datasets

POST /documents/v1/datasets/{dataset_name}

Request

Path parameters

dataset_namestring required

Request body multipart/form-data

filestring binary nullable

The file to ingest into the dataset.

This field must be provided if the file_id is not provided.

The file should be a binary file, and it will be uploaded to the server.

file_idstring nullable

The Tensorlake file ID to ingest into the dataset.

This field must be provided if the file is not provided.

The file ID should be a valid Tensorlake file ID. A valid file ID is a string that starts with tensorlake- (if uploaded via Files V1), or file_ (if uploaded via Files V2); followed by a readable identifier.

pagesstring nullable

The page range to ingest into the dataset.

This field is optional and defaults to None, which means all pages will be ingested. If provided, it should be a string in the format "start-end", where start and end are page numbers. For example, "1-10" will ingest pages 1 to 10.

labelsobject nullable

The labels to apply to the ingest operation of the file.

Labels should be in the format of key=value pairs, e.g. key1=value1; or as a JSON object.

For adding multiple labels, use different form-data fields with the same key.

Example: POST /documents/v1/files Content-Type: multipart/form-data; boundary=----boundary

------boundary Content-Disposition: form-data; name="labels" owner=JohnDoe

------boundary Content-Disposition: form-data; name="labels" project=Tensorlake

Labels can also be provided as a JSON object: ------boundary Content-Disposition: form-data; name="labels" {"owner": "JohnDoe", "project": "Tensorlake"}

Labels are optional and can be used to store additional information about the file.

Response

Extend a dataset

jobIdstring required
fileIdstring required
statusstring required

Changes

No recorded changes to this operation across all 2 revisions of this API.