Get listings
To get all listings, issue a GET
request to the listings
endpoint.
GET https://admin-api.phosphor.xyz/v1/listings
This is a paginated endpoint that returns results up to a certain limit
.
- Specify the
cursor
from the previous response to return the next batch of results from the offset. - Specify an
order_direction
ofASC
orDESC
to sort results in an ascending or descending order.
GET https://admin-api.phosphor.xyz/v1/listings?limit=1
Example response
{
"cursor": "ZHRfMTY1NTk0NzczOC41NzEwODE.",
"has_more": true,
"results": [
{
"id": "4e339560-5c6c-495a-bfe3-0a30e3519983",
"status": "ACTIVE",
"quantity_listed": 1,
"quantity_remaining": 9998,
"sale_type": "DEFAULT",
"policy": {
"type": "FCFS",
"max_per_user": 1,
"payment_session_duration": {
"timeout_seconds": 300,
},
"email_claim_duration": 3600,
"item_assignment_strategy": "AUTOMATIC",
"tx_payer": "SELLER"
},
"start_time": "2022-11-08T09:00:00+00:00",
"end_time": "2022-12-08T09:00:00+00:00",
"collection_id": null,
"item_id": "12b4659a-0796-4021-b21e-a376494b674c",
"price": "25000",
"currency": "USD",
"settlement_currency": null,
"max_quantity_per_tx": 1,
"payment_providers": ["STRIPE"]
}
],
"total_results": 25
}
cursor
indicates an offset from which the next batch of results begin.has_more
returnstrue
if there are more results than already displayed.results
returns an array of listings from the search.total_results
returns the total number of results from the response.
Issue a GET
request to the listings
endpoint using the ID of the listing.
GET https://admin-api.phosphor.xyz/v1/listings/{listing_id}
Example response
{
"id": "4e339560-5c6c-495a-bfe3-0a30e3519983",
"status": "ACTIVE",
"quantity_listed": 1,
"quantity_remaining": 1,
"sale_type": "DEFAULT",
"policy": {
"type": "FCFS",
"max_per_user": 1,
"payment_session_duration": {
"timeout_seconds": 600,
},
"email_claim_duration": 3600,
"item_assignment_strategy": "AUTOMATIC",
"tx_payer": "SELLER"
},
"start_time": "2022-11-08T09:00:00+00:00",
"end_time": "2022-12-08T09:00:00+00:00",
"collection_id": null,
"item_id": "12b4659a-0796-4021-b21e-a376494b674c",
"price": "25000",
"currency": "USD",
"settlement_currency": null,
"max_quantity_per_tx": 1,
"payment_providers": ["STRIPE"]
}