All URIs are relative to https://api.hotdata.dev
| Method | HTTP request | Description |
|---|---|---|
| create_dataset | POST /v1/datasets | Create dataset |
| delete_dataset | DELETE /v1/datasets/{id} | Delete dataset |
| get_dataset | GET /v1/datasets/{id} | Get dataset |
| list_dataset_versions | GET /v1/datasets/{id}/versions | List dataset versions |
| list_datasets | GET /v1/datasets | List datasets |
| update_dataset | PUT /v1/datasets/{id} | Update dataset |
CreateDatasetResponse create_dataset(create_dataset_request, x_database_id=x_database_id)
Create dataset
Create a new dataset from an uploaded file, inline data, a URL, or a SQL/saved query. The dataset becomes a queryable table under the datasets schema (e.g., SELECT * FROM datasets.my_table). Supports CSV, JSON, and Parquet formats. Optionally specify explicit column types.
For sql_query / saved_query sources the dataset materializes by running that SQL, so the X-Database-Id header is required and the query sees only that database's catalogs (the scope is also reused on refresh). Upload/url/inline sources ignore the header.
- Api Key Authentication (WorkspaceId):
- Api Key Authentication (SessionId):
- Bearer Authentication (BearerAuth):
import hotdata
from hotdata.models.create_dataset_request import CreateDatasetRequest
from hotdata.models.create_dataset_response import CreateDatasetResponse
from hotdata.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to https://api.hotdata.dev
# See configuration.py for a list of all supported configuration parameters.
configuration = hotdata.Configuration(
host = "https://api.hotdata.dev"
)
# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.
# Configure API key authorization: WorkspaceId
configuration.api_key['WorkspaceId'] = os.environ["API_KEY"]
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['WorkspaceId'] = 'Bearer'
# Configure API key authorization: SessionId
configuration.api_key['SessionId'] = os.environ["API_KEY"]
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['SessionId'] = 'Bearer'
# Configure Bearer authorization: BearerAuth
configuration = hotdata.Configuration(
access_token = os.environ["BEARER_TOKEN"]
)
# Enter a context with an instance of the API client
with hotdata.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = hotdata.DatasetsApi(api_client)
create_dataset_request = hotdata.CreateDatasetRequest() # CreateDatasetRequest |
x_database_id = 'x_database_id_example' # str | Required for query-backed datasets (sql_query / saved_query): the database whose catalogs the materializing query runs against. An unknown id is a 404. (optional)
try:
# Create dataset
api_response = api_instance.create_dataset(create_dataset_request, x_database_id=x_database_id)
print("The response of DatasetsApi->create_dataset:\n")
pprint(api_response)
except Exception as e:
print("Exception when calling DatasetsApi->create_dataset: %s\n" % e)| Name | Type | Description | Notes |
|---|---|---|---|
| create_dataset_request | CreateDatasetRequest | ||
| x_database_id | str | Required for query-backed datasets (sql_query / saved_query): the database whose catalogs the materializing query runs against. An unknown id is a 404. | [optional] |
WorkspaceId, SessionId, BearerAuth
- Content-Type: application/json
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 201 | Dataset created | - |
| 400 | Invalid request (query-backed dataset without X-Database-Id) | - |
| 404 | Database (from X-Database-Id) not found | - |
| 409 | Dataset already exists | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
delete_dataset(id)
Delete dataset
- Api Key Authentication (WorkspaceId):
- Api Key Authentication (SessionId):
- Bearer Authentication (BearerAuth):
import hotdata
from hotdata.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to https://api.hotdata.dev
# See configuration.py for a list of all supported configuration parameters.
configuration = hotdata.Configuration(
host = "https://api.hotdata.dev"
)
# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.
# Configure API key authorization: WorkspaceId
configuration.api_key['WorkspaceId'] = os.environ["API_KEY"]
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['WorkspaceId'] = 'Bearer'
# Configure API key authorization: SessionId
configuration.api_key['SessionId'] = os.environ["API_KEY"]
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['SessionId'] = 'Bearer'
# Configure Bearer authorization: BearerAuth
configuration = hotdata.Configuration(
access_token = os.environ["BEARER_TOKEN"]
)
# Enter a context with an instance of the API client
with hotdata.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = hotdata.DatasetsApi(api_client)
id = 'id_example' # str | Dataset ID
try:
# Delete dataset
api_instance.delete_dataset(id)
except Exception as e:
print("Exception when calling DatasetsApi->delete_dataset: %s\n" % e)| Name | Type | Description | Notes |
|---|---|---|---|
| id | str | Dataset ID |
void (empty response body)
WorkspaceId, SessionId, BearerAuth
- Content-Type: Not defined
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 204 | Dataset deleted | - |
| 404 | Dataset not found | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
GetDatasetResponse get_dataset(id)
Get dataset
- Api Key Authentication (WorkspaceId):
- Bearer Authentication (BearerAuth):
import hotdata
from hotdata.models.get_dataset_response import GetDatasetResponse
from hotdata.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to https://api.hotdata.dev
# See configuration.py for a list of all supported configuration parameters.
configuration = hotdata.Configuration(
host = "https://api.hotdata.dev"
)
# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.
# Configure API key authorization: WorkspaceId
configuration.api_key['WorkspaceId'] = os.environ["API_KEY"]
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['WorkspaceId'] = 'Bearer'
# Configure Bearer authorization: BearerAuth
configuration = hotdata.Configuration(
access_token = os.environ["BEARER_TOKEN"]
)
# Enter a context with an instance of the API client
with hotdata.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = hotdata.DatasetsApi(api_client)
id = 'id_example' # str | Dataset ID
try:
# Get dataset
api_response = api_instance.get_dataset(id)
print("The response of DatasetsApi->get_dataset:\n")
pprint(api_response)
except Exception as e:
print("Exception when calling DatasetsApi->get_dataset: %s\n" % e)| Name | Type | Description | Notes |
|---|---|---|---|
| id | str | Dataset ID |
- Content-Type: Not defined
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 200 | Dataset details | - |
| 404 | Dataset not found | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
ListDatasetVersionsResponse list_dataset_versions(id, limit=limit, offset=offset)
List dataset versions
- Api Key Authentication (WorkspaceId):
- Bearer Authentication (BearerAuth):
import hotdata
from hotdata.models.list_dataset_versions_response import ListDatasetVersionsResponse
from hotdata.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to https://api.hotdata.dev
# See configuration.py for a list of all supported configuration parameters.
configuration = hotdata.Configuration(
host = "https://api.hotdata.dev"
)
# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.
# Configure API key authorization: WorkspaceId
configuration.api_key['WorkspaceId'] = os.environ["API_KEY"]
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['WorkspaceId'] = 'Bearer'
# Configure Bearer authorization: BearerAuth
configuration = hotdata.Configuration(
access_token = os.environ["BEARER_TOKEN"]
)
# Enter a context with an instance of the API client
with hotdata.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = hotdata.DatasetsApi(api_client)
id = 'id_example' # str | Dataset ID
limit = 56 # int | Maximum number of versions (default: 100, max: 1000) (optional)
offset = 56 # int | Pagination offset (default: 0) (optional)
try:
# List dataset versions
api_response = api_instance.list_dataset_versions(id, limit=limit, offset=offset)
print("The response of DatasetsApi->list_dataset_versions:\n")
pprint(api_response)
except Exception as e:
print("Exception when calling DatasetsApi->list_dataset_versions: %s\n" % e)| Name | Type | Description | Notes |
|---|---|---|---|
| id | str | Dataset ID | |
| limit | int | Maximum number of versions (default: 100, max: 1000) | [optional] |
| offset | int | Pagination offset (default: 0) | [optional] |
- Content-Type: Not defined
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 200 | List of dataset versions | - |
| 404 | Dataset not found | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
ListDatasetsResponse list_datasets(limit=limit, offset=offset)
List datasets
- Api Key Authentication (WorkspaceId):
- Api Key Authentication (SessionId):
- Bearer Authentication (BearerAuth):
import hotdata
from hotdata.models.list_datasets_response import ListDatasetsResponse
from hotdata.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to https://api.hotdata.dev
# See configuration.py for a list of all supported configuration parameters.
configuration = hotdata.Configuration(
host = "https://api.hotdata.dev"
)
# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.
# Configure API key authorization: WorkspaceId
configuration.api_key['WorkspaceId'] = os.environ["API_KEY"]
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['WorkspaceId'] = 'Bearer'
# Configure API key authorization: SessionId
configuration.api_key['SessionId'] = os.environ["API_KEY"]
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['SessionId'] = 'Bearer'
# Configure Bearer authorization: BearerAuth
configuration = hotdata.Configuration(
access_token = os.environ["BEARER_TOKEN"]
)
# Enter a context with an instance of the API client
with hotdata.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = hotdata.DatasetsApi(api_client)
limit = 56 # int | Maximum number of datasets (default: 100, max: 1000) (optional)
offset = 56 # int | Pagination offset (default: 0) (optional)
try:
# List datasets
api_response = api_instance.list_datasets(limit=limit, offset=offset)
print("The response of DatasetsApi->list_datasets:\n")
pprint(api_response)
except Exception as e:
print("Exception when calling DatasetsApi->list_datasets: %s\n" % e)| Name | Type | Description | Notes |
|---|---|---|---|
| limit | int | Maximum number of datasets (default: 100, max: 1000) | [optional] |
| offset | int | Pagination offset (default: 0) | [optional] |
WorkspaceId, SessionId, BearerAuth
- Content-Type: Not defined
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 200 | List of datasets | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]
UpdateDatasetResponse update_dataset(id, update_dataset_request)
Update dataset
- Api Key Authentication (WorkspaceId):
- Api Key Authentication (SessionId):
- Bearer Authentication (BearerAuth):
import hotdata
from hotdata.models.update_dataset_request import UpdateDatasetRequest
from hotdata.models.update_dataset_response import UpdateDatasetResponse
from hotdata.rest import ApiException
from pprint import pprint
# Defining the host is optional and defaults to https://api.hotdata.dev
# See configuration.py for a list of all supported configuration parameters.
configuration = hotdata.Configuration(
host = "https://api.hotdata.dev"
)
# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.
# Configure API key authorization: WorkspaceId
configuration.api_key['WorkspaceId'] = os.environ["API_KEY"]
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['WorkspaceId'] = 'Bearer'
# Configure API key authorization: SessionId
configuration.api_key['SessionId'] = os.environ["API_KEY"]
# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['SessionId'] = 'Bearer'
# Configure Bearer authorization: BearerAuth
configuration = hotdata.Configuration(
access_token = os.environ["BEARER_TOKEN"]
)
# Enter a context with an instance of the API client
with hotdata.ApiClient(configuration) as api_client:
# Create an instance of the API class
api_instance = hotdata.DatasetsApi(api_client)
id = 'id_example' # str | Dataset ID
update_dataset_request = hotdata.UpdateDatasetRequest() # UpdateDatasetRequest |
try:
# Update dataset
api_response = api_instance.update_dataset(id, update_dataset_request)
print("The response of DatasetsApi->update_dataset:\n")
pprint(api_response)
except Exception as e:
print("Exception when calling DatasetsApi->update_dataset: %s\n" % e)| Name | Type | Description | Notes |
|---|---|---|---|
| id | str | Dataset ID | |
| update_dataset_request | UpdateDatasetRequest |
WorkspaceId, SessionId, BearerAuth
- Content-Type: application/json
- Accept: application/json
| Status code | Description | Response headers |
|---|---|---|
| 200 | Dataset updated | - |
| 404 | Dataset not found | - |
| 409 | Conflict | - |
[Back to top] [Back to API list] [Back to Model list] [Back to README]