{
  "openapi": "3.0.1",
  "info": {
    "title": "HotPepper Gourmet Japan Restaurant Scraper",
    "description": "Get Japan restaurant data and leads from HotPepper Gourmet (ホットペッパーグルメ): name, phone number, genre, nearest station, budget, photo and any coupon. Turn on detail pages for address, opening hours, seats and parking. Search all 47 prefectures, like Tokyo or Osaka, by cuisine (izakaya, ramen) or area.",
    "version": "1.0",
    "x-build-id": "KT0cBpROLkRGu4umw"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/piquno~hotpepper-gourmet-japan-restaurant-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-piquno-hotpepper-gourmet-japan-restaurant-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/piquno~hotpepper-gourmet-japan-restaurant-scraper/runs": {
      "post": {
        "operationId": "runs-sync-piquno-hotpepper-gourmet-japan-restaurant-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/piquno~hotpepper-gourmet-japan-restaurant-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-piquno-hotpepper-gourmet-japan-restaurant-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",
        "required": [
          "prefecture"
        ],
        "properties": {
          "prefecture": {
            "title": "Prefecture",
            "enum": [
              "SA11",
              "SA12",
              "SA13",
              "SA14",
              "SA15",
              "SA16",
              "SA17",
              "SA21",
              "SA22",
              "SA23",
              "SA24",
              "SA25",
              "SA26",
              "SA31",
              "SA32",
              "SA33",
              "SA34",
              "SA41",
              "SA51",
              "SA52",
              "SA53",
              "SA54",
              "SA55",
              "SA56",
              "SA61",
              "SA62",
              "SA63",
              "SA64",
              "SA65",
              "SA66",
              "SA71",
              "SA72",
              "SA73",
              "SA74",
              "SA75",
              "SA81",
              "SA82",
              "SA83",
              "SA84",
              "SA91",
              "SA92",
              "SA93",
              "SA94",
              "SA95",
              "SA96",
              "SA97",
              "SA98"
            ],
            "type": "string",
            "description": "Japanese prefecture to search. Covers all 47 prefectures.",
            "default": "SA11"
          },
          "genre": {
            "title": "Genre / Cuisine",
            "enum": [
              "",
              "G001",
              "G002",
              "G003",
              "G004",
              "G005",
              "G006",
              "G007",
              "G008",
              "G017",
              "G009",
              "G010",
              "G011",
              "G012",
              "G013",
              "G016",
              "G014",
              "G015"
            ],
            "type": "string",
            "description": "Cuisine type. Leave 'Any' to include all genres.",
            "default": ""
          },
          "subArea": {
            "title": "Sub-Area Code (Optional)",
            "type": "string",
            "description": "Narrower area within the prefecture, as HotPepper's area code. Examples: Y055=Shinjuku, Y030=Shibuya, Y050=Ikebukuro, Y005=Ginza/Yurakucho, Y045=Roppongi, Y035=Harajuku/Aoyama. To find another code, open the area on hotpepper.jp and copy the Y-code from the address (for example www.hotpepper.jp/SA11/Y055/). A wrong code gives 0 restaurants, and the run ends as Failed with a status message that says so. Leave blank for the whole prefecture.",
            "default": ""
          },
          "startUrls": {
            "title": "Start URLs (Advanced — Optional)",
            "type": "array",
            "description": "Paste one or more www.hotpepper.jp search-result links to scrape directly. Useful if you've built a custom filter on the site (e.g. with budget, amenities, station). When set, this overrides the prefecture/genre/sub-area fields. Links that contain '?' are paged by following HotPepper's own next-page links. Keyword-search links (addresses under /CSP/ or containing /fwt) are not supported, because hotpepper.jp's robots.txt disallows them.",
            "default": [],
            "items": {
              "type": "object",
              "required": [
                "url"
              ],
              "properties": {
                "url": {
                  "type": "string",
                  "title": "URL of a web page",
                  "format": "uri"
                }
              }
            }
          },
          "maxResults": {
            "title": "Max Results",
            "minimum": 1,
            "maximum": 5000,
            "type": "integer",
            "description": "Maximum number of restaurants to scrape per URL (each start URL gets up to this many). Each restaurant saved is one billed result. With detail pages on, a run handles about 1,500 restaurants per hour, so raise the run timeout for bigger detail runs.",
            "default": 100
          },
          "includeDetails": {
            "title": "Include Detail Pages",
            "type": "boolean",
            "description": "Also open each restaurant's own page for the full address, opening hours, closed days, seats, private rooms, parking, smoking rules, credit cards, rating and review count. Same price per restaurant, but about 2 seconds per restaurant (roughly 10 times slower than without).",
            "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}