# Events (/en/docs/api/native/database/events)



[Guide →](/en/docs/developers/services/database/quickstart)

[Base URL and authentication](/en/docs/api/native/database)

Events record database lifecycle and table/field changes, not row reads or writes.

Defaults to ascending seq; before\_seq alone implies desc (newest first). next\_cursor is an opaque string cursor — pass it back unchanged, as after\_seq for asc or before\_seq for desc. Both cursors together, or before\_seq with order=asc, return 400 INVALID\_PARAMS. Events remain readable while a database is deleting.

next\_cursor is an opaque string cursor: pass it back unchanged and do not do arithmetic on it. A null next\_cursor means there is no next page. The captured response below uses the default ascending order. Descending pagination uses the requests below; live responses for this extension will be added after the service update.

```bash
# Newest page
curl "https://api.deepraxis.ai/database/v1/databases/${DATABASE_ID}/events?order=desc&limit=10" \
  -H "Authorization: Bearer $PRAXIS_API_KEY"

# Set NEXT_CURSOR to the previous response's next_cursor
curl "https://api.deepraxis.ai/database/v1/databases/${DATABASE_ID}/events?order=desc&before_seq=${NEXT_CURSOR}&limit=10" \
  -H "Authorization: Bearer $PRAXIS_API_KEY"
```

## List events [#list-events]

`GET /database/v1/databases/{database_id}/events`

| Parameter | Location | Description |
| --- | --- | --- |
| database_id | path | Identifier of the database to act on: the id (db_…) returned by databaseCreateDatabase or databaseListDatabases. A display name is not accepted. |
| after_seq | query | With order=asc, return only events with seq greater than this value. Cannot be combined with before_seq. |
| limit | query | Page size. (default: 50) (1–200) |
| order | query | Sequence order: asc or desc (newest first). Defaults to asc, or to desc when before_seq is supplied. |
| before_seq | query | Return only events with seq less than this value, newest first; implies order=desc when order is omitted. Cannot be combined with after_seq or order=asc. |

Returns: `Page + object`.

### Response [#response]

#### HTTP 200 [#http-200]

Success

**application/json**

| Name | Type | Description |
| --- | --- | --- |
| data | array&lt;object&gt; | Events on this page in the requested order (ascending seq by default, newest first with before_seq or order=desc). |
| data[].seq | integer | Position of the event in the database's event log; starts at 1 and strictly increases. Use it as after_seq or before_seq to page. |
| data[].id | string | Unique identifier of this event record. |
| data[].type | string | What happened: a lifecycle transition of the database, or a schema change to a table or field. |
| data[].processed_at | string | Time the event was recorded, as an RFC 3339 UTC timestamp. |
| data[].database_id | string | Id (db_…) of the database the event belongs to. |
| data[].table_id | string | Id (tbl_…) of the affected table; present only for table and field events. |
| data[].field_id | string | Id (fld_…) of the affected field; present only for field events. |
| next_cursor | string &#124; null | Opaque cursor for the next page, or null when there are no more items. Databases list: pass it as cursor. Events list: pass it as after_seq (order asc) or before_seq (order desc). |

```bash
curl -X GET "https://api.deepraxis.ai/database/v1/databases/${DATABASE_ID}/events?after_seq=0&limit=10" \
  -H "Authorization: Bearer $PRAXIS_API_KEY"
```

Response example — HTTP 200

```json
{
  "data": [
    {
      "seq": 1,
      "id": "7390d75e-216c-4799-891e-c043bac8bce5",
      "type": "database.status_provisioning",
      "processed_at": "2026-10-11T17:41:41.339Z",
      "database_id": "db_d6f0d743d5a645e8"
    },
    {
      "seq": 2,
      "id": "39db0ef4-99b4-4846-9d50-9998e25cf48f",
      "type": "database.status_active",
      "processed_at": "2026-10-11T17:41:41.339Z",
      "database_id": "db_d6f0d743d5a645e8"
    },
    {
      "seq": 3,
      "id": "d295651d-5e83-4b42-bcd3-c979fb71f375",
      "type": "table.created",
      "processed_at": "2026-10-11T17:41:44.246Z",
      "database_id": "db_d6f0d743d5a645e8",
      "table_id": "tbl_2b3431c772754599"
    },
    {
      "seq": 4,
      "id": "eb255753-3dd7-4eae-8861-d53408bfcaf4",
      "type": "table.updated",
      "processed_at": "2026-10-11T17:41:45.127Z",
      "database_id": "db_d6f0d743d5a645e8",
      "table_id": "tbl_2b3431c772754599"
    },
    {
      "seq": 5,
      "id": "99c86e22-0629-4391-85e5-d7b8b31de833",
      "type": "field.added",
      "processed_at": "2026-10-11T17:41:45.420Z",
      "database_id": "db_d6f0d743d5a645e8",
      "table_id": "tbl_2b3431c772754599",
      "field_id": "fld_4c3e63869e35458c"
    },
    {
      "seq": 6,
      "id": "a9b85950-363d-4ab3-8c85-6228eec3d099",
      "type": "field.updated",
      "processed_at": "2026-10-11T17:41:46.276Z",
      "database_id": "db_d6f0d743d5a645e8",
      "table_id": "tbl_2b3431c772754599",
      "field_id": "fld_4c3e63869e35458c"
    },
    {
      "seq": 7,
      "id": "73ca124f-6cbb-4a43-8a37-4ff50a211dd5",
      "type": "field.deleted",
      "processed_at": "2026-10-11T17:41:47.136Z",
      "database_id": "db_d6f0d743d5a645e8",
      "table_id": "tbl_2b3431c772754599",
      "field_id": "fld_4c3e63869e35458c"
    }
  ],
  "next_cursor": null
}
```

## DatabaseEvent [#databaseevent]

| Field | Type | Required | Description |
| --- | --- | --- | --- |
| seq | integer | yes | Position of the event in the database's event log; starts at 1 and strictly increases. Use it as after_seq or before_seq to page. |
| id | string | yes | Unique identifier of this event record. |
| type | "database.status_provisioning" / "database.status_active" / "database.status_deleting" / "database.status_deleted" / "database.status_failed" / "database.restored" / "table.created" / "table.updated" / "table.deleted" / "field.added" / "field.updated" / "field.deleted" | yes | What happened: a lifecycle transition of the database, or a schema change to a table or field. |
| processed_at | date-time | yes | Time the event was recorded, as an RFC 3339 UTC timestamp. |
| database_id | string | yes | Id (db_…) of the database the event belongs to. |
| table_id | string | no | Id (tbl_…) of the affected table; present only for table and field events. |
| field_id | string | no | Id (fld_…) of the affected field; present only for field events. |
