Create a table within a specified keyspace

POST /v1/keyspaces/table/create

Body Required

  • keyspace_name string Required

    The keyspace in which to create the table

  • table_name string Required

    The name of the table to create

  • columns array[object] Required

    List of columns for the table

    Hide columns attributes Show columns attributes object
    • name string Required

      Column name

    • type string Required

      Data type of the column

  • partition_key array[string] Required

    List of columns forming the partition key

  • clustering_columns array[string]

    List of clustering columns, optional

Responses

  • 200

    Success

POST /v1/keyspaces/table/create
curl \
 -X POST https://api.infura.ai/v1/keyspaces/table/create \
 -H "x-api-key: $API_KEY" \
 -d '{"keyspace_name":"string","table_name":"string","columns":[{"name":"string","type":"string"}],"partition_key":["string"],"clustering_columns":["string"]}'
Request example
{
  "keyspace_name": "string",
  "table_name": "string",
  "columns": [
    {
      "name": "string",
      "type": "string"
    }
  ],
  "partition_key": [
    "string"
  ],
  "clustering_columns": [
    "string"
  ]
}