# Cookpad Indonesia API

> Returns Indonesian recipes from Cookpad by search, with ingredients, steps and author for each recipe.

Category: Entertainment & Books. Region: ID. 4 endpoints at `https://api.hoshime.com/v1/cookpad/<endpoint>`, `GET` with query parameters, answering `{data, meta}` (see https://hoshime.com/docs/responses.md). Reference: https://hoshime.com/docs/platforms/cookpad
## GET /v1/cookpad/search

Indonesian recipes on Cookpad that match a query, one page of results at a time.

Scope: `social:read` · Units: 1 · Cached: 30 min · Paginated: cursor

| Parameter | Type | Required | Description |
|---|---|---|---|
| `query` | string | yes | Words to search the recipes for, such as nasi goreng. (e.g. nasi goreng) |
| `cursor` | string | no | meta.pagination.nextCursor of the previous page. Omit it for the first page. |
| `tunnel` | string | no | Id or name of one of your tunnels: the call reads the source from the machine that runs `hoshime tunnel`, through its own connection. Fails with 409 tunnel_unavailable when no machine is connected. Cannot be combined with proxy. |
| `proxy` | string | no | Your own http:// or https:// proxy, such as http://user:pass@proxy.example.com:8080, on a public address. The call reads the source only through it. |
| `profileId` | string | no | Browser profile whose login the call sends (its cookies), so the source answers as that account. Without tunnel or proxy it leaves through the profile's own residential IP. Needs the browser:read scope. Data read logged in is for your account only. |

Response data fields: `id` (string), `title` (string), `url` (string)

```bash
curl "https://api.hoshime.com/v1/cookpad/search?query=nasi+goreng" -H "Authorization: Bearer $HOSHIME_TOKEN"
```

## GET /v1/cookpad/recipe

One Indonesian recipe on Cookpad by its id: ingredients, steps and the author.

Scope: `social:read` · Units: 1 · Cached: 60 min

| Parameter | Type | Required | Description |
|---|---|---|---|
| `id` | string | yes | Recipe number, the digits in its page URL such as cookpad.com/id/resep/26822182. (e.g. 26822182) |
| `tunnel` | string | no | Id or name of one of your tunnels: the call reads the source from the machine that runs `hoshime tunnel`, through its own connection. Fails with 409 tunnel_unavailable when no machine is connected. Cannot be combined with proxy. |
| `proxy` | string | no | Your own http:// or https:// proxy, such as http://user:pass@proxy.example.com:8080, on a public address. The call reads the source only through it. |
| `profileId` | string | no | Browser profile whose login the call sends (its cookies), so the source answers as that account. Without tunnel or proxy it leaves through the profile's own residential IP. Needs the browser:read scope. Data read logged in is for your account only. |

Response data fields: `author` (string), `authorUrl` (string), `bookmarks` (integer (int64)), `cuisine` (string), `description` (string), `id` (string), `image` (string), `ingredients` (Ingredient[]), `ingredients[].name` (string), `keywords` (Keyword[]), `keywords[].name` (string), `likes` (integer (int64)), `name` (string), `publishedDate` (string), `steps` (Step[]), `steps[].text` (string), `url` (string), `yield` (string)

```bash
curl "https://api.hoshime.com/v1/cookpad/recipe?id=26822182" -H "Authorization: Bearer $HOSHIME_TOKEN"
```

## GET /v1/cookpad/user

Profile of one Cookpad cook by the number in the profile URL: name, bio, recipes published, followers and following.

Scope: `social:read` · Units: 1 · Cached: 60 min

| Parameter | Type | Required | Description |
|---|---|---|---|
| `id` | string | yes | Cook number, the digits in the profile URL such as cookpad.com/id/pengguna/14534852. The author link of a recipe carries it. (e.g. 14534852) |
| `tunnel` | string | no | Id or name of one of your tunnels: the call reads the source from the machine that runs `hoshime tunnel`, through its own connection. Fails with 409 tunnel_unavailable when no machine is connected. Cannot be combined with proxy. |
| `proxy` | string | no | Your own http:// or https:// proxy, such as http://user:pass@proxy.example.com:8080, on a public address. The call reads the source only through it. |
| `profileId` | string | no | Browser profile whose login the call sends (its cookies), so the source answers as that account. Without tunnel or proxy it leaves through the profile's own residential IP. Needs the browser:read scope. Data read logged in is for your account only. |

Response data fields: `avatarUrl` (string), `bio` (string), `createdAt` (string), `followerCount` (integer (int64)), `followingCount` (integer (int64)), `id` (string), `name` (string), `postCount` (integer (int64)), `url` (string), `username` (string), `verified` (boolean)

```bash
curl "https://api.hoshime.com/v1/cookpad/user?id=14534852" -H "Authorization: Bearer $HOSHIME_TOKEN"
```

## GET /v1/cookpad/userRecipes

Recipes one Cookpad cook has published, newest first, 20 per page. Page with cursor.

Scope: `social:read` · Units: 1 · Cached: 30 min · Paginated: cursor

| Parameter | Type | Required | Description |
|---|---|---|---|
| `id` | string | yes | Cook number, the digits in the profile URL such as cookpad.com/id/pengguna/14534852. (e.g. 14534852) |
| `cursor` | string | no | meta.pagination.nextCursor of the previous page. Omit it for the first page. |
| `tunnel` | string | no | Id or name of one of your tunnels: the call reads the source from the machine that runs `hoshime tunnel`, through its own connection. Fails with 409 tunnel_unavailable when no machine is connected. Cannot be combined with proxy. |
| `proxy` | string | no | Your own http:// or https:// proxy, such as http://user:pass@proxy.example.com:8080, on a public address. The call reads the source only through it. |
| `profileId` | string | no | Browser profile whose login the call sends (its cookies), so the source answers as that account. Without tunnel or proxy it leaves through the profile's own residential IP. Needs the browser:read scope. Data read logged in is for your account only. |

Response data fields: `id` (string), `title` (string), `url` (string)

```bash
curl "https://api.hoshime.com/v1/cookpad/userRecipes?id=14534852" -H "Authorization: Bearer $HOSHIME_TOKEN"
```
