---
title: "POST /model-hub/prompt-labels/{template_id}/{label_id}/assign-label-by-id/"
method: POST
path: "/model-hub/prompt-labels/{template_id}/{label_id}/assign-label-by-id/"
tags: ["model-hub"]
---

# POST /model-hub/prompt-labels/{template_id}/{label_id}/assign-label-by-id/

`POST /model-hub/prompt-labels/{template_id}/{label_id}/assign-label-by-id/`

## Request

- Base URL: `http://localhost:8000`
- URL: `http://localhost:8000/model-hub/prompt-labels/{template_id}/{label_id}/assign-label-by-id/`
- Auth: one of:
  - API key in header `X-Api-Key`
  - API key in header `X-Secret-Key`

Assign a label to a specific version by template name and version name.

## Request body

- PromptLabel
  - `id` string, uuid
  - `organization` string, uuid
  - `name` string, required
  - `type` 'system' | 'custom', required
  - `metadata` object, nullable
  - `created_at` string, date-time
  - `updated_at` string, date-time

## Response `201`

Created

- PromptLabel
  - `id` string, uuid
  - `organization` string, uuid
  - `name` string, required
  - `type` 'system' | 'custom', required
  - `metadata` object, nullable
  - `created_at` string, date-time
  - `updated_at` string, date-time

## Other responses

- `400`: Bad Request
- `403`: Forbidden
- `404`: Not Found
- `409`: Conflict
- `500`: Internal Server Error
- `default`: Default error response

---

[API](https://skmtc.dev/futureagi/apis/future-agi-management-api.md) · [All operations](https://skmtc.dev/futureagi/apis/future-agi-management-api/llms.txt) · [OpenAPI document](https://skmtc.dev/futureagi/apis/future-agi-management-api/revisions/c8684118e142?raw)
