/warehouses/ping
endpoint¶
The /warehouses/ping
endpoint accepts a POST
request with warehouse adapter parameters, and returns HTTP 204
if the credentials successfully authenticate. If not, the error indicates reason for authentication failure.
Note
No warehouse is created by this request.
Test creation of a warehouse¶
To test if a set of parameters could be used to create a new warehouse, submit a POST
request to /warehouses/ping
with a body identical to a POST /warehouses
request.
Endpoint | /warehouses/ping |
---|---|
Method | POST |
Auth | JWT |
Payload | Properties of the new warehouse object |
Required properties |
|
Success status | HTTP 204 |
Example
curl -X POST \
-H "Authorization: Bearer $JWT_TOKEN" \
-H "Content-Type: application/json" \
https://api.getdropstream.com/warehouses/ping \
-d @- <<EOF
{
"customer_id":"1234",
"name":"My Store",
"description":"My Sellbrite Store",
"platform":"sellbrite",
"adapter": {
"auth_token":"abc123xyz890",
"secret_key":"mysecret"
}
}
EOF
curl -X POST \
-H "Authorization: Bearer $JWT_TOKEN" \
https://api.getdropstream.com/warehouses/ping \
-d @- <<EOF
customer_id=1234&
name=My New Store&
platform=sellbrite&
adapter[auth_token]=abc123xyz890&
adapter[secret_key]=mysecret
EOF
Response if warehouse creation would have been successful:
HTTP/1.1 204 No Content