{
  "openapi": "3.0.1",
  "info": {
    "title": "LLM Price & Model Change Alerts (Schedule Daily)",
    "description": "Schedule daily LLM price/model change alerts from OpenRouter + LiteLLM. Emits price_up/down, new_model, removed_model, context_change. First run baselines free; later runs bill per change (~$0.005). Optional full catalog query (~$0.10).",
    "version": "0.1",
    "x-build-id": "sulHsQ790UAgvt2r8"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/m8forever~ai-model-pricing-tracker/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-m8forever-ai-model-pricing-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/m8forever~ai-model-pricing-tracker/runs": {
      "post": {
        "operationId": "runs-sync-m8forever-ai-model-pricing-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/m8forever~ai-model-pricing-tracker/run-sync": {
      "post": {
        "operationId": "run-sync-m8forever-ai-model-pricing-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": {
          "mode": {
            "title": "Run mode",
            "enum": [
              "monitor",
              "catalog",
              "both"
            ],
            "type": "string",
            "description": "monitor = change alerts only (schedule this daily; first run baselines, no change charges). catalog = full price table (~$0.10). both = catalog + changes. Leave empty to use emitCatalog/detectChanges toggles."
          },
          "sources": {
            "title": "Sources",
            "type": "array",
            "description": "Data sources: openrouter, litellm",
            "default": [
              "openrouter",
              "litellm"
            ],
            "items": {
              "type": "string"
            }
          },
          "providers": {
            "title": "Providers filter",
            "type": "array",
            "description": "Limit catalog and change detection to these providers, e.g. openai, anthropic, google, deepseek",
            "items": {
              "type": "string"
            }
          },
          "search": {
            "title": "Model name contains",
            "type": "string",
            "description": "Substring filter on model id / display name"
          },
          "modality": {
            "title": "Required input modality",
            "type": "string",
            "description": "Require this input modality: text, image, audio, video, or file"
          },
          "maxInputPricePer1M": {
            "title": "Max input USD per 1M tokens",
            "type": "integer",
            "description": "Keep models whose input price is at most this USD per 1M tokens"
          },
          "emitCatalog": {
            "title": "Output catalog rows",
            "type": "boolean",
            "description": "Used when mode is empty. true charges catalog-query (~$0.10). Prefer mode=monitor for schedules.",
            "default": true
          },
          "detectChanges": {
            "title": "Emit change events vs last run",
            "type": "boolean",
            "description": "Used when mode is empty. Compares to stateStoreName snapshot.",
            "default": true
          },
          "stateStoreName": {
            "title": "State store name",
            "type": "string",
            "description": "Named KV store for baseline. Keep the SAME name across scheduled runs.",
            "default": "ai-model-pricing-state"
          },
          "includeArxiv": {
            "title": "Add latest arXiv AI papers",
            "type": "boolean",
            "description": "Optional add-on: push recent arXiv AI papers (free)",
            "default": false
          },
          "arxivCategories": {
            "title": "arXiv categories",
            "type": "array",
            "description": "arXiv category codes when includeArxiv is true",
            "default": [
              "cs.CL",
              "cs.LG",
              "cs.AI"
            ],
            "items": {
              "type": "string"
            }
          },
          "includeHfTrending": {
            "title": "Add Hugging Face trending models",
            "type": "boolean",
            "description": "Optional add-on: push HF trending models (free)",
            "default": false
          },
          "maxItems": {
            "title": "Max add-on items",
            "type": "integer",
            "description": "Max arXiv / HF add-on rows",
            "default": 25
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}