# Get a list of locations

Get a list of locations with data

Endpoint: GET /locations
Version: 1.0.0
Security: BearerPartner

## Security:

  - `BearerPartner` (unknown)
    http bearer Bearer {PartnerToken}

## Query parameters:

  - `id` (number)
    Filter by location ID

  - `group_id` (number)
    Filter by location chain ID *Default: 83*

  - `my` (number)
    For authorized user only. If you need locations that the user has rights to manage

  - `active` (number)
    If you need to get only locations with an active license and an available appointment

  - `forBooking` (number)
    Include date and time of the next free session in the location (ISO8601)

  - `show_groups` (number)
    Include in the location object a list of chains that this location belongs to

  - `city_id` (number)
    Filter by city ID ([cities getting method](#cities))

  - `showBookforms` (number)
    Include in the location object a list of location online booking forms

  - `min_id` (number)
    Filter by minimum location ID

  - `show_deleted` (number)
    Include deleted locations

  - `hide_record_type_single` (number)
    Hide locations with individual appointment

  - `hide_record_type_activity` (number)
    Hide locations with group appointment

  - `hide_record_type_mixed` (number)
    Hide locations with mixed appointment

  - `business_group_id` (number)
    Filter by business group ID

  - `business_type_id` (number)
    Filter by business type ID

  - `include` (array)
    Include additional data in the location object

  - `count` (number)
    Number of locations per page

  - `page` (number)
    Page number

## Header parameters:

  - `Accept` (string, required)
    Must be `application/vnd.api.v2+json`

  - `Content-Type` (string, required)
    Must be `application/json`

  - `Authorization` (string, required)
    Bearer partner_token

## Response 200:

  - `200` (unknown)
    OK

## Response 200 fields (application/json):

  - `success` (boolean)
    Success status (true)

  - `data` (array)
    Array of objects

  - `data.id` (number)
    location ID

  - `data.title` (string)
    location name

  - `data.public_title` (string)
    Public display name of the location

  - `data.short_descr` (string)
    location category

  - `data.logo` (string)
    location logo image address

  - `data.active` (integer)
    Is the location active (1 = active, 0 = inactive)

  - `data.phone` (string)
    location phone number

  - `data.phones` (array)
    Array of location phone numbers

  - `data.email` (string)
    Location email address

  - `data.country_id` (number)
    Identifier of the country in which the location is located

  - `data.schedule` (string)
    location schedule

  - `data.country` (string)
    location country name

  - `data.city_id` (number)
    City ID where the location is located

  - `data.city` (string)
    location city name

  - `data.timezone` (number)
    Timezone offset in hours

  - `data.timezone_name` (string)
    timezone locations

  - `data.address` (string)
    Address where the location is located

  - `data.coordinate_lat` (number)
    Latitude

  - `data.coordinate_lon` (number)
    Longitude

  - `data.phone_confirmation` (boolean)
    Do I need to confirm my phone number via SMS when appointment?

  - `data.active_staff_count` (number)
    Number of team members available for appointment

  - `data.next_slot` (string)
    Date and time of the next free session in the location (ISO8601). The field will be present only if the GET parameter forBooking=1 is passed

  - `data.app_ios` (string)
    Link to iOS App

  - `data.app_android` (string)
    Link to app for Android

  - `data.currency_short_title` (string)
    Abbreviated currency name

  - `data.reminds_sms_disabled` (boolean)
    SMS reminders disabled

  - `data.reminds_sms_default` (integer)
    Default SMS reminder setting

  - `data.group_priority` (number)
    The higher the priority, the higher the location when displayed in the list of chain locations

  - `data.bookform_group_priority` (number)
    Priority for booking form display

  - `data.description` (string)
    Full HTML description of the location

  - `data.photos` (array)
    Array of location photo paths

  - `data.company_photos` (array)
    Array of full location photo URLs

  - `data.booking_widget_promo` (object | null)
    Booking widget promo configuration

  - `meta` (array)
    Metadata (empty array)

## Response 401:

  - `401` (unknown)
    Unauthorized

## Response 401 fields (application/json):

  - `success` (boolean)
    Response status.
    Example: false

  - `data` (object | null)
    Response data.
    Example: null

  - `meta` (object)
    Additional response data.

  - `meta.message` (string)
    Error message.
    Example: Authentication needed.

