Listing Endpoints

Sweep buy items from a collection

Changed on

Buy up to N items from a collection using any payment token, including cross-chain. If a requested item becomes unavailable, the system can automatically substitute it with the next cheapest listing from the same collection (enabled by default). Returns an ordered list of transactions to execute. Collections on EVM chains only; a collection on any other chain is rejected.

post/api/v2/listings/sweep

Request

Request body

buyerstring required

Address of the buyer

collection_slugstring required

The slug of the collection to sweep

max_itemsinteger required

Maximum number of items to buy (1-50)

max_price_per_itemstring required

Maximum price per item in the payment token's units

recipientstring nullable

Optional recipient address for the purchased items

Example request

{
  "buyer": "0x...",
  "collection_slug": "pudgypenguins",
  "max_items": 5,
  "max_price_per_item": "10.0",
  "payment": {
    "chain": "base",
    "token_address": "0x0000000000000000000000000000000000000000"
  }
}

Response

Sweep fulfillment data retrieved successfully

Changes

    • breaking

      the response property became nullable for the status

    • info

      the request property became nullable

    • info

      added the optional property to the response with the status

    • info

      added the optional property to the response with the status

    • info

      added the optional property to the response with the status

    • info

      added the optional property to the response with the status