Your first sale
This guide will walk you through selling your first item using the Depop Selling API.
Prerequisites
Before you start, make sure you have:
- A Testing API key. Our API is currently private and is not available to the general public. If you are interested in integrating with Depop, please contact us at [email protected], and we'll get back to you with the next steps.
- Postman installed with an account. You can use any client but this guide will use Postman as an example.
- An existing listing. If you haven't created a listing yet, please follow the Your first listing guide first.
- Postman configured for this API. If you haven't done this yet, please follow the Your first listing guide first.
Step 1: Make sure your listing is on sale
To sell an item at depop, it must be on sale.
Let's confirm that the listing you have is in this state and has enough stock:
- In Postman, select the
Get product by SKUrequest from theapi/v1>products>{sku}collection. - Make sure the path variable
skumatches your listing. If you followed our previous guide, it will beABC-12345-S-BL. - Click on the Send button.
You'll see a response similar to this:
Notice how the status is STATUS_ONSALE and the quantity is 1. This means that the listing is on sale and has enough stock to sell.
If this isn't the case, you can update the listing first by following the Your first listing guide again.
Step 2: Simulate a purchase
Now that we have confirmed that the listing is on sale, we can simulate a purchase.
Since you can't access our testing environment through the app or website, we have a developer endpoint that simulates a purchase from a test buyer account.
Let's try it out:
- In Postman, expand
api/v1>products>{sku}and select theTrigger a purchase of a product (for testing)request. - Make sure the path variable
skumatches your listing. If you followed our previous guide, it will beABC-12345-S-BL. - Click on the Send button. Please practice patience as this request takes a bit longer than others to complete. This is because we are orchestrating several calls internally to make this happen.
Once it finishes you'll get back a 200 OK response. Congratulations on your first test sale! 🎉
Verify the product has changed state by doing another Get product by SKU request. You should get an updated status and quantity as such:
{
"sku": "ABC-12345-S-BL",
"product_id": 7238212,
"status": "STATUS_PURCHASED",
"quantity": 0,
(...)
}
Step 3: Get your order
Now that you have made a sale, let's find the order that was created for this sale.
- In Postman, expand
api/v1>ordersand select theGet all ordersrequest. - Make sure to uncheck the
limit,after,fromandtoquery parameters. These are optional, we don't need them for now to make sure we get all the recent orders. - Click on the Send button.
If it works, you should see a response with the order that was created for your sale. It should look something like this:
{
"meta": {
"has_more": false
},
"data": [
{
"purchase_id": "435017619960",
"status": "SHIPPING_PENDING",
"currency": "GBP",
"buyer_pays_amount": "31.49",
"seller_receives_amount": "25.38",
"buyer_shipping_price": "3.50",
"buyer_address": {
"name": "Partner Buyer",
"address": "20 Farringdon Road",
"address2": "",
"city": "London",
"postal_code": "EC1M 3HE",
"state": "Islington",
"country_code": "GB"
},
"line_items": [
{
"purchase_item_id": 2490660,
"sku": "ABC-12345-S-BL",
"product_id": 7238212,
"parcel_id": "13a5bef4-703b-32a9-8c89-11cd7a914a14",
"description": "Vintage Nike T-Shirt in excellent condition.\nBlack with white swoosh logo on the front.\nSize medium, fits true to size.\nSmall mark on the left sleeve (see last image).\n\n#vintage #nike #streetwear #90s",
"original_price": "25.99",
"sold_price": "25.99",
"sold_via_offers": false,
"image_url": "https://media-photos-staging.depop.com/b1/97082934/2148295253_8d4b937afa404f48b38cf13846b839da/P0.jpg"
}
],
"seller_fee_breakdown": [
{
"fee_type": "PAYMENT_FEE",
"amount": "1.16",
"currency": "GBP"
},
{
"fee_type": "DEPOP_FEE",
"amount": "2.95",
"currency": "GBP"
}
]
}
]
}
Now that you have your order, the next step is to ship it.
Note
We can send webhooks to notify you when an order is placed for real-time updates. This means you can start processing the order immediately without having to poll the API as often. It also reduces the risk of overselling if you're listing the same product in other platforms. If you are interested in this, please reach out to us with the URL you want us to configure.
Step 4: Ship your order
Notice how we got a purchase_id in the order response and a parcel_id in the line items.
We need this to mark the order as shipped and share the tracking information.
- In Postman, expand
api/v1>ordersand select theMark an order as shipped, providing tracking informationrequest. - Copy over the
purchase_idandparcel_idfrom the get orders response as path variables. - Go to the Body tab and fill in the tracking information. Update the following example with your own tracking number::
- Click on the Send button.
You should get back a 200 OK response.
To confirm it has worked, you can do another Get all orders request and check the status of the order. It should now be SHIPPED.
Great work! You have successfully sold your first item using the Depop Selling API. 🎉
Next steps
Now that you have sold your first item, you can keep exploring the API and learn more about the API fields and options. The API Reference documentation provides detailed information about each field and its purpose.
To keep going, you can read our How to restock next to bring your inventory back to life after a sale.
If you run into any issues or have questions, please reach out to us.