{
  "openapi": "3.0.1",
  "info": {
    "title": "Spain Fuel Prices – Every Gas Station, Official Data",
    "description": "Official prices of gasoline, diesel, LPG, CNG, hydrogen and more at all ~11,500 gas stations in Spain, live or for any past day. Filter by province, town, postal code, brand, fuel or distance and get the cheapest stations first. Straight from Spanish Government open data.",
    "version": "0.0",
    "x-build-id": "tpNZNM2CnNw1j28Qt"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/shikimokami~spain-fuel-prices/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-shikimokami-spain-fuel-prices",
        "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/shikimokami~spain-fuel-prices/runs": {
      "post": {
        "operationId": "runs-sync-shikimokami-spain-fuel-prices",
        "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/shikimokami~spain-fuel-prices/run-sync": {
      "post": {
        "operationId": "run-sync-shikimokami-spain-fuel-prices",
        "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": {
          "provinces": {
            "title": "Provinces",
            "type": "array",
            "description": "Only stations in these provinces. Leave empty for all of Spain (about 12,000 stations).",
            "items": {
              "type": "string",
              "enum": [
                "15",
                "02",
                "03",
                "04",
                "01",
                "33",
                "05",
                "06",
                "08",
                "48",
                "09",
                "39",
                "12",
                "51",
                "13",
                "16",
                "10",
                "11",
                "14",
                "20",
                "17",
                "18",
                "19",
                "21",
                "22",
                "07",
                "23",
                "26",
                "35",
                "24",
                "25",
                "27",
                "28",
                "52",
                "30",
                "29",
                "31",
                "32",
                "34",
                "36",
                "37",
                "38",
                "40",
                "41",
                "42",
                "43",
                "44",
                "45",
                "46",
                "47",
                "49",
                "50"
              ],
              "enumTitles": [
                "A Coruña",
                "Albacete",
                "Alicante",
                "Almería",
                "Araba/Álava",
                "Asturias",
                "Ávila",
                "Badajoz",
                "Barcelona",
                "Bizkaia",
                "Burgos",
                "Cantabria",
                "Castellón",
                "Ceuta",
                "Ciudad Real",
                "Cuenca",
                "Cáceres",
                "Cádiz",
                "Córdoba",
                "Gipuzkoa",
                "Girona",
                "Granada",
                "Guadalajara",
                "Huelva",
                "Huesca",
                "Illes Balears",
                "Jaén",
                "La Rioja",
                "Las Palmas",
                "León",
                "Lleida",
                "Lugo",
                "Madrid",
                "Melilla",
                "Murcia",
                "Málaga",
                "Navarra",
                "Ourense",
                "Palencia",
                "Pontevedra",
                "Salamanca",
                "Santa Cruz de Tenerife",
                "Segovia",
                "Sevilla",
                "Soria",
                "Tarragona",
                "Teruel",
                "Toledo",
                "Valencia",
                "Valladolid",
                "Zamora",
                "Zaragoza"
              ]
            },
            "default": []
          },
          "municipality": {
            "title": "Municipality or town",
            "type": "string",
            "description": "Only stations whose municipality or town contains this text (accents and case are ignored), e.g. «Málaga» or «Alcalá»."
          },
          "postalCode": {
            "title": "Postal codes",
            "type": "string",
            "description": "One or more postal codes or prefixes separated by commas, e.g. «28001, 28002» or «080» for all of Barcelona city."
          },
          "brand": {
            "title": "Brand",
            "type": "string",
            "description": "Only stations of this brand or sign, e.g. «Repsol», «Ballenoil», «Costco». «Unbranded» for independent stations."
          },
          "fuelTypes": {
            "title": "Fuel types",
            "type": "array",
            "description": "Only stations that sell at least one of these fuels. The first one is used when sorting by price. Leave empty to include every station.",
            "items": {
              "type": "string",
              "enum": [
                "gasoline95E5",
                "gasoline95E10",
                "gasoline95E5Premium",
                "gasoline95E25",
                "gasoline95E85",
                "gasoline98E5",
                "gasoline98E10",
                "renewableGasoline",
                "dieselA",
                "dieselPremium",
                "dieselB",
                "renewableDiesel",
                "biodiesel",
                "bioethanol",
                "lpg",
                "cng",
                "lng",
                "bioCng",
                "bioLng",
                "hydrogen",
                "adblue",
                "ammonia",
                "methanol"
              ],
              "enumTitles": [
                "Gasoline 95 E5",
                "Gasoline 95 E10",
                "Gasoline 95 E5 Premium",
                "Gasoline 95 E25",
                "Gasoline 95 E85",
                "Gasoline 98 E5",
                "Gasoline 98 E10",
                "Renewable gasoline",
                "Diesel (Gasóleo A)",
                "Diesel Premium",
                "Agricultural diesel (Gasóleo B)",
                "Renewable diesel (HVO)",
                "Biodiesel",
                "Bioethanol",
                "LPG / Autogas",
                "CNG (compressed natural gas)",
                "LNG (liquefied natural gas)",
                "Bio-CNG",
                "Bio-LNG",
                "Hydrogen",
                "AdBlue",
                "Ammonia",
                "Methanol"
              ]
            },
            "default": []
          },
          "latitude": {
            "title": "Latitude",
            "type": "string",
            "description": "Your point, e.g. «40.4168». Adds the distance in km to every station and enables the radius filter."
          },
          "longitude": {
            "title": "Longitude",
            "type": "string",
            "description": "Your point, e.g. «-3.7038»."
          },
          "radiusKm": {
            "title": "Radius (km)",
            "minimum": 1,
            "maximum": 1000,
            "type": "integer",
            "description": "Only stations within this distance of the point above."
          },
          "sortBy": {
            "title": "Sort by",
            "enum": [
              "none",
              "price",
              "distance"
            ],
            "type": "string",
            "description": "Order of the results.",
            "default": "none"
          },
          "maxResults": {
            "title": "Maximum results",
            "minimum": 0,
            "type": "integer",
            "description": "Stop after this many stations (0 = no limit). Combine with «Cheapest first» to get e.g. the 10 cheapest stations.",
            "default": 0
          },
          "date": {
            "title": "Historical date",
            "type": "string",
            "description": "Get the official closing prices of a past day (YYYY-MM-DD). Leave empty for the current live prices."
          },
          "includeRestrictedSale": {
            "title": "Include restricted-sale stations",
            "type": "boolean",
            "description": "Also include stations that only sell to members or fleets (not open to the public).",
            "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}