> ## Documentation Index
> Fetch the complete documentation index at: https://docs.open-metadata.org/llms.txt
> Use this file to discover all available pages before exploring further.

# Create a Glossary Term

> Create a new glossary term within a glossary

# Create a Glossary Term

Create a new glossary term within a glossary.

## Body Parameters

<ParamField body="name" type="string" required>
  Name of the glossary term. Must be unique within the parent glossary or parent term.
</ParamField>

<ParamField body="glossary" type="string" required>
  Fully qualified name of the parent glossary (e.g., `BusinessGlossary`).
</ParamField>

<ParamField body="displayName" type="string">
  Human-readable display name for the glossary term.
</ParamField>

<ParamField body="description" type="string">
  Description of the glossary term in Markdown format.
</ParamField>

<ParamField body="parent" type="string">
  Fully qualified name of the parent glossary term for creating nested terms (e.g., `BusinessGlossary.Revenue`).
</ParamField>

<ParamField body="synonyms" type="array">
  Array of synonym strings for this term.
</ParamField>

<ParamField body="relatedTerms" type="array">
  Array of fully qualified names of related glossary terms.
</ParamField>

<ParamField body="owners" type="array">
  Array of owner references (users or teams) to assign to the glossary term.

  <Expandable title="properties">
    <ParamField body="id" type="string">
      UUID of the owner entity.
    </ParamField>

    <ParamField body="type" type="string">
      Type of owner entity (e.g., `user`, `team`).
    </ParamField>

    <ParamField body="name" type="string">
      Name of the owner entity.
    </ParamField>
  </Expandable>
</ParamField>

<ParamField body="tags" type="array">
  Array of classification tags to apply.

  <Expandable title="properties">
    <ParamField body="tagFQN" type="string" required>
      Fully qualified name of the tag.
    </ParamField>

    <ParamField body="labelType" type="string">
      Type of label (e.g., `Manual`, `Derived`, `Propagated`).
    </ParamField>

    <ParamField body="state" type="string">
      State of the tag (e.g., `Suggested`, `Confirmed`).
    </ParamField>
  </Expandable>
</ParamField>

<ParamField body="domain" type="string">
  Fully qualified name of the domain to assign for governance purposes.
</ParamField>

<ParamField body="style" type="object">
  Visual styling for the glossary term.

  <Expandable title="properties">
    <ParamField body="color" type="string">
      Hex color code (e.g., `#FF5733`).
    </ParamField>

    <ParamField body="iconURL" type="string">
      URL to a custom icon for the term.
    </ParamField>
  </Expandable>
</ParamField>

<RequestExample dropdown>
  ```python POST /v1/glossaryTerms theme={null}
  from metadata.sdk import configure
  from metadata.sdk.entities import GlossaryTerms
  from metadata.generated.schema.api.data.createGlossaryTerm import CreateGlossaryTermRequest

  configure(
      host="https://your-company.open-metadata.org/api",
      jwt_token="your-jwt-token"
  )

  request = CreateGlossaryTermRequest(
      name="Revenue",
      glossary="BusinessGlossary",
      displayName="Revenue",
      description="Total income generated from business operations",
      synonyms=["Income", "Earnings", "Sales"]
  )

  term = GlossaryTerms.create(request)
  print(f"Created: {term.fullyQualifiedName}")
  ```

  ```java POST /v1/glossaryTerms theme={null}
  import static org.openmetadata.sdk.fluent.GlossaryTerms.*;

  // Create using builder pattern
  var term = GlossaryTerms.builder()
      .name("Revenue")
      .glossary("BusinessGlossary")
      .displayName("Revenue")
      .description("Total income generated from business operations")
      .synonyms(List.of("Income", "Earnings", "Sales"))
      .create();
  ```

  ```bash POST /v1/glossaryTerms theme={null}
  curl -X POST "{base_url}/api/v1/glossaryTerms" \
    -H "Authorization: Bearer {access_token}" \
    -H "Content-Type: application/json" \
    -d '{
      "name": "Revenue",
      "glossary": "BusinessGlossary",
      "description": "Total income generated from business operations",
      "synonyms": ["Income", "Earnings", "Sales"],
      "owners": []
    }'
  ```
</RequestExample>

<ResponseExample>
  ```json Response theme={null}
  {
    "id": "d3a50b09-g258-7h57-defg-42g1d5517ed4",
    "name": "Revenue",
    "fullyQualifiedName": "BusinessGlossary.Revenue",
    "displayName": "Revenue",
    "description": "Total income generated from business operations",
    "synonyms": ["Income", "Earnings", "Sales"],
    "glossary": {
      "id": "c2940a98-f147-6g46-cdef-31f0c4406dc3",
      "type": "glossary",
      "name": "BusinessGlossary",
      "fullyQualifiedName": "BusinessGlossary",
      "deleted": false
    },
    "version": 0.1,
    "updatedAt": 1769984330261,
    "updatedBy": "admin",
    "href": "http://localhost:8585/api/v1/glossaryTerms/d3a50b09-g258-7h57-defg-42g1d5517ed4",
    "deleted": false,
    "owners": [],
    "tags": [],
    "children": [],
    "relatedTerms": []
  }
  ```
</ResponseExample>

***

## Returns

Returns the created glossary term object with all specified properties and system-generated fields.

## Response

<ResponseField name="id" type="string">
  Unique identifier for the glossary term (UUID format).
</ResponseField>

<ResponseField name="name" type="string">
  Glossary term name.
</ResponseField>

<ResponseField name="fullyQualifiedName" type="string">
  Fully qualified name in format `glossary.termName` or `glossary.parent.child`.
</ResponseField>

<ResponseField name="displayName" type="string">
  Human-readable display name.
</ResponseField>

<ResponseField name="description" type="string">
  Description of the glossary term in Markdown format.
</ResponseField>

<ResponseField name="synonyms" type="array">
  List of synonym strings for this term.
</ResponseField>

<ResponseField name="glossary" type="object">
  Reference to the parent glossary.

  <Expandable title="properties">
    <ResponseField name="id" type="string">
      UUID of the glossary.
    </ResponseField>

    <ResponseField name="type" type="string">
      Type of entity (always `glossary`).
    </ResponseField>

    <ResponseField name="name" type="string">
      Name of the glossary.
    </ResponseField>

    <ResponseField name="fullyQualifiedName" type="string">
      Fully qualified name of the glossary.
    </ResponseField>
  </Expandable>
</ResponseField>

<ResponseField name="children" type="array" optional>
  Child glossary term references.
</ResponseField>

<ResponseField name="relatedTerms" type="array" optional>
  Related glossary term references.
</ResponseField>

<ResponseField name="owners" type="array" optional>
  List of owners assigned to the glossary term.
</ResponseField>

<ResponseField name="tags" type="array" optional>
  Classification tags applied to the glossary term.
</ResponseField>

<ResponseField name="style" type="object" optional>
  Visual styling for the term.
</ResponseField>

<ResponseField name="version" type="number">
  Version number for the entity (starts at 0.1).
</ResponseField>

***

## Create or Update (PUT)

Use `PUT /v1/glossaryTerms` instead of `POST` to perform an upsert. If a glossary term with the same `fullyQualifiedName` already exists, it will be updated; otherwise, a new glossary term is created. The request body is the same as `POST`.

```bash theme={null}
curl -X PUT "{base_url}/api/v1/glossaryTerms" \
  -H "Authorization: Bearer {access_token}" \
  -H "Content-Type: application/json" \
  -d '{ ... same body as POST ... }'
```

<Note>
  `PUT` will not return a `409` conflict error if the entity already exists -- it will update the existing entity instead.
</Note>

***

## Error Handling

| Code  | Error Type              | Description                                                         |
| ----- | ----------------------- | ------------------------------------------------------------------- |
| `400` | `BAD_REQUEST`           | Invalid request body or missing required fields                     |
| `401` | `UNAUTHORIZED`          | Invalid or missing authentication token                             |
| `403` | `FORBIDDEN`             | User lacks permission to create glossary terms                      |
| `409` | `ENTITY_ALREADY_EXISTS` | Glossary term with same name already exists in glossary (POST only) |
