> For the complete documentation index, see [llms.txt](https://docs.ordinalsbot.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.ordinalsbot.com/marketplace/api-docs/data-api.md).

# Data API

Api for getting marketplace data stats

## Get collection activity

> Retrieves trading activity history for a specific collection based on its slug

```json
{"openapi":"3.0.0","info":{"title":"Ordinalsbot Marketplace API","version":"0.0.1"},"servers":[{"url":"https://api.ordinalsbot.com/marketplace","description":"Production server"},{"url":"https://testnet-api.ordinalsbot.com/marketplace","description":"Testnet server"},{"url":"https://signet-api.ordinalsbot.com/marketplace","description":"Signet server"}],"paths":{"/data/collections/activity":{"get":{"summary":"Get collection activity","description":"Retrieves trading activity history for a specific collection based on its slug","parameters":[{"in":"query","name":"slug","required":true,"schema":{"type":"string"},"description":"The slug identifier of the collection"},{"in":"query","name":"startDate","required":false,"schema":{"type":"string","format":"date","nullable":true},"description":"Filter activities from this date (format YYYY-MM-DD). By default, it will filter activities from the last 7 days.\n"},{"in":"query","name":"page","required":false,"schema":{"type":"integer","minimum":0,"default":0},"description":"Page number for pagination"},{"in":"query","name":"limit","required":false,"schema":{"type":"integer","minimum":20,"maximum":100,"default":100},"description":"Number of records to return per page (between 20 and 100)"},{"in":"query","name":"order","required":false,"schema":{"type":"string","enum":["asc","desc"],"default":"desc"},"description":"Sort order for activities (ascending or descending)"}],"responses":{"200":{"description":"Successfully retrieved collection activity","content":{"application/json":{"schema":{"type":"array","items":{"type":"object","properties":{"inscription_id":{"type":"string","description":"ID of the inscription involved in the activity"},"inscription_name":{"type":"string","description":"Name of the inscription"},"maker_address":{"type":"string","description":"Seller/maker address"},"taker_address":{"type":"string","nullable":true,"description":"Buyer/taker address (can be null)"},"collection_slug":{"type":"string","description":"Slug of the collection"},"collection_name":{"type":"string","description":"Name of the collection"},"price":{"type":"number","description":"Price in satoshis"},"trade_timestamp":{"type":"string","format":"date-time","description":"Timestamp when the trade occurred"},"transaction_id":{"type":"string","description":"Bitcoin transaction ID"},"thumbnail_url":{"type":"string","description":"URL to the inscription thumbnail image"}}}}}}},"400":{"description":"Bad request - validation error","content":{"application/json":{"schema":{"type":"object","properties":{"errors":{"type":"array","items":{"type":"object","properties":{"msg":{"type":"string"},"param":{"type":"string"},"location":{"type":"string"}}}}}}}}}}}}}}
```


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.ordinalsbot.com/marketplace/api-docs/data-api.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
