API reference
Photos
Upload, reorder and remove a listing's pictures.
Add photos
POST
/v1/listings/:id/photosNeeds a key with listingsTakes uploads
Upload pictures as multipart form data (one or more file parts, up to 10 MB each, plus one video up to 40 MB), or send urls and we'll download them. New photos go at the end; your first own photo is always the cover.
Path
idstringrequired- The id.
Body
urlsstring[]- Public picture URLs to download, instead of uploading.
altstring- A short description for screen readers.
curl https://api.resell.store/v1/listings/8d1e6c2a-…/photos \
-H "Authorization: Bearer $RESELL_KEY" \
-H "Content-Type: application/json" \
-d '{
"urls": [
"https://example.com/dutch-oven.jpg"
]
}'Response
{
"object": "list",
"data": [
{
"id": "3f…",
"url": "https://files.resell.store/…",
"alt": null,
"source": null,
"is_video": false
}
],
"total": 1,
"has_more": false
}Reorder photos
PUT
/v1/listings/:id/photos/orderNeeds a key with listings
Send every photo id in the order you want. The first must be one of your own photos (not a web picture or the video).
Path
idstringrequired- The id.
Body
photo_idsstring[]required- Every photo id on the listing, in order.
curl -X PUT https://api.resell.store/v1/listings/8d1e6c2a-…/photos/order \
-H "Authorization: Bearer $RESELL_KEY" \
-H "Content-Type: application/json" \
-d '{
"photo_ids": [
"3f…",
"9a…"
]
}'Response
{
"object": "list",
"data": [
{
"id": "3f…",
"url": "https://files.resell.store/…",
"alt": null,
"source": null,
"is_video": false
}
],
"total": 1,
"has_more": false
}Remove a photo
DELETE
/v1/listings/:id/photos/:photoIdNeeds a key with listings
Path
idstringrequired- The id.
photoIdstringrequired- The photo's id.
curl -X DELETE https://api.resell.store/v1/listings/8d1e6c2a-…/photos/3f… \
-H "Authorization: Bearer $RESELL_KEY"Response
{
"object": "list",
"data": [],
"total": 0,
"has_more": false
}