# OpenSea Ids API Documentation

<p><strong>OpenSea Ids API Documentation</strong> Get public collection slugs or item identifiers from the site sitemap. Choose type collections or items. Feed each id unchanged into the collection or item route. This route has no page cursor. Every failed request costs no credit. Cost: 1 credit per successful request. Scrappa is an independent service and is not affiliated with or endorsed by OpenSea.</p>

- **Documentation:** [https://scrappa.co/docs/opensea-api/opensea_ids](https://scrappa.co/docs/opensea-api/opensea_ids)
- **API group:** OpenSea API
- **Endpoint:** `GET https://scrappa.co/api/opensea/collections/ids`

## Authentication

Send your Scrappa API key in the `X-API-KEY` request header. Paid endpoints also support accountless x402 payments when called without an API key.

## Parameters

| Parameter | Type | Required | Description |
| --- | --- | --- | --- |
| `type` | string | No | collections (default) or items. |

## Example response

```json
{
    "data": {
        "ids": [
            {
                "slug": "courtyard-nft",
                "type": "collection",
                "chain": null,
                "token_id": null
            }
        ],
        "type": "collections",
        "count": 2
    },
    "meta": {
        "source": "opensea",
        "credits": 1,
        "billable": true,
        "endpoint_family": "discovery_sitemaps"
    },
    "success": true
}
```

## Errors

| Status | Error | Description |
| --- | --- | --- |
| 422 | Validation Error | The type is invalid. This response is not billable. |
| 502 | Bad Gateway | The public id list is temporarily unavailable. This response is not billable. |

## More Scrappa resources

- [API documentation](https://scrappa.co/docs)
- [Full LLM-readable API reference](https://scrappa.co/llms-full.txt)
- [OpenAPI specification](https://scrappa.co/docs/api.json)
- [Pricing](https://scrappa.co/pricing)
