With the Locations API, site owners can define multiple physical locations for their business. This allows them to set individual opening hours for each location.
The Locations API allows you to:
- Get, list, and query existing locations.
- Create, update, and archive locations.
- Set a default location that is reflected in the site properties.
Learn more about how site owners can manage their location-specific bookings.
- Default location: Location reflected in the site properties. This location is used on invoices.
- Type: Describes whether a location is an office, reception, branch or the headquarters.
- Status: Indicates whether a location is
ACTIVE
or INACTIVE
.
- Business Schedule: Describes the location's regular and exceptional opening hours.
- Period: Regular, weekly opening hours of the location.
- Special Hour Period: Exception to the location's regular hours. The location can be either open or closed during the Special Hour Period.
It’s important to note the following points before starting to code:
- The Wix Bookings API doesn't support the
businessSchedule
object.
- You can't delete a location. Instead, you can archive a location using the
archiveLocation()
function.
- You can't archive the default location.
- Archived locations can't be unarchived.
- The
updateLocation()
function replaces an existing location with a new location. Currently, you can't partially update a location.
- Currently, the location type is just informational and doesn't affect a location's functionality.
- The status
INACTIVE
isn't currently supported.