Skip to content

Marketplace

Aknorw edited this page May 2, 2018 · 1 revision

Listings

See on Discogs API documentation

Get listing

client.getListing(listingId, currency)
param required type -
listingId true int
currency false string Must be a supported currency

Edit listing

const data =  {
  releaseId,
  condition: {
    release,
    sleeve,
  },
  price,
  comments,
  allowOffers,
  status,
  externalId,
  location,
  weight,
  formatQty,
}

client.editListing(listingId, data, currency)
param required type -
listingId true int
data true object See below
currency false string Must be a supported currency
key required type default -
releaseId  true int -
condition.release true string - Must be a release condition
condition.sleeve false string - Must be a sleeve condition
price true float -
comments false string -
allowOffers false boolean false -
status true string For Sale Must be For Sale or Draft
externalId false string -
location false string -
weight false float auto
formatQty false float auto

Remove listing

client.removeListing(listingId)
param required type -
listingId true int

Create listing

const data = {
  releaseId,
  condition: {
    release,
    sleeve,
  },
  price,
  comments,
  allowOffers,
  status,
  externalId,
  location,
  weight,
  formatQty,
}

client.createListing(data)
param required type -
data true object See below
key required type default -
releaseId  true int -
condition.release true string - Must be a release condition
condition.sleeve false string - Must be a sleeve condition
price true float -
comments false string -
allowOffers false boolean false -
status true string For Sale Must be For Sale or Draft
externalId false string -
location false string -
weight false float auto
formatQty false float auto

Orders

See on Discogs API documentation

List orders

const options = {
  status,
  pagination,
  sort,
}

client.listOrders(options)
param required type -
options false object See below
key required type default -
status false string All Must be an order status
pagination false object - See paginate
sort false object - See sort - by id (default), buyer, created, status or last_activity

Get order

client.getOrder(orderId)
param required type -
orderId true int

Edit order

const data = {
  status,
  shipping,
}

client.editOrder(orderId, data)
param required type -
orderId true int
data false object See below
key required type default -
status false string - Must be an order status
shipping false number -

List order messages

client.listMessagesForOrder(orderId)
param required type -
orderId true int

Send order message

const options = {
  message,
  status,
}

client.sendMessageForOrder(orderId, options)
param required type -
orderId true int
options false object See below
key required type default -
message false string -
status false string - Must be an order status

Fees

client.getFee(price, currency)
param required type -
price true float
currency false string Must be a supported currency

See on Discogs API documentation

Price suggestions

client.getPriceSuggestions(releaseId)
param required type -
releaseId true int

See on Discogs API documentation