API Documentation
Organization -> Organizations
Organization -> Workspaces
Organization -> Projects
Projects (Deprecated)
Projects -> Api Key
Connections
Data -> Catalogs
Data -> Internal Tables
Data -> Queries
Data -> Semantic Catalogs
Data -> Cache
Embedded Peaka Api
Supported Drivers
Data -> Metadata
- PUTUpdate Metadata
- PUTUpdate Relation From Metadata
- DELDelete Relation From Metadata
- PUTGenerate categorical values from the the column.
- POSTGenerate semantics for the table
- POSTAdd Relation To Metadata
- GETList of golden sqls for the project.
- POSTCreate golden sql for the project
- GETGet Project Metadata
- GETGet Project Catalog Metadata Relations
- GETGenerate sample ai questions for the project
- DELDelete golden sql from the project.
Table Statistics
GET
/
data
/
projects
/
{projectId}
/
catalogs
/
{catalogId}
/
schemas
/
{schemaName}
/
tables
/
{tableName}
/
statistics
curl --request GET \
--url https://partner.peaka.studio/api/v1/data/projects/{projectId}/catalogs/{catalogId}/schemas/{schemaName}/tables/{tableName}/statistics
{
"catalogId": "846085284821991568",
"schemaName": "public",
"tableName": "actor",
"columnStatistics": [
{
"columnName": "actor_id",
"distinctFraction": -1
},
{
"columnName": "first_name",
"distinctFraction": -0.64
},
{
"columnName": "last_name",
"distinctFraction": -0.605
},
{
"columnName": "last_update",
"distinctFraction": 1
}
]
}
Path Parameters
ID of the project
ID of the catalog
Name of the schema
Name of the table
Response
200 - application/json
Successful operation
The ID of the catalog.
The name of the schema.
The name of the table.
Statistics for each column in the table.
The name of the column.
The estimated fraction of distinct values in a column compared to the total number of rows in the table. It helps in query optimization, statistics collection, and cardinality estimation in database systems.
curl --request GET \
--url https://partner.peaka.studio/api/v1/data/projects/{projectId}/catalogs/{catalogId}/schemas/{schemaName}/tables/{tableName}/statistics
{
"catalogId": "846085284821991568",
"schemaName": "public",
"tableName": "actor",
"columnStatistics": [
{
"columnName": "actor_id",
"distinctFraction": -1
},
{
"columnName": "first_name",
"distinctFraction": -0.64
},
{
"columnName": "last_name",
"distinctFraction": -0.605
},
{
"columnName": "last_update",
"distinctFraction": 1
}
]
}