Bulk retrieve vendors BETA
POST
/v2/vendors/bulk-retrieve
Retrieves one or more vendors of specified Vendor IDs.
Name | Description |
---|---|
vendor_
|
IDs of the Vendor objects to retrieve. |
Response Fields
Name | Description |
---|---|
errors
|
Any errors that occurred during the request. |
responses
|
The set of RetrieveVendorResponse objects encapsulating successfully retrieved Vendor
objects or error responses for failed attempts. The set is represented by
a collection of |
Examples
POST
/v2/vendors/bulk-retrieve
cURL
- cURL
- Ruby
- Python
- C#
- Java
- PHP
- Node.js
curl https://connect.squareup.com/v2/vendors/bulk-retrieve \
-X POST \
-H 'Square-Version: 2023-01-19' \
-H 'Authorization: Bearer ACCESS_TOKEN' \
-H 'Content-Type: application/json' \
-d '{
"vendor_ids": [
"INV_V_JDKYHBWT1D4F8MFH63DBMEN8Y4"
]
}'
Response JSON
{
"errors": [],
"vendors": {
"INV_V_JDKYHBWT1D4F8MFH63DBMEN8Y4": {
"vendor": {
"id": "INV_V_JDKYHBWT1D4F8MFH63DBMEN8Y4",
"created_at": "2022-03-16T10:21:54.859Z",
"updated_at": "2022-03-16T10:21:54.859Z",
"name": "Joe's Fresh Seafood",
"address": {
"address_line_1": "505 Electric Ave",
"address_line_2": "Suite 600",
"locality": "New York",
"administrative_district_level_1": "NY",
"postal_code": "10003",
"country": "US"
},
"contacts": [
{
"id": "INV_VC_FMCYHBWT1TPL8MFH52PBMEN92A",
"name": "Joe Burrow",
"email_address": "joe@joesfreshseafood.com",
"phone_number": "1-212-555-4250"
}
],
"account_number": "4025391",
"note": "a vendor",
"version": 1,
"status": "ACTIVE"
}
}
}
}