<- Booking Custom Attributes API

Booking Custom Attributes API

List booking custom attributes

GET

 /v2/bookings/{booking_id}/custom-attributes

Lists a booking's custom attributes.

To call this endpoint with buyer-level permissions, set APPOINTMENTS_READ for the OAuth scope. To call this endpoint with seller-level permissions, set APPOINTMENTS_ALL_READ and APPOINTMENTS_READ for the OAuth scope.

Permissions:APPOINTMENTS_READ
Try in API Explorer
Link to section

Path parameters

Example code

Link to section

booking_id

string

Required

Link to section

Query parameters

Link to section

limit

integer(32-bit)

The maximum number of results to return in a single paged response. This limit is advisory. The response might contain more or fewer results. The minimum value is 1 and the maximum value is 100. The default value is 20. For more information, see Pagination.

Link to section

cursor

string

The cursor returned in the paged response from the previous call to this endpoint. Provide this cursor to retrieve the next page of results for your original request. For more information, see Pagination.

Link to section

with_definitions

boolean

Indicates whether to return the custom attribute definition in the definition field of each custom attribute. Set this parameter to true to get the name and description of each custom attribute, information about the data type, or other definition details. The default value is false.

Link to section

Response fields

Link to section

custom_attributes

The retrieved custom attributes. If with_definitions was set to true in the request, the custom attribute definition is returned in the definition field of each custom attribute.

If no custom attributes are found, Square returns an empty object ({}).

Link to section

cursor

string

The cursor to use in your next call to this endpoint to retrieve the next page of results for your original request. This field is present only if the request succeeded and additional results are available. For more information, see Pagination.

Link to section

errors

Any errors that occurred during the request.