# get_inventory

> Stock and inbound units for an Amazon account.

## Endpoint

POST https://build-api.sellermate.ai/v1/tools/get_inventory — Stock and inbound units for an Amazon account. (writes: no; platforms: Amazon)

The call shape is illustrative until the contract is final.

## When to use it

Use it to work out days of stock, alert before a stock-out, or decide when to pause ads on a SKU.

## Request fields

| Name | Type | Required | Description |
|---|---|---|---|
| `account` | string | yes | The account to read. A key only reaches the accounts you chose when you created it. |

## Response fields

Every answer says how fresh it is with `data_as_of`.

_To write: the response fields of an inventory row (SKU, ASIN, fulfillable, inbound and any others)_

## Examples

**curl**

```bash
curl -X POST https://build-api.sellermate.ai/v1/tools/get_inventory \
  -H "X-API-Key: $BUILD_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"account":"acct_123"}'
```

**Node**

```js
const res = await fetch("https://build-api.sellermate.ai/v1/tools/get_inventory", {
  method: "POST",
  headers: { "X-API-Key": process.env.BUILD_API_KEY, "Content-Type": "application/json" },
  body: JSON.stringify({ account: "acct_123" }),
});
console.log(await res.json());
```

**Python**

```python
import os, requests

res = requests.post(
    "https://build-api.sellermate.ai/v1/tools/get_inventory",
    headers={"X-API-Key": os.environ["BUILD_API_KEY"]},
    json={"account": "acct_123"},
)
print(res.json())
```

_To write: a real response with two or three rows_

## Errors

### 429 Too many requests

You went over the plan's requests per minute. The body says when to retry.

```json
{ "error": "rate_limited", "retry": 12, "upgrade": "https://build.sellermate.ai/pricing" }
```

_To write: the other errors this tool can return, with the real status and body: a missing or wrong key, an account the key cannot reach, bad dates_

## Platforms

- Amazon: Reads: yes · Writes: yes

## Open in your AI

Paste this into Claude Code, Cursor, Lovable, n8n or Zapier. It points your AI at the docs and at your key.

Prompt:

```
Read https://build.sellermate.ai/SKILL.md. My key is in BUILD_API_KEY. Use get_inventory to list every SKU with fewer than 14 days of stock.
```
