---
updatedAt: 2025-03-06T23:35:27.000Z
agentTools:
  projectIndex: https://docs.tenyks.ai/llms.txt
---

# Upload Dataset Annotations

This endpoint uploads the annotations of a dataset.

# OpenAPI definition

```json
{
  "openapi": "3.0.0",
  "info": {
    "title": "API Endpoints",
    "version": "1.0.1"
  },
  "servers": [
    {
      "url": "https://{base_url}.tenyks.ai",
      "description": "The Tenyks API",
      "variables": {
        "base_url": {
          "enum": [
            "dashboard",
            "sandbox"
          ],
          "default": "dashboard"
        }
      }
    }
  ],
  "tags": [
    {
      "name": "Data Upload GCS"
    }
  ],
  "paths": {
    "/api/workspaces/tenyks/datasets/{dataset_key}/images/annotations": {
      "put": {
        "tags": [
          "Data Upload GCS"
        ],
        "summary": "Upload Dataset Annotations",
        "description": "This endpoint uploads the annotations of a dataset.",
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/DatasetAnnotationsPayloadGCS"
              }
            }
          }
        },
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "parameters": [
          {
            "name": "dataset_key",
            "in": "path",
            "schema": {
              "type": "string"
            },
            "required": true,
            "description": "The unique key assigned to your dataset when it was created.",
            "example": "face_detection"
          }
        ],
        "responses": {
          "200": {
            "description": "Successful response",
            "content": {
              "application/json": {}
            }
          }
        }
      }
    }
  },
  "components": {
    "schemas": {
      "DatasetAnnotationsPayloadGCS": {
        "type": "object",
        "properties": {
          "type": {
            "type": "string",
            "enum": [
              "gcs"
            ],
            "default": "gcs"
          },
          "gcs_uri": {
            "type": "string",
            "example": "gs://tenyks_datasets_bucket/kitti/annotations.json"
          },
          "credentials": {
            "$ref": "#/components/schemas/GCSCredentials"
          }
        },
        "required": [
          "type",
          "gcs_uri",
          "credentials"
        ]
      },
      "GCSCredentials": {
        "type": "object",
        "properties": {
          "type": {
            "type": "string"
          },
          "project_id": {
            "type": "string"
          },
          "private_key_id": {
            "type": "string"
          },
          "private_key": {
            "type": "string"
          },
          "client_email": {
            "type": "string"
          },
          "client_id": {
            "type": "string"
          },
          "auth_uri": {
            "type": "string"
          },
          "token_uri": {
            "type": "string"
          },
          "auth_provider_x509_cert_url": {
            "type": "string"
          },
          "client_x509_cert_url": {
            "type": "string"
          },
          "universe_domain": {
            "type": "string"
          }
        }
      }
    },
    "securitySchemes": {
      "bearerAuth": {
        "type": "http",
        "scheme": "bearer"
      }
    }
  },
  "x-readme": {
    "explorer-enabled": true,
    "proxy-enabled": true,
    "samples-enabled": true
  }
}
```