# Pinterest Search API

> Search Pinterest pins by keyword and get pin IDs, URLs, titles, descriptions and images, with cursor pagination.

Source: https://www.sandbase.ai/apis/pinterest/search
API reference: https://www.sandbase.ai/apis/pinterest/search/docs

## Facts

- Provider: Pinterest
- Type: Data API
- Endpoint: `POST https://api.sandbase.ai/v1/api/pinterest/search`
- Price: $0.02 per call
- Capabilities: social media, image search
- Billing: pay per use from one SandBase balance; no provider account or subscription needed

## Call it

`POST https://api.sandbase.ai/v1/api/pinterest/search` with `Authorization: Bearer $SANDBASE_API_KEY` and the parameters as a JSON body.

| Parameter | Type | Required | Allowed values |
| --- | --- | --- | --- |
| `query` | string | yes |  |
| `cursor` | string | no |  |
| `trim` | boolean | no |  |

## FAQ

### How do I use the Pinterest Search API?

Send a POST request to https://api.sandbase.ai/v1/api/pinterest/search with your SandBase API key in the Authorization header (Bearer) and the parameters as a JSON body. You can also try it in the Playground on this page without writing code.

### How much does the Pinterest Search API cost?

$0.02 per call, billed from your SandBase balance. You are only charged for calls you make; there is no subscription.

### What parameters does the Pinterest Search API accept?

Required: query (string). Optional: cursor (string) and trim (boolean). The Parameters table and the Playground on this page list every field.

### What does the Pinterest Search API return?

A JSON response returned in the same HTTP request (synchronous). The README on this page includes a sample response.

### Do I need a Pinterest developer account or API key?

No. Pinterest Search runs through SandBase, so one SandBase API key covers this endpoint and every other API and model in the catalog. You do not need to apply for Pinterest API access separately.

## README

### Pinterest Search API

Search Pinterest for a query and get matching pins. Set `trim` for a compact response.

#### Use cases

- Research visual trends for a product category.
- Find inspiration and competitor creatives.
- Collect pins for mood boards.

#### Request

```bash
curl -X POST "https://api.sandbase.ai/v1/api/pinterest/search" \
  -H "Authorization: Bearer $SANDBASE_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"query": "home office ideas", "trim": true}'
```

#### Parameters

| Name | Type | Required | Description |
|---|---|---|---|
| `query` | string | Yes | Search query for Pinterest pins. |
| `trim` | boolean | No | Set to true for a trimmed down version of the response. |
| `cursor` | string | No | Pagination cursor from a previous response to fetch the next page. |

#### Example response

Real response for the request above, trimmed to the main fields. User names and long IDs are masked.

```json
{
  "cursor": "<next cursor>",
  "pins": [
    {
      "id": "4887421732865150",
      "url": "https://www.pinterest.com/pin/4887421732865150",
      "images": {
        "url": "https://i.pinimg.com/…"
      }
    }
  ]
}
```

#### Notes

- Paginate with the `cursor` from the previous response.
