Use this endpoint to query packing slips.
List packing slips
GET: /wp-json/sab/v1/packing_slips/
Properties
Scope under which the request is made; determines fields present in response. Options: view
Current page of the collection. Default is 1
Maximum number of items to be returned in result set. Default is 10
Limit results to those matching a string.
Limit response to resources published after a given ISO8601 compliant date.
Limit response to resources published before a given ISO8601 compliant date.
Ensure result set excludes specific IDs.
Limit result set to specific ids.
Offset the result set by a specific number of items.
Order sort attribute ascending or descending. Options: desc
Sort collection by object attribute. Options: date
Limit result set to documents which have specific statuses. Default is any
Limit result set to documents which have a specific reference id.
Limit result set to documents which have a specific reference type.
Limit result set to packing slips belonging to a certain order.
exclude properties
exclude item.
include properties
include item.
status properties
status item. Options:
Example
This is an example request which retrieves packing slips associated with a certain shipment.
curl https://example.com/wp-json/sab/v1/packing_slips/?reference_id=<shipment_id>
Manage packing slips
Retrieve, update or delete a packing slip.
GET|POST|PUT|PATCH|DELETE: /wp-json/sab/v1/packing_slips/<id>
Properties
Unique identifier for the resource.
Parent document ID.
The reference id linked to the document.
The reference type linked to the document.
The reference formatted number linked to the document.
The document number.
The formatted document number.
Shows where the document was created.
The current document status. Options: closed
The date the document was created, in the site’s timezone.
The date the document was created, as GMT.
The date the document was last modified, in the site’s timezone.
The date the document was last modified, as GMT.
The date the document was sent, in the site’s timezone.
The date the document was sent, as GMT.
User ID linked to the document. 0 for guests.
Author ID linked to the document.
Relative path to PDF file.
Absolute path to PDF file.
The journal type for numbering purposes.
The document version.
The document country.
Formatted address data.
Address data.
Attachments.
Meta data.
address properties
First name.
Last name.
Company name.
Address line 1.
Address line 2.
City name.
ISO code or name of the state, province or district.
Postal code.
Country code in ISO 3166-1 alpha-2 format.
Email address.
Phone number.
Address VAT ID.
attachments properties
Unique identifier for the resource.
The attachment type, e.g. einvoice.
The attachment name.
The attachment title.
The attachment file extension.
The date the attachment was created, in the site’s timezone.
The date the attachment was created, as GMT.
The attachment document id.
Relative path to attachment file.
Absolute path to attachment file.
The filename.
Meta data.
meta_data properties
Meta ID.
Meta key.
Meta value.
Example
Create a packing slip by syncing it with an existing shipment.
curl -L 'https://example.com/wp-json/sab/v1/packing_slips/' \ -F 'shipment_id="1631"' \ -F 'sync="true"'
Download PDF
Download the packing slip PDF.
GET: /wp-json/sab/v1/packing_slips/<id>/pdf
Properties
The file data (base64 encoded).
Local path to file in case it exists.
The filename.
Whether it is a preview or the file is persisted.