<- Customer Custom Attributes API

Customer Custom Attributes API

Retrieve customer custom attribute definition

GET

 /v2/customers/custom-attribute-definitions/{key}

To retrieve a custom attribute definition created by another application, the visibility setting must be VISIBILITY_READ_ONLY or VISIBILITY_READ_WRITE_VALUES. Note that seller-defined custom attributes (also known as custom fields) are always set to VISIBILITY_READ_WRITE_VALUES.

Permissions:CUSTOMERS_READ
Link to section

Path parameters

Example code

Link to section

key

string

Required

The key of the custom attribute definition to retrieve. If the requesting application is not the definition owner, you must use the qualified key.

Link to section

Query parameters

Link to section

version

integer(32-bit)

The current version of the custom attribute definition, which is used for strongly consistent reads to guarantee that you receive the most up-to-date data. When included in the request, Square returns the specified version or a higher version if one exists. If the specified version is higher than the current version, Square returns a BAD_REQUEST error.

Link to section

Response fields

Link to section

custom_attribute_definition

The retrieved custom attribute definition.

Link to section

errors

Any errors that occurred during the request.