canonical: https://jentic.com/apis/tokopedia.com/tokopedia

# Tokopedia API

Tokopedia's Official API for integration of various services from Tokopedia, Indonesia's largest e-commerce platform. The API exposes 9 endpoints secured with oauth2 authentication.

## For AI agents

Programmatically list orders, get single order. Covers 9 operations with oauth2 authentication.

## Scope

Does not handle payments, communications, or crm - use for developer tools only.

## Capabilities

- List orders
- Get single order
- Accept order
- Reject order
- Edit product
- Update stock

## Use cases

### Developer Tools Operations

Use the Tokopedia API to perform developer tools operations programmatically. The API provides 9 endpoints covering core functionality including list orders, get single order, accept order.

Example prompt: Call GET `/v1/order/list` to list orders

### Automated Orders Management

Automate orders operations by combining multiple Tokopedia API endpoints. Agents can get single order and then accept order in a single workflow.

Example prompt: Call GET `/v2/order` to get single order, then verify the result

### AI Agent Integration via Jentic

AI agents discover and call Tokopedia API endpoints through Jentic without managing credentials directly. An agent searches for the required operation by intent, receives the matching endpoint schema, and executes the call with Jentic-managed authentication. This eliminates the need to read API documentation or handle oauth2 tokens manually.

Example prompt: Search Jentic for 'list orders', load the operation schema, and execute with Jentic-managed credentials

## Key endpoints

| Method | Path | Description |
| --- | --- | --- |
| GET | `/v1/order/list` | List orders |
| GET | `/v2/order` | Get single order |
| POST | `/v1/order/{orderId}/fs/{fsId}/ack` | Accept order |
| POST | `/v1/order/{orderId}/fs/{fsId}/reject` | Reject order |
| GET | `/inventory/v1/fs/{fsId}/product/info` | Get product info |
| POST | `/v2/products/fs/{fsId}/edit` | Edit product |
| POST | `/inventory/v1/fs/{fsId}/stock/update` | Update stock |
| GET | `/v1/shop/fs/{fsId}/shop-info` | Get shop info |

## Key resources

- **Orders** — Order management
- **Products** — Product and inventory management
- **Shop** — Shop information
- **Logistics** — Shipping and logistics

## Why Jentic

- **Setup:** Wiring the Tokopedia API by hand means running its OAuth2 client-credentials flow, threading the fs id through every path, and handling retries yourself. Through Jentic you install once, import Tokopedia from the API Directory, store the credentials once, and your agent calls it.
- **Permission scoping:** Tokopedia puts the fulfilment-service id in the URL path (`/fs/{fsId}/...`), so a rule can pin your agent to one fs: it works within that shop's orders and inventory and nothing else. You choose the operations it may call, so writes like rejecting an order or updating stock are not included unless you add them.
- **Credential handling:** Your Tokopedia client credentials are stored once, encrypted, by your own Jentic One instance and injected at execution time. They never enter the agent's prompt, logs, or context.
- **Discovery method:** Agents search Jentic by intent such as 'list orders for a shop' or 'update product stock', and Jentic returns the matching Tokopedia operation with its input schema so the agent calls the right endpoint without browsing the reference docs.

## Related APIs

- **Github** — Alternative developer tools API
- **Gitlab** — Alternative developer tools API

## FAQ

### What authentication does the Tokopedia API use?

The Tokopedia API uses OAuth 2.0 for authorization. Through Jentic, these credentials are stored encrypted in your Jentic One instance and injected at execution time, so raw secrets never enter the agent context.

### Can I list orders with the Tokopedia API?

Yes. Use the GET `/v1/order/list` endpoint. The API returns structured JSON responses that agents can parse and act on directly.

### What are the rate limits for the Tokopedia API?

Rate limits are not specified in the OpenAPI spec. Check the vendor documentation for current limits. Through Jentic, rate limiting is handled automatically with retry logic built into the execution layer.

### How do I list orders through Jentic?

Install the Jentic SDK with pip install jentic, authenticate through Jentic One, the self-hosted execution layer, then search for 'list orders'. Jentic returns the matching Tokopedia API operation with its input schema. Load the schema and execute the call - credentials are injected automatically.

### How many endpoints does the Tokopedia API have?

The Tokopedia API exposes 9 endpoints covering orders, products, shop operations.

### Can I limit what my agent is allowed to do with the Tokopedia API?

Yes. Because you run Jentic One yourself, your own rules decide which Tokopedia operations and credentials the agent may use. Since Tokopedia puts the fulfilment-service id in the URL path (`/fs/{fsId}/...`), you can pin the agent to a single shop so it only touches that shop's orders and inventory. You also choose the operations it may call, so read calls like GET `/v1/order/list` and GET `/v2/order` can be allowed while writes such as rejecting an order or updating stock stay excluded unless you add them.
