POST
/
api
/
sources
curl --request POST \
  --url https://local-news.newscatcherapi.com/api/sources \
  --header 'Content-Type: application/json' \
  --header 'x-api-token: <api-key>' \
  --data '{
  "lang": [
    "en",
    "es"
  ],
  "countries": [
    "US",
    "CA"
  ],
  "theme": [
    "Business",
    "Finance"
  ]
}'
{
  "message": "<string>",
  "sources": [
    "<string>"
  ],
  "user_input": {
    "lang": "<string>",
    "countries": "<string>",
    "theme": "<string>"
  }
}

Authorizations

x-api-token
string
header
required

API Key to authenticate requests.

To access the API, include your API key in the x-api-token header. To obtain your API key, complete the form or contact us directly.

Body

application/json
lang

The language(s) of the search. The only accepted format is the two-letter ISO 639-1 code. To select multiple languages, use a comma-separated string or an array of strings.

Examples:

  • "en,es"
  • ["en", "es"]

To learn more, see Enumerated parameters > Language.

Example:
["en", "es"]
countries

The countries where the news publisher is located. The accepted format is the two-letter ISO 3166-1 alpha-2 code. To select multiple countries, use a comma-separated string or an array of strings.

Examples:

  • "US,CA"
  • ["US", "CA"]

To learn more, see Enumerated parameters > Country.

Example:
["US", "CA"]
theme

Filters articles based on their general topic, as determined by NLP analysis. To select multiple themes, use a comma-separated string or an array of strings.

Examples:

  • "Finance, Tech"
  • ["Finance", "Tech"]

To learn more, see NLP features.

Available options: Business, Economics, Entertainment, Finance, Health, Politics, Science, Sports, Tech, Crime, Financial Crime, Lifestyle, Automotive, Travel, Weather, General.

Example:
["Business", "Finance"]

Response

200
application/json
Successful response containing the list of sources

The response model for the Sources request.

Response field behavior:

  • Required fields are guaranteed to be present and non-null.
  • Optional fields may be null/undefined if the data couldn't be extracted during processing.
message
string
required

A message describing the result of the sources request.

sources
string[]
required

A list of available local news sources.

user_input
object
required

The user input parameters used to search local news sources.