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

# Get tag associations

> Get a list of tag-roles associations from DataHub. Each tag has a list of roles associated with it.



## OpenAPI

````yaml get /api/metastore/tags/associations
openapi: 3.1.0
info:
  title: Nx1 AI API
  description: |

    AI API for Nx1 Data Platform Management and Automated Data Tasks.

    Authentication is required via PSK in Authorization header.

    Default PSK is | [ask a friend] |
  version: 0.10.2
servers: []
security: []
paths:
  /api/metastore/tags/associations:
    get:
      tags:
        - Metastore
      summary: Get tag associations
      description: >-
        Get a list of tag-roles associations from DataHub. Each tag has a list
        of roles associated with it.
      operationId: get_tag_associations_api_metastore_tags_associations_get
      responses:
        '200':
          description: Data retrieved successfully.
          content:
            application/json:
              schema:
                items:
                  $ref: '#/components/schemas/TagsAssociation'
                type: array
                title: >-
                  Response Get Tag Associations Api Metastore Tags Associations
                  Get
        '400':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
          description: Bad Request
      security:
        - OAuth2AuthorizationCodeBearer: []
        - APIKeyHeader: []
components:
  schemas:
    TagsAssociation:
      properties:
        tag:
          type: string
          title: Tag
          description: Tag name linked to roles.
        roles:
          items:
            anyOf:
              - additionalProperties:
                  type: boolean
                type: object
              - type: 'null'
          type: array
          title: Roles
          description: List of roles associated with the tag.
      type: object
      required:
        - tag
        - roles
      title: TagsAssociation
    ErrorResponse:
      properties:
        error:
          type: string
          title: Error
          description: A brief description of the error that occurred.
        code:
          type: integer
          title: Code
          description: The HTTP status code associated with the error.
          default: 500
      type: object
      required:
        - error
      title: ErrorResponse
  securitySchemes:
    OAuth2AuthorizationCodeBearer:
      type: oauth2
      flows:
        authorizationCode:
          scopes: {}
          authorizationUrl: >-
            https://sso-rapid.rapid.nx1cloud.com/realms/rapid/protocol/openid-connect/auth
          tokenUrl: >-
            https://sso-rapid.rapid.nx1cloud.com/realms/rapid/protocol/openid-connect/token
    APIKeyHeader:
      type: apiKey
      in: header
      name: Authorization-PSK

````