PATCH
/
api
/
database
/
tables
/
{tableName}
{
"message": "Table schema updated successfully",
"tableName": "posts",
"operations": [
"added 2 columns",
"dropped 1 columns",
"renamed 1 columns",
"added 1 foreign keys",
"dropped 1 foreign keys"
]
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

tableName
string
required

Body

application/json
addColumns
object[]

Add new columns to the table

dropColumns
string[]

Remove columns from the table

Name of the column to drop

updateColumns
object[]

Modify existing columns (rename or change default)

addForeignKeys
object[]

Add foreign key constraints to existing columns

dropForeignKeys
string[]

Remove foreign key constraints from columns

Name of the column with foreign key to drop

renameTable
object

Rename the table

Response

Table schema updated successfully

message
string

Success message

tableName
string

Name of the updated table

operations
string[]

List of operations performed