General details on API communications
How to make API requests?
Each API request should include your identity by specifying AppID and Signature.
- The AppID is static value which can be taken from your API Settings page.
- The Secret Key is auto-generated value which can be taken from your API Settings page.
The Signature value will need to be generated on your end as SHA1 (request body + Secret Key).
NOTE: The request body value is different for POST and GET methods:
If the POST method is used, the request body should include the entire content of the request.
If the GET method is used, the request body should include everything after the "?" symbol, excluding your Signature parameter.
Requests can be made in either JSON or XML:
Requests: Requests sent using GET can use either JSON or XML formats. If you're using POST you'll need to specify the format of your requests using Content-Type. All answers to these requests will be in the same format as the format of request.
Answers: If you're using GET, the format of answers will need to be specified using the 'format' parameter. You can use either 'JSON' or 'XML' as the value - if omitted this will default to 'JSN'.
Creating and processing orders
What can you do with Order?
The API lets you do the following with the Order resource. More detailed versions of these general actions may be available:
- GET /api/orders.php
Retrieve a list of Orders
- GET /api/order.php
Receive a single Order
- GET /api/orders/count.php
Receive a count of all Orders
- POST /api/orders.php
Create a new Order
- DELETE /api/orders.php
Remove a Order from the database
A unique numeric identifier for the order. This one is used by the shop owner and customer.
A unique numeric identifier for the internal customer order.
By default, this auto-generated property is the date and time when the order was created in Snuggle.Partners, in ISO 8601 format.
If the order was cancelled, this value is "true."
The name of one of the brands created on your profile page https://www.snugglepartners.co.uk/my-brands
The billing address associated with the creator account. This auto-generated property based on your profile details https://www.snugglepartners.co.uk/profile. It has the following properties:
The mailing address to where the order will be shipped. It has the following properties:
A list of line item objects, each one containing information about an item in the order. Each item object has the following properties:
A order summary information. It has the following properties:
The shipping details. It has the following properties:
An object containing information about the payment status. It has the following properties:
|Retrieve a list of Orders|
|ids||A comma-separated list of order ids|
|limit||Amount of results
(default: 50) (maximum: 250)
|page||Page to show
|since_id||Restrict results to after the specified ID|
|created_at_min||Show orders created after date (format: 2014-04-25T16:15:47-04:00)|
|created_at_max||Show orders created before date (format: 2014-04-25T16:15:47-04:00)|
|List all orders
|List all orders after the specified ID
|List of specific orders in XML format
|Retrieve a specific order|
|Get a representation of a single order
|Get a representation of a single order in XML format
|Receive a count of all Orders|
|since_id||Count orders created after the specified ID|
|created_at_min||Count orders created after date (format: 2014-04-25T16:15:47-04:00)|
|created_at_max||Count orders created before date (format: 2014-04-25T16:15:47-04:00)|
|status||Count orders with status:
|Count all orders
|Count all paid orders
|Create a new order|
|order||Order details - please see Order properties|
|Creating an order (JSON format)
|Creating an order (XML format)
|Delete an order. Only supported for non paid orders.|
|Delete an order