{
  "openapi": "3.0.1",
  "info": {
    "title": "GDELT News Search & Monitor – Global News, Only New",
    "description": "Search worldwide news in 65 languages through GDELT: keywords, phrases, domain, country, language and tone filters. Scheduled, it delivers only the articles it has never delivered before. One clean JSON record per article.",
    "version": "0.1",
    "x-build-id": "dgLHVlXtPR6Hpk775"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/far003~gdelt-news-monitor/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-far003-gdelt-news-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/far003~gdelt-news-monitor/runs": {
      "post": {
        "operationId": "runs-sync-far003-gdelt-news-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/far003~gdelt-news-monitor/run-sync": {
      "post": {
        "operationId": "run-sync-far003-gdelt-news-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",
        "required": [
          "queries"
        ],
        "properties": {
          "queries": {
            "title": "Searches",
            "minItems": 1,
            "type": "array",
            "description": "One GDELT search per line. Plain words must all appear; put phrases in quotes (\"climate change\"); group alternatives in parentheses ((tesla OR spacex)); exclude with a minus (-football). Every word needs at least 3 letters (write \"artificial intelligence\", not AI). Write the keywords in English even for articles in other languages (GDELT finds them that way; choose them with sourcecountry: or sourcelang:). GDELT operators work too: domain:bbc.co.uk · sourcecountry:france · sourcelang:italian · theme:ENV_CLIMATECHANGE · tone<-5 (negative) · tone>5 (positive).",
            "items": {
              "type": "string"
            }
          },
          "timespan": {
            "title": "How far back",
            "type": "string",
            "description": "A number and a unit: 90min (at least 15 minutes), 6h, 24h, 7d, 2w, 3m (m = months, at most 3: GDELT keeps the last 3 months). Ignored when a start date is given.",
            "default": "24h"
          },
          "startDate": {
            "title": "Start date (optional)",
            "type": "string",
            "description": "Instead of \"how far back\": 2026-10-01 or 2026-10-01T08:00:00Z (UTC unless a zone is given). Older than 3 months is cut to 3 months."
          },
          "endDate": {
            "title": "End date (optional)",
            "type": "string",
            "description": "Used with a start date, or alone to end the window earlier than now. A bare date such as 2026-10-05 includes that whole day (UTC)."
          },
          "maxArticlesPerQuery": {
            "title": "Max articles per search",
            "minimum": 1,
            "maximum": 10000,
            "type": "integer",
            "description": "Your cost cap per search (one article = one charged event). GDELT returns at most 250 articles per request: above 250 the window is read in pieces (each piece ends where the previous one stopped, newest first), one request (15-25 seconds, plus GDELT's 5-second pause) per 250 articles. With \"only new\", articles beyond the cap stay new for the next run.",
            "default": 100
          },
          "maxArticlesTotal": {
            "title": "Max articles in the whole run",
            "minimum": 0,
            "maximum": 1000000,
            "type": "integer",
            "description": "0 = no extra limit. Stops the run once this many articles were delivered, whatever the number of searches.",
            "default": 0
          },
          "sortBy": {
            "title": "Order",
            "enum": [
              "DateDesc",
              "DateAsc",
              "HybridRel",
              "ToneDesc",
              "ToneAsc"
            ],
            "type": "string",
            "description": "Newest first is the one for monitoring. Relevance and tone orders cannot be paged: above 250 articles the window is cut into time slices and the best 250 of each slice are read.",
            "default": "DateDesc"
          },
          "onlyNew": {
            "title": "Only new articles",
            "type": "boolean",
            "description": "Remembers every article it delivers (in a named key-value store, see \"Memory name\") and never delivers or charges it again, across runs and across searches. Off: every run returns everything GDELT lists.",
            "default": true
          },
          "firstRunDelivers": {
            "title": "First run delivers the current articles",
            "type": "boolean",
            "description": "On (default): the first run of a search returns what GDELT lists now, later runs only the additions. Off: the first run silently remembers the current articles as a baseline (free, nothing returned) and you get only what appears afterwards.",
            "default": true
          },
          "monitorName": {
            "title": "Memory name",
            "type": "string",
            "description": "Runs with the same name share one memory (a key-value store named gdelt-news-monitor-<name>). Use another name for an independent schedule. Letters, digits and dashes.",
            "default": "default"
          },
          "sourceCountries": {
            "title": "Only sources from these countries",
            "type": "array",
            "description": "Country names without spaces are safest: france, germany, unitedkingdom, unitedstates. Two-letter codes are GDELT's FIPS codes, not ISO (Germany = GM, UK = UK). Several countries = any of them.",
            "items": {
              "type": "string"
            }
          },
          "sourceLanguages": {
            "title": "Only articles in these languages",
            "type": "array",
            "description": "english, italian, french, german, spanish, arabic, chinese… (or 3-letter codes: eng, ita). Several languages = any of them.",
            "items": {
              "type": "string"
            }
          },
          "domains": {
            "title": "Only these sites",
            "type": "array",
            "description": "bbc.co.uk, theguardian.com… A site includes its subdomains. A full URL is shortened to its domain.",
            "items": {
              "type": "string"
            }
          },
          "excludeDomains": {
            "title": "Never these sites",
            "type": "array",
            "description": "Sites whose articles you do not want.",
            "items": {
              "type": "string"
            }
          },
          "timeoutSecs": {
            "title": "Timeout per request (seconds)",
            "minimum": 10,
            "maximum": 180,
            "type": "integer",
            "description": "10-180. GDELT often needs 5-20 seconds to answer.",
            "default": 90
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}