{
  "openapi": "3.0.1",
  "info": {
    "title": "News API - Article Search, Headlines, Sentiment, NewsCatcher",
    "description": "Search news articles from 140,000+ sources by keyword, entity, theme, sentiment, language and country, or pull latest headlines, breaking news, articles by author or URL, news sources and article counts from the NewsCatcher News API into a dataset. Bring your own API key.",
    "version": "0.1",
    "x-build-id": "05ohdIbWlv8Mvv27P"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/nabeelbaghoor~news-search-api-headlines-sentiment/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-nabeelbaghoor-news-search-api-headlines-sentiment",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor, waits for its completion, and returns Actor's dataset items in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/acts/nabeelbaghoor~news-search-api-headlines-sentiment/runs": {
      "post": {
        "operationId": "runs-sync-nabeelbaghoor-news-search-api-headlines-sentiment",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor and returns information about the initiated run in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/runsResponseSchema"
                }
              }
            }
          }
        }
      }
    },
    "/acts/nabeelbaghoor~news-search-api-headlines-sentiment/run-sync": {
      "post": {
        "operationId": "run-sync-nabeelbaghoor-news-search-api-headlines-sentiment",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor, waits for completion, and returns the OUTPUT from Key-value store in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    }
  },
  "components": {
    "schemas": {
      "inputSchema": {
        "type": "object",
        "properties": {
          "mode": {
            "title": "What to read",
            "enum": [
              "search",
              "latestHeadlines",
              "breakingNews",
              "authors",
              "articlesByLink",
              "sources",
              "articleCounts"
            ],
            "type": "string",
            "description": "Article search reads articles matching keywords or a Boolean query. Latest headlines reads the newest articles in a time window. Breaking news reads stories with sudden coverage, each with its top articles. Articles by author reads one byline at a time. Articles by URL or ID looks up known articles. News sources lists the indexed publishers. Article counts returns how many articles matched per hour, day or month.",
            "default": "search"
          },
          "queries": {
            "title": "Search queries",
            "type": "array",
            "description": "Article search and article counts. One query per line, each read separately. Supports AND, OR, NOT, + and -, wildcards such as technolog*, and exact phrases in double quotes. Separate words are joined with AND automatically. The characters [ ] / \\ : ^ are not allowed.",
            "items": {
              "type": "string"
            }
          },
          "searchIn": {
            "title": "Search in",
            "enum": [
              "title_content",
              "title",
              "content",
              "summary",
              "title_content_translated",
              "title_translated",
              "content_translated",
              "summary_translated"
            ],
            "type": "string",
            "description": "Article search and article counts. Which article fields the query is matched against. The translated fields search the English translation of non-English articles.",
            "default": "title_content"
          },
          "authorNames": {
            "title": "Author names",
            "type": "array",
            "description": "Articles by author. Author bylines, one per line, each matched exactly and read separately.",
            "items": {
              "type": "string"
            }
          },
          "articleLinks": {
            "title": "Article URLs",
            "type": "array",
            "description": "Articles by URL or ID. Full article URLs, one per line. Sent 25 to a request.",
            "items": {
              "type": "string"
            }
          },
          "articleIds": {
            "title": "Article IDs",
            "type": "array",
            "description": "Articles by URL or ID. Article IDs from the id field of earlier results, one per line. Sent 25 to a request.",
            "items": {
              "type": "string"
            }
          },
          "from": {
            "title": "From",
            "type": "string",
            "description": "Article search, articles by author, articles by URL or ID and article counts. Earliest publication date, in UTC: a date such as 2026-01-31, a date and time such as 2026-01-31T09:00:00, or a relative value such as 30d, 24h or 3 days ago. The provider defaults to 7 days ago (1 month ago for URL lookups). How far back you can go depends on your plan."
          },
          "to": {
            "title": "To",
            "type": "string",
            "description": "Same modes as From. Latest publication date, in the same formats. Defaults to now."
          },
          "when": {
            "title": "Headlines time window",
            "type": "string",
            "description": "Latest headlines. How far back to read, as hours or days such as 1h, 24h, 7d or 30d.",
            "default": "7d"
          },
          "languages": {
            "title": "Languages",
            "type": "array",
            "description": "Two letter language codes such as en, de or es, one per line. The provider uses cn for Chinese (China) and tw for Chinese (Taiwan). Not used by breaking news or URL lookups.",
            "items": {
              "type": "string"
            }
          },
          "excludeLanguages": {
            "title": "Exclude languages",
            "type": "array",
            "description": "Two letter language codes to leave out.",
            "items": {
              "type": "string"
            }
          },
          "countries": {
            "title": "Publisher countries",
            "type": "array",
            "description": "Two letter country codes such as US, GB or DE, one per line. Matches where the publisher is based, not where the story happened; use Locations for that.",
            "items": {
              "type": "string"
            }
          },
          "excludeCountries": {
            "title": "Exclude publisher countries",
            "type": "array",
            "description": "Two letter country codes to leave out.",
            "items": {
              "type": "string"
            }
          },
          "sourceDomains": {
            "title": "Source domains",
            "type": "array",
            "description": "Only these publishers, as domains such as reuters.com or finance.yahoo.com, one per line. In the news sources mode, looks these domains up in the catalogue.",
            "items": {
              "type": "string"
            }
          },
          "excludeSourceDomains": {
            "title": "Exclude source domains",
            "type": "array",
            "description": "Publishers to leave out, as domains.",
            "items": {
              "type": "string"
            }
          },
          "predefinedSources": {
            "title": "Top sources per country",
            "type": "array",
            "description": "The provider's curated top publishers per country, written as top, a number and a country code, such as top 50 US or top 20 GB, one per line.",
            "items": {
              "type": "string"
            }
          },
          "sourceName": {
            "title": "Source name contains",
            "type": "array",
            "description": "Article search and news sources. Words to find in publisher names.",
            "items": {
              "type": "string"
            }
          },
          "excludeAuthors": {
            "title": "Exclude authors",
            "type": "array",
            "description": "Author names to leave out.",
            "items": {
              "type": "string"
            }
          },
          "sortBy": {
            "title": "Sort order",
            "enum": [
              "relevancy",
              "date",
              "rank"
            ],
            "type": "string",
            "description": "Most relevant first, newest first, or from the highest ranked publishers first.",
            "default": "relevancy"
          },
          "includeUnrankedSources": {
            "title": "Include unranked sources",
            "type": "boolean",
            "description": "By default only publishers ranked in the top 1 million websites are searched. Tick to include the long tail too."
          },
          "fromRank": {
            "title": "Lowest source rank",
            "minimum": 1,
            "maximum": 999999,
            "type": "integer",
            "description": "Only publishers with a rank at or above this number (1 is the most popular). Not available for latest headlines."
          },
          "toRank": {
            "title": "Highest source rank",
            "minimum": 1,
            "maximum": 999999,
            "type": "integer",
            "description": "Only publishers with a rank at or below this number, such as 1000 for the top thousand sites."
          },
          "headlines": {
            "title": "Home page headlines",
            "enum": [
              "any",
              "only",
              "exclude"
            ],
            "type": "string",
            "description": "Only articles that appeared on the publisher's home page, only those that did not, or both.",
            "default": "any"
          },
          "opinion": {
            "title": "Opinion pieces",
            "enum": [
              "any",
              "only",
              "exclude"
            ],
            "type": "string",
            "description": "Only opinion pieces, news only, or both.",
            "default": "any"
          },
          "fullTextOnly": {
            "title": "Full text available only",
            "type": "boolean",
            "description": "Leave out articles whose full text is not publicly available, such as paywalled stories where only a preview is indexed."
          },
          "wordCountMin": {
            "title": "Minimum word count",
            "minimum": 0,
            "type": "integer",
            "description": "Leave out articles shorter than this."
          },
          "wordCountMax": {
            "title": "Maximum word count",
            "minimum": 0,
            "type": "integer",
            "description": "Leave out articles longer than this."
          },
          "newsDomainType": {
            "title": "News domain type",
            "enum": [
              "Original Content",
              "Aggregator",
              "Press Releases",
              "Republisher",
              "Other"
            ],
            "type": "string",
            "description": "Article search and news sources. Only original publishers, aggregators, press release sites, republishers or others."
          },
          "newsTypes": {
            "title": "News types",
            "type": "array",
            "description": "Article search and news sources. Only publishers of these kinds.",
            "items": {
              "type": "string",
              "enum": [
                "Tech News and Updates",
                "Sports News and Blogs",
                "News and Blogs",
                "E-commerce and Product Information",
                "Educational News",
                "Press Releases",
                "Corporate News",
                "Gaming News and Blogs",
                "Entertainment and Media News",
                "Health and Medical News",
                "Government and Municipal News",
                "Real Estate News",
                "Automotive News and Blogs",
                "News Aggregators",
                "Fashion and Lifestyle",
                "Local News and Community Events",
                "Music and Radio",
                "Reviews",
                "Blogs and Magazines",
                "Political News",
                "Non-Profit and Organization News",
                "Event News",
                "General News Outlets",
                "Gambling News",
                "Travel and Lifestyle",
                "Finance and Investment",
                "Specific News Type",
                "Pure News Outlet",
                "Corporate News Section",
                "Other"
              ],
              "enumTitles": [
                "Tech News and Updates",
                "Sports News and Blogs",
                "News and Blogs",
                "E-commerce and Product Information",
                "Educational News",
                "Press Releases",
                "Corporate News",
                "Gaming News and Blogs",
                "Entertainment and Media News",
                "Health and Medical News",
                "Government and Municipal News",
                "Real Estate News",
                "Automotive News and Blogs",
                "News Aggregators",
                "Fashion and Lifestyle",
                "Local News and Community Events",
                "Music and Radio",
                "Reviews",
                "Blogs and Magazines",
                "Political News",
                "Non-Profit and Organization News",
                "Event News",
                "General News Outlets",
                "Gambling News",
                "Travel and Lifestyle",
                "Finance and Investment",
                "Specific News Type",
                "Pure News Outlet",
                "Corporate News Section",
                "Other"
              ]
            }
          },
          "newsDomainsOnly": {
            "title": "News domains only",
            "type": "boolean",
            "description": "Article search and news sources. Leave out sites the provider does not classify as news domains."
          },
          "themes": {
            "title": "Themes",
            "type": "array",
            "description": "Only articles the provider's NLP classifies under these themes.",
            "items": {
              "type": "string",
              "enum": [
                "Business",
                "Economics",
                "Entertainment",
                "Finance",
                "Health",
                "Politics",
                "Science",
                "Sports",
                "Tech",
                "Crime",
                "Financial Crime",
                "Lifestyle",
                "Automotive",
                "Travel",
                "Weather",
                "General"
              ],
              "enumTitles": [
                "Business",
                "Economics",
                "Entertainment",
                "Finance",
                "Health",
                "Politics",
                "Science",
                "Sports",
                "Tech",
                "Crime",
                "Financial Crime",
                "Lifestyle",
                "Automotive",
                "Travel",
                "Weather",
                "General"
              ]
            }
          },
          "excludeThemes": {
            "title": "Exclude themes",
            "type": "array",
            "description": "Leave out articles under these themes.",
            "items": {
              "type": "string",
              "enum": [
                "Business",
                "Economics",
                "Entertainment",
                "Finance",
                "Health",
                "Politics",
                "Science",
                "Sports",
                "Tech",
                "Crime",
                "Financial Crime",
                "Lifestyle",
                "Automotive",
                "Travel",
                "Weather",
                "General"
              ],
              "enumTitles": [
                "Business",
                "Economics",
                "Entertainment",
                "Finance",
                "Health",
                "Politics",
                "Science",
                "Sports",
                "Tech",
                "Crime",
                "Financial Crime",
                "Lifestyle",
                "Automotive",
                "Travel",
                "Weather",
                "General"
              ]
            }
          },
          "organizations": {
            "title": "Organizations mentioned",
            "type": "array",
            "description": "Article search, latest headlines, breaking news and counts. Only articles whose named entity recognition found these organizations.",
            "items": {
              "type": "string"
            }
          },
          "people": {
            "title": "People mentioned",
            "type": "array",
            "description": "Only articles mentioning these people, as found by named entity recognition.",
            "items": {
              "type": "string"
            }
          },
          "locations": {
            "title": "Locations mentioned",
            "type": "array",
            "description": "Only articles mentioning these places.",
            "items": {
              "type": "string"
            }
          },
          "otherEntities": {
            "title": "Other entities mentioned",
            "type": "array",
            "description": "Only articles mentioning these products, events, nationalities or other named entities.",
            "items": {
              "type": "string"
            }
          },
          "titleSentimentMin": {
            "title": "Minimum title sentiment",
            "minimum": -1,
            "maximum": 1,
            "type": "number",
            "description": "From -1 (most negative) to 1 (most positive)."
          },
          "titleSentimentMax": {
            "title": "Maximum title sentiment",
            "minimum": -1,
            "maximum": 1,
            "type": "number",
            "description": "From -1 to 1. For negative news only, set this to 0."
          },
          "contentSentimentMin": {
            "title": "Minimum content sentiment",
            "minimum": -1,
            "maximum": 1,
            "type": "number",
            "description": "Sentiment of the article body, from -1 to 1."
          },
          "contentSentimentMax": {
            "title": "Maximum content sentiment",
            "minimum": -1,
            "maximum": 1,
            "type": "number",
            "description": "Sentiment of the article body, from -1 to 1."
          },
          "iptcTags": {
            "title": "IPTC media topic IDs",
            "type": "array",
            "description": "IPTC Tags plan or higher. Only articles tagged with these IPTC media topic IDs.",
            "items": {
              "type": "string"
            }
          },
          "iabTags": {
            "title": "IAB categories",
            "type": "array",
            "description": "IPTC Tags plan or higher. Article search, latest headlines and articles by author. Only articles in these IAB content categories.",
            "items": {
              "type": "string"
            }
          },
          "includeNlpData": {
            "title": "Include NLP data",
            "type": "boolean",
            "description": "Add each article's theme, AI summary, title and content sentiment and named entities, where the provider has them.",
            "default": true
          },
          "includeTranslation": {
            "title": "Include English translations",
            "type": "boolean",
            "description": "Add English translations of the title and content of non-English articles."
          },
          "excludeDuplicates": {
            "title": "Exclude duplicates",
            "type": "boolean",
            "description": "Article search. Leave out duplicate and near identical articles, such as syndicated wire copy."
          },
          "robotsCompliantOnly": {
            "title": "Robots.txt compliant only",
            "type": "boolean",
            "description": "Only articles whose publisher's robots.txt allows crawling. Useful when you plan to reuse the content."
          },
          "topArticlesPerEvent": {
            "title": "Top articles per event",
            "minimum": 1,
            "maximum": 100,
            "type": "integer",
            "description": "Breaking news. How many top articles each event carries.",
            "default": 3
          },
          "aggregationBy": {
            "title": "Count interval",
            "enum": [
              "day",
              "hour",
              "month"
            ],
            "type": "string",
            "description": "Article counts. Count per hour, day or month.",
            "default": "day"
          },
          "includeSourceDetails": {
            "title": "Include source details",
            "type": "boolean",
            "description": "News sources. Add each source's country, rank, domain type, news type, robots.txt compliance and 7 day article volume.",
            "default": true
          },
          "maxResults": {
            "title": "Maximum results",
            "minimum": 1,
            "maximum": 100000,
            "type": "integer",
            "description": "The most rows this run returns and charges for, across all queries. Pages are read up to 1000 at a time, and the provider serves at most 10,000 results for one query; split the dates to read more.",
            "default": 100
          },
          "requestsPerMinute": {
            "title": "Requests per minute",
            "minimum": 1,
            "maximum": 600,
            "type": "integer",
            "description": "Pacing. Your plan limits concurrent calls, and the actor waits and retries when the provider answers 429.",
            "default": 60
          },
          "apiKey": {
            "title": "API key",
            "type": "string",
            "description": "Your own NewsCatcher News API key from your subscription. Stored as a secret and sent only in the x-api-token header; it is never logged. You can instead set the DATA_API_KEY environment secret."
          }
        }
      },
      "runsResponseSchema": {
        "type": "object",
        "properties": {
          "data": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string"
              },
              "actId": {
                "type": "string"
              },
              "userId": {
                "type": "string"
              },
              "startedAt": {
                "type": "string",
                "format": "date-time",
                "example": "2025-01-08T00:00:00.000Z"
              },
              "finishedAt": {
                "type": "string",
                "format": "date-time",
                "example": "2025-01-08T00:00:00.000Z"
              },
              "status": {
                "type": "string",
                "example": "READY"
              },
              "meta": {
                "type": "object",
                "properties": {
                  "origin": {
                    "type": "string",
                    "example": "API"
                  },
                  "userAgent": {
                    "type": "string"
                  }
                }
              },
              "stats": {
                "type": "object",
                "properties": {
                  "inputBodyLen": {
                    "type": "integer",
                    "example": 2000
                  },
                  "rebootCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "restartCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "resurrectCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "computeUnits": {
                    "type": "integer",
                    "example": 0
                  }
                }
              },
              "options": {
                "type": "object",
                "properties": {
                  "build": {
                    "type": "string",
                    "example": "latest"
                  },
                  "timeoutSecs": {
                    "type": "integer",
                    "example": 300
                  },
                  "memoryMbytes": {
                    "type": "integer",
                    "example": 1024
                  },
                  "diskMbytes": {
                    "type": "integer",
                    "example": 2048
                  }
                }
              },
              "buildId": {
                "type": "string"
              },
              "defaultKeyValueStoreId": {
                "type": "string"
              },
              "defaultDatasetId": {
                "type": "string"
              },
              "defaultRequestQueueId": {
                "type": "string"
              },
              "buildNumber": {
                "type": "string",
                "example": "1.0.0"
              },
              "containerUrl": {
                "type": "string"
              },
              "usage": {
                "type": "object",
                "properties": {
                  "ACTOR_COMPUTE_UNITS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_WRITES": {
                    "type": "integer",
                    "example": 1
                  },
                  "KEY_VALUE_STORE_LISTS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_INTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_EXTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_SERPS": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_UNBLOCKER_UNITS": {
                    "type": "integer",
                    "example": 0
                  }
                }
              },
              "usageTotalUsd": {
                "type": "number",
                "example": 0.00005
              },
              "usageUsd": {
                "type": "object",
                "properties": {
                  "ACTOR_COMPUTE_UNITS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_WRITES": {
                    "type": "number",
                    "example": 0.00005
                  },
                  "KEY_VALUE_STORE_LISTS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_INTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_EXTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_SERPS": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_UNBLOCKER_UNITS": {
                    "type": "integer",
                    "example": 0
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}