# Create a new label

> You're reading the Mindset v3 documentation. v3 is no longer sold; this is reference for existing customers. Mindset 4 docs are at /docs.

Mindset v3 REST API reference: Labels.

**POST** `/api/v1/appuid/{appUid}/labels`

## Base URL

Requests go to your region's API host, for example `https://a.api.mindset.ai`. Hosts: `https://a.api.mindset.ai`, `https://b.api.mindset.ai`, `https://c.api.mindset.ai`, `https://d.api.mindset.ai`.

## Authorization

- `x-api-key` (string, required, header)

  Your API key.

## Path parameters

- `appUid` (string, required, path)

  Your application's uid

## Request body

Content type: `application/json`.

- `name` (string, required, body)

  Name of the label

* `externalId` (string, body)

  Optional External ID of the label

- `showInDiscovery` (boolean, body)

  Is this label visible to end users?

```json
{
  "name": "string",
  "externalId": "string",
  "showInDiscovery": true
}
```

## Responses

### 201

Label created successfully

```json
{
  "uid": "string",
  "name": "string",
  "externalId": "string",
  "showInDiscovery": true,
  "createdAt": "string"
}
```

### 400

Bad Request

### 401

Unauthorized

### 403

Forbidden

### 422

Unprocessable Entity

### 500

Internal Server Error

## Example request

```bash
curl -X POST "https://a.api.mindset.ai/api/v1/appuid/{appUid}/labels" \
  -H "x-api-key: <your-api-key>" \
  -H "Content-Type: application/json" \
  -d '{"name":"string","externalId":"string","showInDiscovery":true}'
```
