/stores/ping
endpoint¶
The /stores/ping
endpoint accepts a POST
request with store adapter parameters, and returns HTTP 204
if the credentials successfully authenticate. If not, the error indicates reason for authentication failure.
Note
No store is created by this request.
Test creation of a store¶
To test if a set of parameters could be used to create a new store, submit a POST
request to /stores/ping
with a body identical to a POST /stores
request.
Endpoint | /stores/ping |
---|---|
Method | POST |
Auth | JWT |
Payload | Properties of the new store 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/stores/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/stores/ping \
-d @- <<EOF
customer_id=1234&
name=My New Store&
platform=sellbrite&
adapter[auth_token]=abc123xyz890&
adapter[secret_key]=mysecret
EOF
Response if store creation would have been successful:
HTTP/1.1 204 No Content