{
  "openapi": "3.0.1",
  "info": {
    "title": "French Fuel Prices – Live, Cheapest Stations & Alerts",
    "description": "Live fuel prices of every station in France (official feed, refreshed every 10 minutes): cheapest diesel, SP95-E10, SP98, E85 or LPG near an address, station brands from OpenStreetMap, opening hours, shortages, price-change alerts and statistics by department.",
    "version": "0.1",
    "x-build-id": "EIpb86FHrqETGBLbC"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/yck69~french-fuel-prices/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-yck69-french-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/yck69~french-fuel-prices/runs": {
      "post": {
        "operationId": "runs-sync-yck69-french-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/yck69~french-fuel-prices/run-sync": {
      "post": {
        "operationId": "run-sync-yck69-french-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",
        "required": [
          "mode"
        ],
        "properties": {
          "mode": {
            "title": "What do you want?",
            "enum": [
              "stations",
              "stats"
            ],
            "type": "string",
            "description": "<b>Stations</b>: stations with their live prices, cheapest or nearest first, with brand, opening hours, services and savings. Turn on alerts to get only price changes.<br><b>Statistics</b>: average, lowest and highest price by department, region, city or for all of France.",
            "default": "stations"
          },
          "fuels": {
            "title": "Fuels",
            "type": "array",
            "description": "The first fuel is used for sorting, filters and savings.",
            "items": {
              "type": "string",
              "enum": [
                "diesel",
                "e10",
                "sp95",
                "sp98",
                "e85",
                "lpg"
              ],
              "enumTitles": [
                "Diesel (Gazole)",
                "SP95-E10",
                "SP95",
                "SP98",
                "E85 (superethanol)",
                "LPG (GPLc)"
              ]
            },
            "default": [
              "diesel",
              "e10"
            ]
          },
          "address": {
            "title": "Address",
            "type": "string",
            "description": "Any French address, e.g. <code>Place Bellecour, Lyon</code>."
          },
          "radiusKm": {
            "title": "Radius (km)",
            "minimum": 0.1,
            "maximum": 50,
            "type": "number",
            "description": "Up to 50 km.",
            "default": 5
          },
          "latitude": {
            "title": "Latitude",
            "type": "number",
            "description": "Instead of an address."
          },
          "longitude": {
            "title": "Longitude",
            "type": "number",
            "description": "Instead of an address."
          },
          "communes": {
            "title": "Cities",
            "type": "array",
            "description": "City names, e.g. <code>Toulouse</code>.",
            "items": {
              "type": "string"
            }
          },
          "postalCodes": {
            "title": "Postal codes",
            "type": "array",
            "description": "e.g. <code>31000</code>.",
            "items": {
              "type": "string"
            }
          },
          "departments": {
            "title": "Departments",
            "type": "array",
            "description": "e.g. <code>31</code>, <code>2A</code>.",
            "items": {
              "type": "string"
            }
          },
          "regions": {
            "title": "Regions",
            "type": "array",
            "description": "Whole regions.",
            "items": {
              "type": "string",
              "enum": [
                "11",
                "24",
                "27",
                "28",
                "32",
                "44",
                "52",
                "53",
                "75",
                "76",
                "84",
                "93",
                "94"
              ],
              "enumTitles": [
                "Île-de-France",
                "Centre-Val de Loire",
                "Bourgogne-Franche-Comté",
                "Normandie",
                "Hauts-de-France",
                "Grand Est",
                "Pays de la Loire",
                "Bretagne",
                "Nouvelle-Aquitaine",
                "Occitanie",
                "Auvergne-Rhône-Alpes",
                "Provence-Alpes-Côte d'Azur",
                "Corse"
              ]
            }
          },
          "sortBy": {
            "title": "Sort by",
            "enum": [
              "cheapest",
              "distance",
              "freshest"
            ],
            "type": "string",
            "description": "Cheapest first by default.",
            "default": "cheapest"
          },
          "onlyAvailable": {
            "title": "Only stations selling the first fuel",
            "type": "boolean",
            "description": "Excludes stations out of stock.",
            "default": true
          },
          "maxPrice": {
            "title": "Maximum price (€/litre)",
            "type": "number",
            "description": "For the first fuel, e.g. <code>1.75</code>."
          },
          "maxAgeHours": {
            "title": "Price updated within (hours)",
            "type": "number",
            "description": "Ignore stations whose price hasn't been updated recently."
          },
          "only24h": {
            "title": "Only 24/7 card machines",
            "type": "boolean",
            "description": "Stations with a 24/7 automatic pump.",
            "default": false
          },
          "motorway": {
            "title": "Motorway stations",
            "enum": [
              "include",
              "exclude",
              "only"
            ],
            "type": "string",
            "description": "Motorway stations are usually more expensive.",
            "default": "include"
          },
          "services": {
            "title": "Required services",
            "type": "array",
            "description": "Words found in the service list, e.g. <code>Lavage</code>, <code>Bornes électriques</code>, <code>Gonflage</code>, <code>Boutique</code>.",
            "items": {
              "type": "string"
            }
          },
          "addBrands": {
            "title": "Add station brand and name (OpenStreetMap)",
            "type": "boolean",
            "description": "The official feed has no brand; it is matched from OpenStreetMap when available.",
            "default": true
          },
          "onlyChanges": {
            "title": "Alerts: only price changes since the last run",
            "type": "boolean",
            "description": "Schedule the Actor (e.g. every hour) with an email or Slack integration to follow price moves around you.",
            "default": false
          },
          "alertName": {
            "title": "Alert name",
            "type": "string",
            "description": "Separate memory per alert. Defaults to one per set of filters."
          },
          "groupBy": {
            "title": "Statistics by",
            "enum": [
              "department",
              "region",
              "city",
              "national"
            ],
            "type": "string",
            "description": "For Statistics mode.",
            "default": "department"
          },
          "maxResults": {
            "title": "Maximum results",
            "minimum": 1,
            "maximum": 20000,
            "type": "integer",
            "description": "Stations or statistics rows.",
            "default": 50
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}