# Incidecoder — Wrapped API

> **You are on:** `https://api.paywithlocus.com/api` | [llms.txt](https://paywithlocus.com/llms.txt) | [docs](https://docs.paywithlocus.com)
>
> Locus runs on multiple environments -- make sure every URL you call matches your expected environment.
> | Environment | Landing | API | Docs |
> |---|---|---|---|
> | Production | paywithlocus.com | api.paywithlocus.com | docs.paywithlocus.com |
> | Beta | beta.paywithlocus.com | api.beta.paywithlocus.com | docs.paywithlocus.com |
> | Stage | stage.paywithlocus.com | api.stage.paywithlocus.com | docs.paywithlocus.com |
>
> If the API URL above doesn't match your expected environment, re-fetch this file from the correct domain.

> Search cosmetic products and ingredients, get detailed analysis of their safety and composition, and decode ingredient lists to understand what's in your beauty products. Find similar products and explore comprehensive ingredient databases to make informed decisions about the cosmetics you use.

**Category:** Healthcare | **Website:** [incidecoder.com/](https://incidecoder.com/) | **Docs:** [parse.bot/marketplace/fdb8c3ef-f03f-4e96-9da4-9a559bb1005d/incidecoder-com-api](https://parse.bot/marketplace/fdb8c3ef-f03f-4e96-9da4-9a559bb1005d/incidecoder-com-api)

Pay-per-use API proxy for Locus Pro. Each call burns credits from your workspace balance.

## Access

**Base URL:** `https://api.paywithlocus.com/api/wrapped/credits/incidecoder/`
**Auth:** `Authorization: Bearer <LOCUS_CREDITS_SECRET_KEY>` (an `lcr_` secret key or a scoped `lcac_` agent credential)
**Required header:** `Idempotency-Key: <fresh UUID per call>`. A retry with the same key replays the stored result without a new charge.
**Response:** the provider response after any endpoint-specific normalization. `X-Locus-Credits-Charged` carries the charge and `X-Locus-Credits-Balance` the remaining balance. Insufficient credits return `402` before the provider is called.
**Pricing:** estimated costs below are USD. Locus debits the credit equivalent at your workspace rate.

Full call contract: https://docs.paywithlocus.com/api-reference/introduction

> Using a Pay With Locus wallet key (`claw_` prefix)? Wallet routes are documented separately: https://docs.paywithlocus.com/wrapped-apis/for-agents

## Endpoints

### Decode inci

Submit a raw INCI ingredient list (comma-separated text) and get back a decoded analysis including ingredient table with irritancy/comedogenicity data, highlights, and key ingredient categories. Useful for analyzing custom product formulations.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `texts` | string | Yes | Comma-separated INCI ingredient list (e.g. 'Aqua, Glycerin, Niacinamide'). |

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/credits/incidecoder/decode-inci \
  -H "Authorization: Bearer $LOCUS_CREDITS_SECRET_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{"texts":"<string>"}'
```

### Get ingredient

Get full details for a specific ingredient by its slug, including INCIDecoder rating, facts (what-it-does, also-called), description text, CosIng URL, and a list of products containing it with concentration percentages when available.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `slug` | string | Yes | Ingredient slug (e.g. 'niacinamide', 'retinol'). |

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/credits/incidecoder/get-ingredient \
  -H "Authorization: Bearer $LOCUS_CREDITS_SECRET_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{"slug":"<string>"}'
```

### Get product

Get full details for a product by its slug, including ingredient analysis with irritancy/comedogenicity scores, highlights (hashtag-style labels like #alcohol-free), and key ingredient categories. Returns stale_input with kind input_not_found if the product slug does not exist.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `slug` | string | Yes | Product slug from URL path (e.g. 'cerave-moisturizing-cream'). |

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/credits/incidecoder/get-product \
  -H "Authorization: Bearer $LOCUS_CREDITS_SECRET_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{"slug":"<string>"}'
```

### Get similar products

Get recommended products related to a specific product. Results are title-match based, sharing product name keywords. Returns stale_input with kind input_not_found if the product slug does not exist.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `slug` | string | Yes | Product slug (e.g. 'cerave-moisturizing-cream'). |

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/credits/incidecoder/get-similar-products \
  -H "Authorization: Bearer $LOCUS_CREDITS_SECRET_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{"slug":"<string>"}'
```

### List ingredients

Browse featured ingredients paginated. Returns a list of ingredient summaries with name and slug. Each page contains up to 28 ingredients.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `ppage` | integer | No | Page number for pagination. |

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/credits/incidecoder/list-ingredients \
  -H "Authorization: Bearer $LOCUS_CREDITS_SECRET_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{"ppage":"<integer>"}'
```

### List products

Browse featured products paginated. Returns a list of product summaries with title, brand, and slug. Each page contains up to 28 products.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `ppage` | integer | No | Page number for pagination. |

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/credits/incidecoder/list-products \
  -H "Authorization: Bearer $LOCUS_CREDITS_SECRET_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{"ppage":"<integer>"}'
```

### Search

Search for products and/or ingredients by query string. Returns paginated results with title, brand, slug, URL, and type for each match. Supports filtering by included/excluded ingredient slugs. The activetab param switches between product and ingredient results.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `activetab` | string | No | Tab to search in. Accepted values: 'products', 'ingredients'. |
| `exclude` | string | No | Comma-separated ingredient slugs that must not be present in results. |
| `include` | string | No | Comma-separated ingredient slugs that must be present in results. |
| `ppage` | integer | No | Page number for pagination. |
| `query` | string | Yes | Search keyword. |

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/credits/incidecoder/search \
  -H "Authorization: Bearer $LOCUS_CREDITS_SECRET_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{"activetab":"<string>","exclude":"<string>","include":"<string>","ppage":"<integer>","query":"<string>"}'
```

## Next steps

- [All wrapped API providers](https://paywithlocus.com/wapi/index.md): pick another provider.
- [Find and call tools](https://paywithlocus.com/agent/tools.md): price ceilings, async results, and errors.
- [Credits and billing](https://paywithlocus.com/agent/billing.md): what a call costs and how to add credits.
- [Agent docs index](https://paywithlocus.com/agent/index.md): every Locus agent page.