{
  "openapi": "3.0.1",
  "info": {
    "title": "News & RSS Keyword Monitor (GDELT + Feeds)",
    "description": "Monitor keywords in worldwide news (GDELT) and any RSS/Atom feed. Exclude words, language and country filters, dedupe, and only new articles on schedules.",
    "version": "0.1",
    "x-build-id": "avEICLQcSUS6sQ6h8"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/prevailing_glow~news-rss-keyword-monitor/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-prevailing_glow-news-rss-keyword-monitor",
        "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/prevailing_glow~news-rss-keyword-monitor/runs": {
      "post": {
        "operationId": "runs-sync-prevailing_glow-news-rss-keyword-monitor",
        "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/prevailing_glow~news-rss-keyword-monitor/run-sync": {
      "post": {
        "operationId": "run-sync-prevailing_glow-news-rss-keyword-monitor",
        "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": {
          "keywords": {
            "title": "Keywords",
            "type": "array",
            "description": "Words or phrases to look for (case- and accent-insensitive, whole words: \"AI\" does not match \"said\"). GDELT searches the full article text; feed articles must mention a keyword in the title or summary. A trailing <code>*</code> is a prefix wildcard in feeds (GDELT searches the word itself). GDELT ignores keywords shorter than 3 characters; they still apply to feeds.",
            "items": {
              "type": "string"
            }
          },
          "gdeltKeywords": {
            "title": "English search terms for GDELT (optional)",
            "type": "array",
            "description": "GDELT searches English machine translations of all articles, including Dutch, German or French news. For non-English monitoring, enter the English terms here (e.g. <code>housing market</code>, <code>Dutch cabinet</code>) and keep your native-language keywords above for the feeds. Empty = GDELT uses the keywords above.",
            "items": {
              "type": "string"
            }
          },
          "excludeKeywords": {
            "title": "Exclude words",
            "type": "array",
            "description": "Articles mentioning any of these (in GDELT: anywhere in the text; in feeds: title or summary) are dropped.",
            "items": {
              "type": "string"
            }
          },
          "matchMode": {
            "title": "Keyword match",
            "enum": [
              "any",
              "all"
            ],
            "type": "string",
            "description": "Return articles that mention any keyword, or only those that mention all of them.",
            "default": "any"
          },
          "feeds": {
            "title": "RSS / Atom feed URLs",
            "type": "array",
            "description": "Optional feeds to watch next to GDELT: RSS 2.0, RSS 1.0 (RDF) or Atom. A Google News RSS search URL you copied also works. A web page URL works if the page links to its feed. Leave keywords empty to get every article from these feeds.",
            "items": {
              "type": "string"
            }
          },
          "useGdelt": {
            "title": "Search GDELT",
            "type": "boolean",
            "description": "Search the keywords in the GDELT DOC 2.0 news index (worldwide online news, about 65 languages, updated every 15 minutes). If GDELT is slow or down, the run still returns your feed articles.",
            "default": true
          },
          "languages": {
            "title": "Languages",
            "type": "array",
            "description": "ISO 639-1 codes such as <code>en</code>, <code>nl</code>, <code>de</code>. Applied to GDELT and to feeds that declare a language. Empty = all languages.",
            "items": {
              "type": "string"
            }
          },
          "countries": {
            "title": "Source countries (GDELT)",
            "type": "array",
            "description": "ISO country codes such as <code>US</code>, <code>GB</code>, <code>NL</code> (or English names). Filters GDELT by the publisher's country. Feeds are not filtered by country.",
            "items": {
              "type": "string"
            }
          },
          "lookbackHours": {
            "title": "Lookback window (hours)",
            "minimum": 1,
            "maximum": 2160,
            "type": "integer",
            "description": "Only articles published within this window. Default 48 h because GDELT's index sometimes lags by a day or more; on scheduled runs the seen-store prevents duplicates. GDELT covers up to the last 3 months (2160 h).",
            "default": 48
          },
          "maxArticles": {
            "title": "Max articles per run",
            "minimum": 1,
            "maximum": 10000,
            "type": "integer",
            "description": "Cap on rows delivered per run (newest first). Articles over the cap are not marked as seen, so the next run can still deliver them.",
            "default": 200
          },
          "onlyNew": {
            "title": "Return only new articles",
            "type": "boolean",
            "description": "Remember delivered articles between runs and return only new ones: ideal for schedules. Turn off to return every match (each row still shows isNew).",
            "default": true
          },
          "stateStoreName": {
            "title": "Seen-articles store name",
            "type": "string",
            "description": "Named key-value store that remembers delivered articles. Use a different name per monitor (task) so they do not share state. Letters, digits and hyphens.",
            "default": "news-rss-keyword-monitor-state"
          },
          "gdeltMaxRecords": {
            "title": "GDELT max records",
            "minimum": 1,
            "maximum": 250,
            "type": "integer",
            "description": "Articles requested from GDELT per run (GDELT's maximum is 250, newest first).",
            "default": 250
          },
          "gdeltMaxWaitSecs": {
            "title": "GDELT max wait (seconds)",
            "minimum": 10,
            "maximum": 900,
            "type": "integer",
            "description": "Total time for GDELT including retries when it rate-limits (HTTP 429) or errors. After that the run continues with feed articles only. Raise it for unattended scheduled runs where a slower run is fine.",
            "default": 40
          },
          "requestTimeoutSecs": {
            "title": "Request timeout (seconds)",
            "minimum": 5,
            "maximum": 120,
            "type": "integer",
            "description": "Timeout for each GDELT or feed request.",
            "default": 30
          },
          "proxyConfiguration": {
            "title": "Proxy for GDELT",
            "type": "object",
            "description": "Optional. GDELT allows one request every 5 seconds per IP address; a proxy helps if your runs keep getting rate-limited. Feeds are always fetched directly.",
            "default": {
              "useApifyProxy": false
            }
          },
          "statusRowWhenEmpty": {
            "title": "Status row when nothing is new",
            "type": "boolean",
            "description": "When a run finds no new articles, write one free row with type \"status\" so you can see the run happened. Turn off to keep the dataset strictly to articles.",
            "default": true
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}