SeaTable

App · 20 actions

Read and update rows, tables, views and comments in a SeaTable base.

Actions

ActionWhat it does
Append rowsAdd up to 1,000 new rows to a table by its name, optionally filling empty cells with the columns' default values.
Create row commentAdd a comment to a row, picked by its table ID and row ID.
Create tableCreate a new, empty table with the given name in the connected base.
Create viewCreate a new view on a table, either a normal or an archive view, optionally locked.
Delete commentDelete a comment from a row by the comment's ID.
Delete rowDelete up to 10,000 rows from a table by their row IDs.
Delete tableDelete a table, picked by its name, from the connected base along with all of its rows.
Delete viewDelete a view from a table by its name.
Get commentGet one row comment by its ID, returning its author, text, time and whether it is resolved.
Get metadataGet the structure of the connected base, returning each table with its columns and views.
Get rowGet one row from a table by its row ID, returning all of its cell values.
Get viewGet one view of a table by its name, returning its type, filters, sorts, grouping and hidden columns.
List collaboratorsList the people who can access the connected base, with each user's name, email address and ID.
List columnsList the columns of a table by its name, optionally only those shown in one view.
List row commentsList the comments left on a row, picked by its row ID, with each comment's author, text and time.
List rowsList the rows of a table by its name, optionally limited to one view.
List viewsList the views of a table by its name, returning each view's name, type, filters and sorts.
Query sqlRun a SQL statement against the connected base, with optional parameters for any question marks in it.
Rename tableRename a table in the connected base, picked by its current name.
Update rowChange cell values in up to 1,000 existing rows of a table, each picked by its row ID.

Append rows

Add up to 1,000 new rows to a table by its name, optionally filling empty cells with the columns' default values. Returns how many rows were inserted.

Inputs

Table nametable_nametextRequired
The name of the table to perform the operation on. Alternatively, you can use the `table_id` instead of `table_name`. If using `table_id`, ensure that the key in the request body is replaced accordingly.
RowsrowslistRequired
Defines the rows which should be added. Maximum 1,000 rows per call.
Apply defaultapply_defaulttrue/false
Use the column default values to populate new rows during creation. False by default.

Outputs

dataobject
Response.
Example output
{
  "data": {
    "first_row": {},
    "inserted_row_count": 1,
    "row_ids": []
  }
}

Create row comment

Add a comment to a row, picked by its table ID and row ID. Returns the new comment.

Inputs

Table IDtable_idtextRequired
Table ID.
Row IDrow_idtextRequired
Row ID.
CommentcommenttextRequired
Comment.

Outputs

dataobject
Response.
Example output
{
  "data": {
    "comment": "example",
    "id": 1
  }
}

Create table

Create a new, empty table with the given name in the connected base. Returns the new table with its ID and default columns.

Inputs

Table nametable_nametextRequired
The name of the table to perform the operation on. Alternatively, you can use the `table_id` instead of `table_name`. If using `table_id`, ensure that the key in the request body is replaced accordingly.

Outputs

dataobject
Response.
Example output
{
  "data": {
    "_id": "example",
    "columns": [],
    "name": "example"
  }
}

Create view

Create a new view on a table, either a normal or an archive view, optionally locked. Returns the new view.

Inputs

Table nametable_nametextRequired
Table name.
NamenametextRequired
Name of the new view.
TypetypetextRequired
Type of the view, either normal view or a big data view. The default value is *table*.One of: table, archive.
Is lockedis_lockedtrue/false
Is locked.

Outputs

dataobject
Response.
Example output
{
  "data": {
    "_id": "example",
    "name": "example",
    "type": "example"
  }
}

Delete comment

Delete a comment from a row by the comment's ID.

Inputs

Comment IDcomment_idnumberRequired
Comment ID.At least 1.

Outputs

dataobject
Response.
Example output
{
  "data": {}
}

Delete row

Delete up to 10,000 rows from a table by their row IDs. Returns how many rows were deleted.

Inputs

Table nametable_nametextRequired
The name of the table to perform the operation on. Alternatively, you can use the `table_id` instead of `table_name`. If using `table_id`, ensure that the key in the request body is replaced accordingly.
Row IDsrow_idslistRequired
Defines the rows which should be deleted. Maximum 10,000 row IDs per call.

Outputs

dataobject
Response.
Example output
{
  "data": {
    "deleted_rows": 1
  }
}

Delete table

Delete a table, picked by its name, from the connected base along with all of its rows.

Inputs

Table nametable_nametextRequired
The name of the table to perform the operation on. Alternatively, you can use the `table_id` instead of `table_name`. If using `table_id`, ensure that the key in the request body is replaced accordingly.

Outputs

dataobject
Response.
Example output
{
  "data": {}
}

Delete view

Delete a view from a table by its name. The table's rows are not affected.

Inputs

View nameview_nametextRequired
View name.
Table nametable_nametextRequired
Table name.

Outputs

dataobject
Response.
Example output
{
  "data": {}
}

Get comment

Get one row comment by its ID, returning its author, text, time and whether it is resolved.

Inputs

Comment IDcomment_idnumberRequired
Comment ID.At least 1.

Outputs

dataobject
Response.
Example output
{
  "data": {
    "author": "example",
    "comment": "example",
    "created_at": "example",
    "dtable_uuid": "example",
    "id": 1,
    "resolved": 1,
    "row_id": "example",
    "updated_at": "example"
  }
}

Get metadata

Get the structure of the connected base, returning each table with its columns and views.

Inputs

None.

Outputs

dataobject
Response.
Example output
{
  "data": {
    "metadata": {
      "tables": []
    }
  }
}

Get row

Get one row from a table by its row ID, returning all of its cell values.

Inputs

Row IDrow_idtextRequired
Row ID.
Table nametable_nametextRequired
Table name.
Convert keysconvert_keystrue/false
Convert keys.

Outputs

dataobject
Response.
Example output
{
  "data": {}
}

Get view

Get one view of a table by its name, returning its type, filters, sorts, grouping and hidden columns.

Inputs

View nameview_nametextRequired
View name.
Table nametable_nametextRequired
Table name.

Outputs

dataobject
Response.
Example output
{
  "data": {
    "_id": "example",
    "name": "example",
    "type": "example"
  }
}

List collaborators

List the people who can access the connected base, with each user's name, email address and ID.

Inputs

None.

Outputs

dataobject
Response.
Example output
{
  "data": {}
}

List columns

List the columns of a table by its name, optionally only those shown in one view. Returns each column's name, key and type.

Inputs

Table nametable_nametextRequired
Table name.
View nameview_nametext
View name.

Outputs

dataobject
Response.
Example output
{
  "data": {}
}

List row comments

List the comments left on a row, picked by its row ID, with each comment's author, text and time.

Inputs

Row IDrow_idtextRequired
Row ID.

Outputs

datalist
Response.
Example output
{
  "data": []
}

List rows

List the rows of a table by its name, optionally limited to one view. Returns one page of rows; use start and limit for the next page.

Inputs

Table nametable_nametextRequired
Table name.
View nameview_nametext
View name.
Startstartnumber
Start.
Limitlimitnumber
Limit.From 1 to 1000.
Convert keysconvert_keystrue/false
Convert keys.

Outputs

dataobject
Response.
Example output
{
  "data": {
    "rows": []
  }
}

List views

List the views of a table by its name, returning each view's name, type, filters and sorts.

Inputs

Table nametable_nametextRequired
Table name.

Outputs

dataobject
Response.
Example output
{
  "data": {
    "views": []
  }
}

Query sql

Run a SQL statement against the connected base, with optional parameters for any question marks in it. Returns the matching rows and their column metadata.

Inputs

SqlsqltextRequired
SQL-Query to get rows from base.
Convert keysconvert_keystrue/false
Determines if the columns are returned as their keys (false by default) or their names (true).
Parametersparameterslist
Parameters in SQL clause to avoid sql injection. Only needed, if you use `?` in the SQL statement. The parameters will replace the `?` according to their order in the array.
Server onlyserver_onlytrue/false
Show rows from normal and Big Data backend (false by default) or limit the output only to the normal backend (true).

Outputs

dataobject
Response.
Example output
{
  "data": {
    "metadata": [],
    "results": [],
    "success": false
  }
}

Rename table

Rename a table in the connected base, picked by its current name. Returns the updated table.

Inputs

Table nametable_nametextRequired
The name of the table to perform the operation on. Alternatively, you can use the `table_id` instead of `table_name`. If using `table_id`, ensure that the key in the request body is replaced accordingly.
New table namenew_table_nametextRequired
New table name.

Outputs

dataobject
Response.
Example output
{
  "data": {}
}

Update row

Change cell values in up to 1,000 existing rows of a table, each picked by its row ID. Only the columns you supply are changed.

Inputs

Table nametable_nametextRequired
The name of the table to perform the operation on. Alternatively, you can use the `table_id` instead of `table_name`. If using `table_id`, ensure that the key in the request body is replaced accordingly.
UpdatesupdateslistRequired
Defines the rows which should be updated. Maximum 1,000 rows per call.

Outputs

dataobject
Response.
Example output
{
  "data": {}
}

On this page