# Transjakarta



Every Transjakarta route and stop, with its full GTFS feed.



## Transjakarta Routes

Every Transjakarta route with its number, destination, and stop count — 240 of them.

- Method: `GET`
- Path: `/v1/transit/transjakarta/routes`

**Parameters**

| Name | Type | | Description |
|---|---|---|---|
| `q` | string | optional | Match a route number or destination. |
| `mode` | string | optional | `bus`, `metro`, `rail`, `tram`, `ferry`. Transjakarta itself is bus-only; the value exists because the underlying field does, and other networks will use it once they're added. |
| `limit` | integer | optional | 1 to 200. |

**Example request**

```bash
curl https://api.diraz.ae/v1/transit/transjakarta/routes \
  -H "Authorization: Bearer drz_live_…"
```

**Example response**

```json
{
  "data": {
    "agency": {
      "name": "Transjakarta",
      "url": "https://transjakarta.co.id/",
      "timezone": "Asia/Jakarta"
    },
    "routes": [
      { "id": "1W", "short_name": "1W", "long_name": "Blok M - Ancol", "mode": "bus", "stop_count": 42 }
    ]
  },
  "meta": {
    "request_id": "req_7Q2fK4mZ",
    "as_of": "2026-08-19T02:00:00.000Z",
    "age_seconds": 42,
    "next_update_at": "2026-08-19T02:30:00.000Z"
  }
}
```

## Transjakarta Stops

8,000 Transjakarta stops, searchable by name, filtered to a route, or found by walking distance from a point.

- Method: `GET`
- Path: `/v1/transit/transjakarta/stops`

**Parameters**

| Name | Type | | Description |
|---|---|---|---|
| `q` | string | optional | Match a stop name. |
| `route_id` | string | optional | Only stops this route serves. |
| `lat` | number | optional | With `lon`, return stops near a point, nearest first. |
| `lon` | number | optional | Must be given with `lat`. |
| `radius_km` | number | optional | How far to look from `lat`/`lon`. |
| `limit` | integer | optional | 1 to 100. |

**Example request**

```bash
curl https://api.diraz.ae/v1/transit/transjakarta/stops \
  -H "Authorization: Bearer drz_live_…"
```

**Example response**

```json
{
  "data": {
    "agency": {
      "name": "Transjakarta",
      "url": "https://transjakarta.co.id/",
      "timezone": "Asia/Jakarta"
    },
    "stops": [
      { "id": "B00123", "name": "Bundaran HI", "lat": -6.19501, "lon": 106.82302, "distance_km": 0.412 }
    ]
  },
  "meta": {
    "request_id": "req_7Q2fK4mZ",
    "as_of": "2026-08-19T02:00:00.000Z",
    "age_seconds": 42,
    "next_update_at": "2026-08-19T02:30:00.000Z"
  }
}
```