{
  "openapi": "3.0.1",
  "info": {
    "title": "Radio Airplay Tracker - Was My Song Played? iHeart & BBC Spins",
    "description": "Find every new spin of your songs and artists on iHeart stations (optional BBC): station, market, time. Metadata-based, no audio fingerprinting; scheduled runs return only new spins. Unofficial APIs, see README risks. Failed stations are never charged.",
    "version": "1.0",
    "x-build-id": "i6mtI8a5mtvQJPXMg"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/that_red_bird~radio-airplay-tracker/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-that_red_bird-radio-airplay-tracker",
        "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/that_red_bird~radio-airplay-tracker/runs": {
      "post": {
        "operationId": "runs-sync-that_red_bird-radio-airplay-tracker",
        "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/that_red_bird~radio-airplay-tracker/run-sync": {
      "post": {
        "operationId": "run-sync-that_red_bird-radio-airplay-tracker",
        "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": {
          "artists": {
            "title": "Artists to watch",
            "type": "array",
            "description": "Artist names, one per line. A spin matches when the station's artist field contains the name as whole words (featured artists included). Leave artists and songs empty to see a free sample of the latest spins.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "songs": {
            "title": "Songs to watch",
            "type": "array",
            "description": "Song titles, or 'Artist - Title' to be exact (e.g. 'The Weeknd - Starboy'). Matching ignores case, punctuation, accents and '(feat. ...)' parts.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "stationIds": {
            "title": "iHeart station IDs",
            "type": "array",
            "description": "Specific iHeart station IDs to scan (the id returned in the output as stationId).",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "stationNames": {
            "title": "Station name filter",
            "type": "array",
            "description": "Scan stations whose name, call letters or description contains any of these words (e.g. 'KIIS', 'Z100').",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "markets": {
            "title": "Market / city / state filter",
            "type": "array",
            "description": "Scan stations in these markets (city, market name or 2-letter state), e.g. 'New York', 'CA'. Combined with the other filters (all given filters must match).",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "genres": {
            "title": "Genre filter",
            "type": "array",
            "description": "Scan stations whose primary genre contains any of these words, e.g. 'Hip Hop', 'Country', 'Top 40'.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "maxStations": {
            "title": "Max stations",
            "minimum": 1,
            "maximum": 4000,
            "type": "integer",
            "description": "Maximum number of iHeart stations to scan, biggest audiences first. With no station filter this picks the biggest stations. Use 1000+ to cover the full network.",
            "default": 60
          },
          "historyPerStation": {
            "title": "Recent tracks per station",
            "minimum": 5,
            "maximum": 500,
            "type": "integer",
            "description": "How many of each station's most recent plays to check. A busy station plays roughly 12-15 songs an hour; make sure this covers the gap between your scheduled runs.",
            "default": 40
          },
          "lookbackHours": {
            "title": "Look-back window (hours)",
            "minimum": 1,
            "maximum": 168,
            "type": "integer",
            "description": "Ignore plays older than this. On the first run it also limits how far back spins are reported.",
            "default": 24
          },
          "newOnly": {
            "title": "New spins only",
            "type": "boolean",
            "description": "Report each spin once. The Actor remembers what it already reported in a named key-value store, so scheduled runs return only new spins.",
            "default": true
          },
          "stateStoreName": {
            "title": "State store name",
            "type": "string",
            "description": "Name of the key-value store that remembers reported spins and weekly totals. Use the same name on every scheduled run.",
            "default": "radio-airplay-state"
          },
          "includeBbc": {
            "title": "Also check BBC Radio (unofficial, see README)",
            "type": "boolean",
            "description": "Also read the BBC's now-playing music feed for the services below. Off by default: the BBC's terms discourage automated collection and the feed has no exact timestamps. Turn on only if you accept that risk.",
            "default": false
          },
          "bbcServices": {
            "title": "BBC services",
            "type": "array",
            "description": "BBC service ids to read when BBC is on, e.g. bbc_radio_one, bbc_radio_two, bbc_6music, bbc_radio_three, bbc_asian_network.",
            "default": [
              "bbc_radio_one",
              "bbc_radio_two",
              "bbc_6music",
              "bbc_radio_three",
              "bbc_asian_network"
            ],
            "items": {
              "type": "string"
            }
          },
          "maxSpins": {
            "title": "Max spins per run",
            "minimum": 1,
            "maximum": 100000,
            "type": "integer",
            "description": "Safety cap on spins returned (and charged) in one run. Spins above the cap are reported on the next run.",
            "default": 2000
          },
          "concurrency": {
            "title": "Parallel requests",
            "minimum": 1,
            "maximum": 12,
            "type": "integer",
            "description": "How many stations are read at the same time. Keep it modest to be polite to the source.",
            "default": 6
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}