API

Creating a vendor return by API

Allow your vendors to self-service the creation of returns using the Jetti API

Last updated July 9th, 2020

Alongide generating returns in the vendor poral, vendors will also be able to trigger returns using the Jetti API.

Step 1

Lookup the dropship purchase

If you don't already have the id of the purchase object, you'll need to look that up in the API. A common scenario is to lookup by reference or the ID of the object from the dropship provider's external system (vendorReceivedId or vendorReceivedReference). The example here is querying for the purchase object by the reference.

Step 2

Cancel the dropship purchase

Next, the dropship purchase will need to be cancelled. You can optionally pass in an array of purchase item IDs (note: note sale item IDs) if you only want to partially cancel the sale. From this endpoint, a new sale return object is created, which will contain a purchaseId foreign key to the dropship purchase object.

Once the dropship purchase has been cancelled, a notification email is then triggered automatically to the retailer notifying them of the cancellation.

Step 3

Updating the status of the sale return

If needed, you can update the status of the sale return object after it has been raised through a PUT request. For example, you might want to update the status of the return to signify it has been received from the customer.

Back to API