# Jdih Kemenkeu — 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 and retrieve Indonesian Ministry of Finance legal documents with detailed information including document types, metadata, and downloadable files. Browse legal products by category and access comprehensive details about regulations, policies, and official legal materials from Indonesia's financial authority.

**Category:** Government & Public Data | **Website:** [jdih.kemenkeu.go.id/](https://jdih.kemenkeu.go.id/) | **Docs:** [parse.bot/marketplace/f8e40d83-7dbf-4473-acab-525c0445ba6b/jdih-kemenkeu-go-id-api](https://parse.bot/marketplace/f8e40d83-7dbf-4473-acab-525c0445ba6b/jdih-kemenkeu-go-id-api)

Pay-per-use API proxy. Each call is automatically billed to your wallet in USDC.

## Access

**Base URL:** `https://api.paywithlocus.com/api/wrapped/parse-jdih-kemenkeu-go-id-api-f8e40d83/`
**Auth:** `Authorization: Bearer <LOCUS_API_KEY>`

## Endpoints

### get_document_detail

Retrieve full metadata for a single legal document by its slug. Returns the complete record including issuing body, organizational unit, enactment date, associated files, and linked documents. The slug is obtained from search_documents results.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `slug` | string | Yes | Document slug identifier from search_documents results (e.g. 'pmk-39-tahun-2026'). |

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-jdih-kemenkeu-go-id-api-f8e40d83/get_document_detail \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"slug":"<string>"}'
```

### get_document_files

List the downloadable files associated with a legal document. Returns file metadata including type codes, descriptions, filenames, sizes, and download URLs. The slug is obtained from search_documents results.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `slug` | string | Yes | Document slug identifier (e.g. 'pmk-39-tahun-2026'). Available in search_documents results as items[*].slug. |

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-jdih-kemenkeu-go-id-api-f8e40d83/get_document_files \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"slug":"<string>"}'
```

### get_jenis_dokumen_options

List all document type categories available in the database with their document counts. Returns the full vocabulary of document types accepted by the bentuk filter in search_documents. Useful for populating filter controls or discovering the database structure.

**Estimated cost:** Metered

_No parameters required._

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-jdih-kemenkeu-go-id-api-f8e40d83/get_jenis_dokumen_options \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{}'
```

### search_documents

Full-text search over the Indonesian Ministry of Finance legal document database. Supports filtering by document type, year, status, issuing body, topic, and label. Results are paginated and sortable by date or relevance. Each result includes document metadata (title, number, year, status, slug) suitable for drilling into detail or files.

**Estimated cost:** Metered

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `bentuk` | string | No | Document type filter. Use get_jenis_dokumen_options to discover valid values. |
| `keyword` | string | No | Search keyword to find in document titles and content. |
| `label` | string | No | Document label filter. |
| `nomor` | string | No | Document number filter. |
| `order` | string | No | Sort order. |
| `page` | integer | No | Page number for pagination. |
| `status` | string | No | Document status filter. |
| `tahun` | string | No | Year of publication filter (e.g. '2026'). |
| `tema` | string | No | Topic/Theme filter. |
| `teu` | string | No | Tajuk Entri Utama (Issuing Body) filter. |

```bash
curl -X POST https://api.paywithlocus.com/api/wrapped/parse-jdih-kemenkeu-go-id-api-f8e40d83/search_documents \
  -H "Authorization: Bearer YOUR_LOCUS_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"bentuk":"<string>","keyword":"<string>","label":"<string>","nomor":"<string>","order":"<string>","page":"<integer>","status":"<string>","tahun":"<string>","tema":"<string>","teu":"<string>"}'
```
