Square: Vendors schemas
19 Square schemas with complete fields and constraints.
← Vendors operations · All schemas
Bulk Create Vendors — request body — body
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Represents an input to a call to [BulkCreateVendors](api-endpoint:Vendors-BulkCreateVendors). |
vendors | object | Required within parent | Specifies a set of new [Vendor](entity:Vendor) objects as represented by a collection of idempotency-key/`Vendor`-object pairs. Additional keys: see wildcard field |
vendors.* | Model | Additional keys | Expand Create Vendor — request body — body vendor |
Referenced models: Create Vendor — request body — body vendor
Bulk Create Vendors — response body
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Represents an output from a call to [BulkCreateVendors](api-endpoint:Vendors-BulkCreateVendors). |
errors | array | Optional | Any errors that occurred during the request. |
errors[] | Model | Each item | Expand Get Shift — response body — errors item |
responses | object | Optional | A set of [CreateVendorResponse](entity:CreateVendorResponse) objects encapsulating successfully created [Vendor](entity:Vendor) objects or error responses for failed attempts. The set is represented by a collection of idempotency-key/`Vendor`-object or idempotency-key/error-object pairs. The idempotency keys correspond to those specified in the input. Additional keys: see wildcard field |
responses.* | Model | Additional keys | Expand Create Vendor — response body |
Referenced models: Create Vendor — response body, Get Shift — response body — errors item
Bulk Retrieve Vendors — request body — body
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Represents an input to a call to [BulkRetrieveVendors](api-endpoint:Vendors-BulkRetrieveVendors). |
vendor_ids | JSON | Optional | |
vendor_ids (anyOf 1) | array | Alternative | IDs of the [Vendor](entity:Vendor) objects to retrieve. |
vendor_ids (anyOf 1)[] | string | Each item | |
vendor_ids (anyOf 2) | null | Alternative |
Bulk Retrieve Vendors — response body
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Represents an output from a call to [BulkRetrieveVendors](api-endpoint:Vendors-BulkRetrieveVendors). |
errors | array | Optional | Any errors that occurred during the request. |
errors[] | Model | Each item | Expand Get Shift — response body — errors item |
responses | object | Optional | The set of [RetrieveVendorResponse](entity:RetrieveVendorResponse) objects encapsulating successfully retrieved [Vendor](entity:Vendor) objects or error responses for failed attempts. The set is represented by a collection of `Vendor`-ID/`Vendor`-object or `Vendor`-ID/error-object pairs. Additional keys: see wildcard field |
responses.* | Model | Additional keys | Expand Retrieve Vendor — response body |
Referenced models: Get Shift — response body — errors item, Retrieve Vendor — response body
Bulk Update Vendors — request body — body
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Represents an input to a call to [BulkUpdateVendors](api-endpoint:Vendors-BulkUpdateVendors). |
vendors | object | Required within parent | A set of [UpdateVendorRequest](entity:UpdateVendorRequest) objects encapsulating to-be-updated [Vendor](entity:Vendor) objects. The set is represented by a collection of `Vendor`-ID/`UpdateVendorRequest`-object pairs. Additional keys: see wildcard field |
vendors.* | Model | Additional keys | Expand Update Vendor — request body — body |
Referenced models: Update Vendor — request body — body
Bulk Update Vendors — response body
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Represents an output from a call to [BulkUpdateVendors](api-endpoint:Vendors-BulkUpdateVendors). |
errors | array | Optional | Errors encountered when the request fails. |
errors[] | Model | Each item | Expand Get Shift — response body — errors item |
responses | object | Optional | A set of [UpdateVendorResponse](entity:UpdateVendorResponse) objects encapsulating successfully created [Vendor](entity:Vendor) objects or error responses for failed attempts. The set is represented by a collection of `Vendor`-ID/`UpdateVendorResponse`-object or `Vendor`-ID/error-object pairs. Additional keys: see wildcard field |
responses.* | Model | Additional keys | Expand Update Vendor — response body |
Referenced models: Get Shift — response body — errors item, Update Vendor — response body
Create Vendor — request body — body
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Represents an input to a call to [CreateVendor](api-endpoint:Vendors-CreateVendor). |
idempotency_key | string | Required within parent | A client-supplied, universally unique identifier (UUID) to make this [CreateVendor](api-endpoint:Vendors-CreateVendor) call idempotent. See [Idempotency](https://developer.squareup.com/docs/build-basics/common-api-patterns/idempotency) in the [API Development 101](https://developer.squareup.com/docs/buildbasics) section for more information. Maximum length: 128 Minimum length: 1 |
vendor | Model | Optional | Expand Create Vendor — request body — body vendor The requested [Vendor](entity:Vendor) to be created. |
Referenced models: Create Vendor — request body — body vendor
Create Vendor — request body — body vendor
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Represents a supplier to a seller. |
account_number | JSON | Optional | |
account_number (anyOf 1) | string | Alternative | The account number of the [Vendor](entity:Vendor). Maximum length: 100 |
account_number (anyOf 2) | null | Alternative | |
address | JSON | Optional | |
address (anyOf 1) | Model | Alternative | Expand Create Customer — request body — body address The address of the [Vendor](entity:Vendor). |
address (anyOf 2) | null | Alternative | |
contacts | JSON | Optional | |
contacts (anyOf 1) | array | Alternative | The contacts of the [Vendor](entity:Vendor). |
contacts (anyOf 1)[] | Model | Each item | Expand Create Vendor — request body — body vendor contacts The contacts of the Vendor (entity:Vendor) item |
contacts (anyOf 2) | null | Alternative | |
created_at | string | Optional | An RFC 3339-formatted timestamp that indicates when the [Vendor](entity:Vendor) was created. Maximum length: 34 Read only: true |
id | string | Optional | A unique Square-generated ID for the [Vendor](entity:Vendor). This field is required when attempting to update a [Vendor](entity:Vendor). Maximum length: 100 |
name | JSON | Optional | |
name (anyOf 1) | string | Alternative | The name of the [Vendor](entity:Vendor). This field is required when attempting to create or update a [Vendor](entity:Vendor). Maximum length: 100 |
name (anyOf 2) | null | Alternative | |
note | JSON | Optional | |
note (anyOf 1) | string | Alternative | A note detailing information about the [Vendor](entity:Vendor). Maximum length: 4096 |
note (anyOf 2) | null | Alternative | |
status | JSON | Optional | |
status (anyOf 1) | string | Alternative | The status of the [Vendor](entity:Vendor), whether a [Vendor](entity:Vendor) is active or inactive. The status of the [Vendor](entity:Vendor). See [Status](#type-status) for possible values One of: ACTIVE, INACTIVE |
status (anyOf 2) | null | Alternative | |
updated_at | string | Optional | An RFC 3339-formatted timestamp that indicates when the [Vendor](entity:Vendor) was last updated. Maximum length: 34 Read only: true |
version | integer | Optional | The version of the [Vendor](entity:Vendor). |
Referenced models: Create Customer — request body — body address, Create Vendor — request body — body vendor contacts The contacts of the Vendor (entity:Vendor) item
Create Vendor — request body — body vendor contacts The contacts of the Vendor (entity:Vendor) item
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Represents a contact of a [Vendor](entity:Vendor). |
email_address | JSON | Optional | |
email_address (anyOf 1) | string | Alternative | The email address of the [VendorContact](entity:VendorContact). Maximum length: 255 |
email_address (anyOf 2) | null | Alternative | |
id | string | Optional | A unique Square-generated ID for the [VendorContact](entity:VendorContact). This field is required when attempting to update a [VendorContact](entity:VendorContact). Maximum length: 100 |
name | JSON | Optional | |
name (anyOf 1) | string | Alternative | The name of the [VendorContact](entity:VendorContact). This field is required when attempting to create a [Vendor](entity:Vendor). Maximum length: 255 |
name (anyOf 2) | null | Alternative | |
ordinal | integer | Required within parent | The ordinal of the [VendorContact](entity:VendorContact). |
phone_number | JSON | Optional | |
phone_number (anyOf 1) | string | Alternative | The phone number of the [VendorContact](entity:VendorContact). Maximum length: 255 |
phone_number (anyOf 2) | null | Alternative | |
removed | JSON | Optional | |
removed (anyOf 1) | boolean | Alternative | The state of the [VendorContact](entity:VendorContact). |
removed (anyOf 2) | null | Alternative |
Create Vendor — response body
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Represents an output from a call to [CreateVendor](api-endpoint:Vendors-CreateVendor). |
errors | array | Optional | Errors encountered when the request fails. |
errors[] | Model | Each item | Expand Get Shift — response body — errors item |
vendor | Model | Optional | Expand Create Vendor — response body — vendor The successfully created [Vendor](entity:Vendor) object. |
Referenced models: Get Shift — response body — errors item, Create Vendor — response body — vendor
Create Vendor — response body — vendor
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Represents a supplier to a seller. |
account_number | JSON | Optional | |
account_number (anyOf 1) | string | Alternative | The account number of the [Vendor](entity:Vendor). Maximum length: 100 |
account_number (anyOf 2) | null | Alternative | |
address | JSON | Optional | |
address (anyOf 1) | Model | Alternative | Expand Get Payment — response body — payment billing address The address of the [Vendor](entity:Vendor). |
address (anyOf 2) | null | Alternative | |
contacts | JSON | Optional | |
contacts (anyOf 1) | array | Alternative | The contacts of the [Vendor](entity:Vendor). |
contacts (anyOf 1)[] | Model | Each item | Expand Create Vendor — response body — vendor contacts The contacts of the Vendor (entity:Vendor) item |
contacts (anyOf 2) | null | Alternative | |
created_at | string | Optional | An RFC 3339-formatted timestamp that indicates when the [Vendor](entity:Vendor) was created. Maximum length: 34 Read only: true |
id | string | Optional | A unique Square-generated ID for the [Vendor](entity:Vendor). This field is required when attempting to update a [Vendor](entity:Vendor). Maximum length: 100 |
name | JSON | Optional | |
name (anyOf 1) | string | Alternative | The name of the [Vendor](entity:Vendor). This field is required when attempting to create or update a [Vendor](entity:Vendor). Maximum length: 100 |
name (anyOf 2) | null | Alternative | |
note | JSON | Optional | |
note (anyOf 1) | string | Alternative | A note detailing information about the [Vendor](entity:Vendor). Maximum length: 4096 |
note (anyOf 2) | null | Alternative | |
status | JSON | Optional | |
status (anyOf 1) | string | Alternative | The status of the [Vendor](entity:Vendor), whether a [Vendor](entity:Vendor) is active or inactive. The status of the [Vendor](entity:Vendor). See [Status](#type-status) for possible values Known values: ACTIVE, INACTIVE |
status (anyOf 2) | null | Alternative | |
updated_at | string | Optional | An RFC 3339-formatted timestamp that indicates when the [Vendor](entity:Vendor) was last updated. Maximum length: 34 Read only: true |
version | JSON | Optional | |
version (anyOf 1) | integer | Alternative | The version of the [Vendor](entity:Vendor). |
version (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
Referenced models: Get Payment — response body — payment billing address, Create Vendor — response body — vendor contacts The contacts of the Vendor (entity:Vendor) item
Create Vendor — response body — vendor contacts The contacts of the Vendor (entity:Vendor) item
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Represents a contact of a [Vendor](entity:Vendor). |
email_address | JSON | Optional | |
email_address (anyOf 1) | string | Alternative | The email address of the [VendorContact](entity:VendorContact). Maximum length: 255 |
email_address (anyOf 2) | null | Alternative | |
id | string | Optional | A unique Square-generated ID for the [VendorContact](entity:VendorContact). This field is required when attempting to update a [VendorContact](entity:VendorContact). Maximum length: 100 |
name | JSON | Optional | |
name (anyOf 1) | string | Alternative | The name of the [VendorContact](entity:VendorContact). This field is required when attempting to create a [Vendor](entity:Vendor). Maximum length: 255 |
name (anyOf 2) | null | Alternative | |
ordinal | JSON | Required within parent | |
ordinal (anyOf 1) | integer | Alternative | The ordinal of the [VendorContact](entity:VendorContact). |
ordinal (anyOf 2) | string | Alternative | Pattern: ^-?[0-9]+(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$ |
phone_number | JSON | Optional | |
phone_number (anyOf 1) | string | Alternative | The phone number of the [VendorContact](entity:VendorContact). Maximum length: 255 |
phone_number (anyOf 2) | null | Alternative | |
removed | JSON | Optional | |
removed (anyOf 1) | boolean | Alternative | The state of the [VendorContact](entity:VendorContact). |
removed (anyOf 2) | null | Alternative |
Retrieve Vendor — response body
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Represents an output from a call to [RetrieveVendor](api-endpoint:Vendors-RetrieveVendor). |
errors | array | Optional | Errors encountered when the request fails. |
errors[] | Model | Each item | Expand Get Shift — response body — errors item |
vendor | Model | Optional | Expand Create Vendor — response body — vendor The successfully retrieved [Vendor](entity:Vendor) object. |
Referenced models: Get Shift — response body — errors item, Create Vendor — response body — vendor
Search Vendors — request body — body
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Represents an input into a call to [SearchVendors](api-endpoint:Vendors-SearchVendors). |
cursor | string | Optional | A pagination cursor returned by a previous call to this endpoint. Provide this to retrieve the next set of results for the original query. See the [Pagination](https://developer.squareup.com/docs/working-with-apis/pagination) guide for more information. |
filter | Model | Optional | Expand Search Vendors — request body — body filter Specifies a filter used to search for vendors. |
sort | Model | Optional | Expand Search Vendors — request body — body sort Specifies a sorter used to sort the returned vendors. |
Referenced models: Search Vendors — request body — body filter, Search Vendors — request body — body sort
Search Vendors — request body — body filter
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Defines supported query expressions to search for vendors by. |
name | JSON | Optional | |
name (anyOf 1) | array | Alternative | The names of the [Vendor](entity:Vendor) objects to retrieve. |
name (anyOf 1)[] | string | Each item | |
name (anyOf 2) | null | Alternative | |
status | JSON | Optional | |
status (anyOf 1) | array | Alternative | The statuses of the [Vendor](entity:Vendor) objects to retrieve. See [VendorStatus](#type-vendorstatus) for possible values |
status (anyOf 1)[] | string | Each item | The status of the [Vendor](entity:Vendor), whether a [Vendor](entity:Vendor) is active or inactive. One of: ACTIVE, INACTIVE |
status (anyOf 2) | null | Alternative |
Search Vendors — request body — body sort
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Defines a sorter used to sort results from [SearchVendors](api-endpoint:Vendors-SearchVendors). |
field | JSON | Optional | |
field (anyOf 1) | string | Alternative | The field to sort the returned [Vendor](entity:Vendor) objects by. Specifies the sort key to sort the returned vendors. See [Field](#type-field) for possible values One of: NAME, CREATED_AT |
field (anyOf 2) | null | Alternative | |
order | JSON | Optional | |
order (anyOf 1) | string | Alternative | The order (e.g., chronological or alphabetical) in which results from a request are returned. Specifies the sort order for the returned vendors. See [SortOrder](#type-sortorder) for possible values One of: DESC, ASC |
order (anyOf 2) | null | Alternative |
Search Vendors — response body
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Represents an output from a call to [SearchVendors](api-endpoint:Vendors-SearchVendors). |
cursor | string | Optional | The pagination cursor to be used in a subsequent request. If unset, this is the final response. See the [Pagination](https://developer.squareup.com/docs/working-with-apis/pagination) guide for more information. |
errors | array | Optional | Errors encountered when the request fails. |
errors[] | Model | Each item | Expand Get Shift — response body — errors item |
vendors | array | Optional | The [Vendor](entity:Vendor) objects matching the specified search filter. |
vendors[] | Model | Each item | Expand Create Vendor — response body — vendor |
Referenced models: Get Shift — response body — errors item, Create Vendor — response body — vendor
Update Vendor — request body — body
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Represents an input to a call to [UpdateVendor](api-endpoint:Vendors-UpdateVendor). |
idempotency_key | JSON | Optional | |
idempotency_key (anyOf 1) | string | Alternative | A client-supplied, universally unique identifier (UUID) for the request. See [Idempotency](https://developer.squareup.com/docs/build-basics/common-api-patterns/idempotency) in the [API Development 101](https://developer.squareup.com/docs/buildbasics) section for more information. Maximum length: 128 |
idempotency_key (anyOf 2) | null | Alternative | |
vendor | Model | Required within parent | Expand Create Vendor — request body — body vendor The specified [Vendor](entity:Vendor) to be updated. |
Referenced models: Create Vendor — request body — body vendor
Update Vendor — response body
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Represents an output from a call to [UpdateVendor](api-endpoint:Vendors-UpdateVendor). |
errors | array | Optional | Errors occurred when the request fails. |
errors[] | Model | Each item | Expand Get Shift — response body — errors item |
vendor | Model | Optional | Expand Create Vendor — response body — vendor The [Vendor](entity:Vendor) that has been updated. |
Referenced models: Get Shift — response body — errors item, Create Vendor — response body — vendor