{
  "openapi": "3.0.1",
  "info": {
    "title": "Stock Market News Scraper",
    "description": "Collect stock market news from Bloomberg, MarketWatch, CNBC, Yahoo Finance, Economic Times & crypto outlets, or search Google News for any company. Ticker filter, sentiment & event tags, only-new-article alerts, optional full text. Clean JSON for alerts, dashboards & AI/RAG. No login.",
    "version": "0.0",
    "x-build-id": "xCYAI0eLS0D7fxBUc"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/vamsi-krishna~stock-market-news-collector/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-vamsi-krishna-stock-market-news-collector",
        "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/vamsi-krishna~stock-market-news-collector/runs": {
      "post": {
        "operationId": "runs-sync-vamsi-krishna-stock-market-news-collector",
        "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/vamsi-krishna~stock-market-news-collector/run-sync": {
      "post": {
        "operationId": "run-sync-vamsi-krishna-stock-market-news-collector",
        "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": {
          "feedPreset": {
            "title": "Feed preset",
            "enum": [
              "us_markets",
              "global_markets",
              "earnings",
              "india_markets",
              "crypto",
              "none",
              "custom"
            ],
            "type": "string",
            "description": "Curated RSS feed bundle. Use \"none\" to fetch only search queries and ticker feeds, or \"custom\" to supply your own RSS URLs.",
            "default": "us_markets"
          },
          "searchQueries": {
            "title": "Google News search queries",
            "type": "array",
            "description": "Search Google News for any company, topic, or person (max 10), e.g. \"Apple OR AAPL\", \"Reliance Industries\", \"lithium prices\". Combined with the preset. Google News operators like OR, quotes, site:, and when:7d work. Article links point to Google News redirect URLs.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "searchLanguage": {
            "title": "Search language",
            "pattern": "^[a-zA-Z]{2}$",
            "type": "string",
            "description": "Two-letter language code for Google News searches (e.g. en, hi, de, ja).",
            "default": "en"
          },
          "searchCountry": {
            "title": "Search country",
            "pattern": "^[a-zA-Z]{2}$",
            "type": "string",
            "description": "Two-letter country code for Google News searches (e.g. US, IN, GB, DE, JP).",
            "default": "US"
          },
          "feeds": {
            "title": "Custom feeds",
            "type": "array",
            "description": "RSS or Atom feed URLs (http or https only, max 20). Used only when Feed preset is \"custom\". Each item can be a URL string or an object with name and url.",
            "default": []
          },
          "tickers": {
            "title": "Stock tickers",
            "type": "array",
            "description": "Only include articles about these tickers (e.g. AAPL, TSLA, NVDA, RELIANCE.NS). Each ticker also fetches its Yahoo Finance headline feed (max 20), and well-known company names (Apple, Nvidia, Infosys, ...) count as a match. Leave empty to disable the ticker filter.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "useTickerFeeds": {
            "title": "Fetch per-ticker feeds",
            "type": "boolean",
            "description": "When tickers are set, also fetch each ticker's Yahoo Finance headline feed. Turn off to filter only the preset or custom feeds.",
            "default": true
          },
          "companies": {
            "title": "Company names",
            "type": "array",
            "description": "Only include articles mentioning these company names. Leave empty to disable.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "tickerMatchMode": {
            "title": "Ticker match mode",
            "enum": [
              "any",
              "all"
            ],
            "type": "string",
            "description": "When multiple tickers are set: \"any\" keeps articles matching at least one ticker; \"all\" requires every ticker.",
            "default": "any"
          },
          "includeKeywords": {
            "title": "Include keywords",
            "type": "array",
            "description": "Only include articles where the headline or summary contains at least one keyword. Leave unset to use built-in finance keywords (stock, market, earnings, S&P, Dow, Nasdaq, ...), which apply only to the US, global, earnings, and custom presets when no tickers, companies, or search queries are set. Use [] to disable keyword filtering; an explicit list is always applied."
          },
          "excludeKeywords": {
            "title": "Exclude keywords",
            "type": "array",
            "description": "Exclude articles where the headline or summary contains any of these keywords.",
            "default": []
          },
          "hoursBack": {
            "title": "Hours back",
            "minimum": 0,
            "maximum": 168,
            "type": "integer",
            "description": "Only include articles published within this many hours. Use 0 to disable the date filter.",
            "default": 24
          },
          "maxItems": {
            "title": "Maximum items",
            "minimum": 1,
            "maximum": 500,
            "type": "integer",
            "description": "Maximum news items returned after sorting by publishedDate descending. Runs also stop at your maximum cost per run.",
            "default": 50
          },
          "maxItemsPerFeed": {
            "title": "Max items per feed",
            "minimum": 1,
            "maximum": 500,
            "type": "integer",
            "description": "Optional cap on items kept from each individual feed before global sorting. Leave empty for no per-feed limit."
          },
          "onlyNewArticles": {
            "title": "Only new articles",
            "type": "boolean",
            "description": "Skip articles already returned by earlier runs with the same sources and filters. Ideal for scheduled alerts: you only receive (and pay for) new headlines. History is kept for 14 days in a named key-value store.",
            "default": false
          },
          "stateKey": {
            "title": "History key",
            "type": "string",
            "description": "Optional name for the onlyNewArticles history. Runs sharing a key share history, even if their filters differ. Leave empty to derive it from sources and filters."
          },
          "enrichArticles": {
            "title": "Enrich articles",
            "type": "boolean",
            "description": "Add companyDetails (name, exchange, sector), eventTypes (earnings, M&A, analyst ratings, ...), sentimentScore, and sentimentLabel to each article.",
            "default": true
          },
          "includeFullText": {
            "title": "Include full article text",
            "type": "boolean",
            "description": "Fetch each returned article page and extract the readable body text. Skips paywalled publishers (Bloomberg, WSJ, FT, Barron's) and Google News redirect links. Makes runs slower.",
            "default": false
          },
          "fullTextMaxChars": {
            "title": "Full text max characters",
            "minimum": 500,
            "maximum": 50000,
            "type": "integer",
            "description": "Truncate extracted article text to this many characters.",
            "default": 10000
          },
          "deduplicate": {
            "title": "Deduplicate by link",
            "type": "boolean",
            "description": "Remove duplicate articles that appear in multiple feeds.",
            "default": true
          },
          "requestTimeoutMs": {
            "title": "Request timeout (ms)",
            "minimum": 5000,
            "maximum": 120000,
            "type": "integer",
            "description": "HTTP timeout per feed or article request.",
            "default": 15000
          },
          "feedRetries": {
            "title": "Feed retries",
            "minimum": 0,
            "maximum": 3,
            "type": "integer",
            "description": "Number of retries after the first failed attempt for each feed.",
            "default": 1
          },
          "failOnAllFeedsFailed": {
            "title": "Fail run when all feeds fail",
            "type": "boolean",
            "description": "Mark the run as FAILED (instead of succeeded with runStatus all_feeds_failed or error) so Apify monitoring and webhooks alert you.",
            "default": false
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}