{
  "openapi": "3.0.1",
  "info": {
    "title": "Rome2Rio API Scraper",
    "description": "Search Rome2Rio for transport routes between any two places worldwide. Get detailed route options including duration, price, transport modes, operators, segments, and geo coordinates.",
    "version": "0.0",
    "x-build-id": "hQsFbBJnn1uio9QT9"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/rl1987~rome2rio-api-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-rl1987-rome2rio-api-scraper",
        "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/rl1987~rome2rio-api-scraper/runs": {
      "post": {
        "operationId": "runs-sync-rl1987-rome2rio-api-scraper",
        "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/rl1987~rome2rio-api-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-rl1987-rome2rio-api-scraper",
        "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": {
          "trips": {
            "title": "Trips",
            "type": "array",
            "description": "One trip per line as \"Origin -> Destination\", e.g. \"London -> Paris\". Place names, addresses, airports or \"lat,lng\" coordinates all work. Takes priority over the single Origin/Destination fields below.",
            "items": {
              "type": "string"
            }
          },
          "origin": {
            "title": "Origin",
            "type": "string",
            "description": "Single-trip origin — a place name, address, airport or \"lat,lng\". Ignored when Trips is set."
          },
          "destination": {
            "title": "Destination",
            "type": "string",
            "description": "Single-trip destination — a place name, address, airport or \"lat,lng\". Ignored when Trips is set."
          },
          "includeSchedules": {
            "title": "Include timetabled departures",
            "type": "boolean",
            "description": "Add real departure times for each schedulable route (train/bus/ferry). One extra API call per route.",
            "default": false
          },
          "includeBookable": {
            "title": "Include bookable fares + booking links",
            "type": "boolean",
            "description": "Add bookable departures with fares and partner booking deep links (Omio and friends). One extra API call per route.",
            "default": false
          },
          "departureDate": {
            "title": "Departure date",
            "type": "string",
            "description": "Date for the timetables, as YYYY-MM-DD (optionally YYYY-MM-DDTHH:MM). Defaults to now. Only used when departures or fares are enabled."
          },
          "currency": {
            "title": "Currency",
            "type": "string",
            "description": "ISO currency code for indicative prices and fares, e.g. USD, EUR, GBP.",
            "default": "USD"
          },
          "language": {
            "title": "Language",
            "type": "string",
            "description": "ISO language code for place and route names, e.g. en, de, fr.",
            "default": "en"
          },
          "maxItems": {
            "title": "Max items",
            "type": "integer",
            "description": "Maximum route rows to return across all trips. 0 = no limit.",
            "default": 100
          },
          "includeHotels": {
            "title": "Also scrape hotels at each destination",
            "type": "boolean",
            "description": "After the routes for a trip, emit hotel rows for its destination — name, stars, review score and nightly rate from Rome2Rio's hotel provider (Booking.com). Billed as a separate hotel-row event.",
            "default": false
          },
          "checkIn": {
            "title": "Hotel check-in date",
            "type": "string",
            "description": "Check-in date as YYYY-MM-DD. Defaults to 30 days from the run. Only used when hotels are enabled."
          },
          "checkOut": {
            "title": "Hotel check-out date",
            "type": "string",
            "description": "Check-out date as YYYY-MM-DD. Defaults to two nights after check-in. Only used when hotels are enabled."
          },
          "hotelAdults": {
            "title": "Adults per room",
            "type": "integer",
            "description": "Number of adults for the hotel availability search.",
            "default": 2
          },
          "maxHotelsPerTrip": {
            "title": "Max hotels per trip",
            "type": "integer",
            "description": "How many hotel rows to emit for each destination.",
            "default": 20
          },
          "proxyConfiguration": {
            "title": "Proxy configuration",
            "type": "object",
            "description": "Route requests through Apify Proxy. The default (datacenter) is measured to work fine — Rome2Rio's mobile API applies no IP-reputation blocking, and datacenter runs ~6x faster than residential (p50 0.28s vs 1.62s). Pick RESIDENTIAL only if you need a specific country's pricing/availability; it also draws on your residential GB quota (~133 KB per trip).",
            "default": {
              "useApifyProxy": true
            }
          }
        }
      },
      "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
                  }
                }
              },
              "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}