Skip to content

API reference

Rows

The records in a table: list, filter, aggregate, create, edit and bulk-write them.

List rows

GET/v1/projects/{project_id}/tables/{table_id}/rows

Path parameters

  • project_idstringRequired
  • table_idstringRequired

Query parameters

  • cursorstringoptional
  • filterstringoptional
  • limitintegeroptional
    Default
    20

    Between 1 and 100.

  • orderstringoptional
  • pageintegeroptional

    At least 1.

  • qstringoptional

    Up to 200 characters.

Returns

200application/json

  • countintegerRequired

    At least 0.

  • hasMorebooleanRequired
  • limitintegerRequired

    At least 1.

  • nextCursorstringRequirednullable
  • pageintegerRequirednullable

    At least 1.

  • rowsarray of objectsRequired

Errors

  • 404not_foundtable_not_found
Errors every endpoint can return
import { AnyrowSDK } from "@anyrow/sdk"const anyrow = new AnyrowSDK({  baseURL: "https://api.anyrow.ai",  headers: { Authorization: `ApiKey ${process.env.ANYROW_API_KEY}` },})const { data, error } = await anyrow.row.list({  params: {    project_id: "{project_id}",    table_id: "{table_id}"  },})
{  "count": 0,  "hasMore": true,  "limit": 1,  "nextCursor": "string",  "page": 1,  "rows": [    {}  ]}

Create row

POST/v1/projects/{project_id}/tables/{table_id}/rows

Path parameters

  • project_idstringRequired
  • table_idstringRequired

Request body

application/json

    Returns

    201application/json

    Errors

    • 404not_foundtable_not_found
    Errors every endpoint can return
    import { AnyrowSDK } from "@anyrow/sdk"const anyrow = new AnyrowSDK({  baseURL: "https://api.anyrow.ai",  headers: { Authorization: `ApiKey ${process.env.ANYROW_API_KEY}` },})const { data, error } = await anyrow.row.create({  params: {    project_id: "{project_id}",    table_id: "{table_id}"  },  json: {},})
    {}

    Aggregate column values

    GET/v1/projects/{project_id}/tables/{table_id}/rows/aggregate

    Path parameters

    • project_idstringRequired
    • table_idstringRequired

    Query parameters

    • aggsstringRequired
    • filterstringoptional

    Returns

    200application/json

    Errors

    • 404not_foundtable_not_found
    Errors every endpoint can return
    import { AnyrowSDK } from "@anyrow/sdk"const anyrow = new AnyrowSDK({  baseURL: "https://api.anyrow.ai",  headers: { Authorization: `ApiKey ${process.env.ANYROW_API_KEY}` },})const { data, error } = await anyrow.row.aggregate({  params: {    project_id: "{project_id}",    table_id: "{table_id}"  },  search: {    aggs: "{aggs}"  },})
    {  "key": 0}

    Bulk create/update/delete rows

    POST/v1/projects/{project_id}/tables/{table_id}/rows/bulk

    Path parameters

    • project_idstringRequired
    • table_idstringRequired

    Request body

    application/json

    • createsarray of objectsoptional

      Up to 1000 items.

    • deletesarray of stringsoptional

      Up to 1000 items.

    • updatesarray of objectsoptional

      Up to 1000 items.

    Returns

    200application/json

    • createdarray of objectsoptional
    • deletedarray of stringsoptional
    • updatedarray of objectsoptional

    Errors

    • 404not_foundtable_not_found
    Errors every endpoint can return
    import { AnyrowSDK } from "@anyrow/sdk"const anyrow = new AnyrowSDK({  baseURL: "https://api.anyrow.ai",  headers: { Authorization: `ApiKey ${process.env.ANYROW_API_KEY}` },})const { data, error } = await anyrow.row.bulk({  params: {    project_id: "{project_id}",    table_id: "{table_id}"  },  json: {    creates: [      {}    ],    deletes: [      "string"    ],    updates: [      {        data: {},        id: "string"      }    ]  },})
    {  "created": [    {}  ],  "deleted": [    "string"  ],  "updated": [    {}  ]}

    Get row

    GET/v1/projects/{project_id}/tables/{table_id}/rows/{row_id}

    Path parameters

    • project_idstringRequired
    • table_idstringRequired
    • row_idstringRequired

    Returns

    200application/json

    Errors

    • 404not_foundrow_not_foundtable_not_found
    Errors every endpoint can return
    import { AnyrowSDK } from "@anyrow/sdk"const anyrow = new AnyrowSDK({  baseURL: "https://api.anyrow.ai",  headers: { Authorization: `ApiKey ${process.env.ANYROW_API_KEY}` },})const { data, error } = await anyrow.row.get({  params: {    project_id: "{project_id}",    table_id: "{table_id}",    row_id: "{row_id}"  },})
    {}

    Update row

    PATCH/v1/projects/{project_id}/tables/{table_id}/rows/{row_id}

    Path parameters

    • project_idstringRequired
    • table_idstringRequired
    • row_idstringRequired

    Request body

    application/json

      Returns

      200application/json

      Errors

      • 404not_foundrow_not_foundtable_not_found
      Errors every endpoint can return
      import { AnyrowSDK } from "@anyrow/sdk"const anyrow = new AnyrowSDK({  baseURL: "https://api.anyrow.ai",  headers: { Authorization: `ApiKey ${process.env.ANYROW_API_KEY}` },})const { data, error } = await anyrow.row.update({  params: {    project_id: "{project_id}",    table_id: "{table_id}",    row_id: "{row_id}"  },  json: {},})
      {}

      Delete row

      DELETE/v1/projects/{project_id}/tables/{table_id}/rows/{row_id}

      Path parameters

      • project_idstringRequired
      • table_idstringRequired
      • row_idstringRequired

      Returns

      200application/json

      • idstringRequired

      Errors

      • 404not_foundrow_not_foundtable_not_found
      Errors every endpoint can return
      import { AnyrowSDK } from "@anyrow/sdk"const anyrow = new AnyrowSDK({  baseURL: "https://api.anyrow.ai",  headers: { Authorization: `ApiKey ${process.env.ANYROW_API_KEY}` },})const { data, error } = await anyrow.row.delete({  params: {    project_id: "{project_id}",    table_id: "{table_id}",    row_id: "{row_id}"  },})
      {  "id": "string"}

      The source file behind a row: download it, or open a PDF or image inline

      GET/v1/projects/{project_id}/tables/{table_id}/rows/{row_id}/source

      Path parameters

      • project_idstringRequired
      • table_idstringRequired
      • row_idstringRequired

      Query parameters

      • dispositionstringoptional
        Allowed values
        attachmentinline
        Default
        attachment

      Returns

      200application/octet-stream

      Errors

      • 404not_foundrow_not_foundrow_source_not_foundtable_not_found
      Errors every endpoint can return
      import { AnyrowSDK } from "@anyrow/sdk"const anyrow = new AnyrowSDK({  baseURL: "https://api.anyrow.ai",  headers: { Authorization: `ApiKey ${process.env.ANYROW_API_KEY}` },})const { data, error } = await anyrow.row.source({  params: {    project_id: "{project_id}",    table_id: "{table_id}",    row_id: "{row_id}"  },})