---
agentTools:
  projectIndex: https://keytocheck.readme.io/llms.txt
---

# /locations

# OpenAPI definition

```json
{
  "openapi": "3.0.3",
  "info": {
    "title": "KeyToCheck",
    "description": "KeyToCheck API",
    "version": "1.0.0"
  },
  "servers": [
    {
      "url": "https://api.keytocheck.com/api",
      "description": "Main (production) server"
    },
    {
      "url": "https://apisandbox.keytocheck.com/api",
      "description": "Sandbox server for testing"
    }
  ],
  "paths": {
    "/locations": {
      "get": {
        "tags": [
          "Location"
        ],
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "parameters": [
          {
            "$ref": "#/components/parameters/PageQueryParameter"
          },
          {
            "$ref": "#/components/parameters/LimitQueryParameter"
          }
        ],
        "responses": {
          "200": {
            "$ref": "#/components/responses/LocationListResponse"
          },
          "400": {
            "$ref": "#/components/responses/ListErrorResponse"
          },
          "401": {
            "$ref": "#/components/responses/BadTokenErrorResponse"
          },
          "500": {
            "$ref": "#/components/responses/ErrorResponse"
          }
        }
      }
    }
  },
  "components": {
    "schemas": {
      "Location": {
        "type": "object",
        "required": [
          "id",
          "name",
          "street",
          "zip",
          "city",
          "country",
          "tourism_tax",
          "caution",
          "cleaning_cost",
          "collect_tax collect_caution",
          "metadata"
        ],
        "properties": {
          "id": {
            "type": "string",
            "nullable": false
          },
          "name": {
            "type": "string",
            "nullable": false
          },
          "street": {
            "type": "string",
            "nullable": false
          },
          "zip": {
            "type": "string",
            "nullable": false
          },
          "city": {
            "type": "string",
            "nullable": false
          },
          "country": {
            "type": "string",
            "nullable": false
          },
          "tourism_tax": {
            "type": "number",
            "nullable": true
          },
          "caution": {
            "type": "number",
            "nullable": true
          },
          "cleaning_cost": {
            "type": "number",
            "nullable": true
          },
          "collect_tax": {
            "type": "boolean",
            "nullable": false
          },
          "collect_caution": {
            "type": "boolean",
            "nullable": false
          },
          "metadata": {
            "type": "object",
            "nullable": false,
            "additionalProperties": true
          }
        }
      }
    },
    "securitySchemes": {
      "bearerAuth": {
        "type": "http",
        "scheme": "bearer",
        "bearerFormat": "JWT"
      }
    },
    "parameters": {
      "PageQueryParameter": {
        "in": "query",
        "name": "page",
        "required": false,
        "schema": {
          "type": "integer",
          "minimum": 1,
          "default": 1,
          "nullable": false
        }
      },
      "LimitQueryParameter": {
        "in": "query",
        "name": "limit",
        "required": false,
        "schema": {
          "type": "integer",
          "minimum": 1,
          "default": 50,
          "nullable": false
        }
      }
    },
    "responses": {
      "ErrorResponse": {
        "description": "",
        "content": {
          "application/json": {
            "schema": {
              "type": "object",
              "required": [
                "success",
                "error",
                "message"
              ],
              "properties": {
                "success": {
                  "type": "boolean",
                  "default": false,
                  "nullable": false
                },
                "error": {
                  "type": "integer",
                  "default": 500,
                  "nullable": false
                },
                "message": {
                  "type": "string",
                  "nullable": false
                }
              }
            }
          }
        }
      },
      "BadTokenErrorResponse": {
        "description": "Access token is missing or invalid",
        "content": {
          "application/json": {
            "schema": {
              "type": "object",
              "required": [
                "success",
                "error",
                "message"
              ],
              "properties": {
                "success": {
                  "type": "boolean",
                  "default": false,
                  "nullable": false
                },
                "error": {
                  "type": "integer",
                  "default": 401,
                  "nullable": false
                },
                "message": {
                  "type": "string",
                  "default": "error.bad-token",
                  "nullable": false
                }
              }
            }
          }
        }
      },
      "ListErrorResponse": {
        "description": "",
        "content": {
          "application/json": {
            "schema": {
              "type": "object",
              "required": [
                "success",
                "error",
                "message"
              ],
              "properties": {
                "success": {
                  "type": "boolean",
                  "default": false,
                  "nullable": false
                },
                "error": {
                  "type": "integer",
                  "default": 400,
                  "nullable": false
                },
                "message": {
                  "type": "string",
                  "nullable": false,
                  "enum": [
                    "error.page-not-valid",
                    "error.limit-not-valid"
                  ]
                }
              }
            }
          }
        }
      },
      "LocationListResponse": {
        "description": "",
        "content": {
          "application/json": {
            "schema": {
              "type": "object",
              "required": [
                "success",
                "data"
              ],
              "properties": {
                "success": {
                  "type": "boolean",
                  "default": true,
                  "nullable": false
                },
                "data": {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/Location"
                  },
                  "nullable": false
                }
              }
            }
          }
        }
      }
    }
  },
  "x-readme": {
    "explorer-enabled": true,
    "proxy-enabled": true
  },
  "_id": {
    "buffer": {
      "0": 101,
      "1": 114,
      "2": 232,
      "3": 241,
      "4": 248,
      "5": 91,
      "6": 51,
      "7": 0,
      "8": 22,
      "9": 97,
      "10": 214,
      "11": 14
    }
  }
}
```