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

# Get a segment by its public ID from an import

> Retrieves a single segment for a given import. The segment is identified by its globally unique public ID (UUID)



## OpenAPI

````yaml GET /imports/{importId}/segments/{segmentId}
openapi: 3.0.3
info:
  title: Taxonomy API
  version: v1
servers:
  - url: https://api.permutive.app/audience-api/v1
security: []
paths:
  /imports/{importId}/segments/{segmentId}:
    get:
      tags:
        - v1
      summary: Retrieves a single segment by its public ID for an import.
      description: >-
        Retrieves a single segment for a given import. The segment is identified
        by its globally unique public ID (UUID)
      operationId: getImportsImportidSegmentsSegmentid
      parameters:
        - name: importId
          in: path
          description: Import ID
          required: true
          schema:
            type: string
            format: uuid
          example: 32f8e031-c532-41bb-b25e-65bdb677a96f
        - name: segmentId
          in: path
          description: Segment ID
          required: true
          schema:
            type: string
            format: uuid
          example: 1b890475-1482-496d-bcfd-6b2f5564b249
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Segment'
              example:
                id: 1b890475-1482-496d-bcfd-6b2f5564b249
                code: '1234'
                name: Segment Name
                import_id: 9f87bd3e-32eb-4d15-8e85-17fb275fa809
                description: segment description
                cpm: 2
                categories:
                  - category_1
                updated_at: '2023-04-12T11:27:00.716632Z'
        '400':
          description: >-
            Invalid value for: path parameter importId, Invalid value for: path
            parameter segmentId
          content:
            text/plain:
              schema:
                type: string
        default:
          description: ''
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HttpErrorResponse'
components:
  schemas:
    Segment:
      required:
        - id
        - code
        - name
        - importId
        - updatedAt
      type: object
      properties:
        id:
          type: string
          format: uuid
        code:
          type: string
        name:
          type: string
        importId:
          type: string
          format: uuid
        description:
          type: string
        cpm:
          type: number
          format: double
        categories:
          type: array
          items:
            type: string
        updatedAt:
          type: string
          format: date-time
    HttpErrorResponse:
      required:
        - requestId
        - error
      type: object
      properties:
        requestId:
          type: string
          format: uuid
        error:
          $ref: '#/components/schemas/HttpError'
    HttpError:
      oneOf:
        - $ref: '#/components/schemas/AlreadyExists'
        - $ref: '#/components/schemas/AuthorizationFailed'
        - $ref: '#/components/schemas/AuthorizationFailedForAPIKey'
        - $ref: '#/components/schemas/AuthorizationFailedForUser'
        - $ref: '#/components/schemas/AuthorizationMissing'
        - $ref: '#/components/schemas/BadEncoding'
        - $ref: '#/components/schemas/BadOrigin'
        - $ref: '#/components/schemas/DoesNotExist'
        - $ref: '#/components/schemas/InsufficientAPIKey'
        - $ref: '#/components/schemas/InvalidAPIKey'
        - $ref: '#/components/schemas/InvalidHeader'
        - $ref: '#/components/schemas/InvalidParameters'
        - $ref: '#/components/schemas/InvalidRequestBody'
        - $ref: '#/components/schemas/MissingHeader'
        - $ref: '#/components/schemas/MissingOrigin'
        - $ref: '#/components/schemas/MissingParameters'
        - $ref: '#/components/schemas/MissingRequestBody'
        - $ref: '#/components/schemas/RouteDeprecated'
        - $ref: '#/components/schemas/SchemeNotSupported'
        - $ref: '#/components/schemas/UnknownError'
        - $ref: '#/components/schemas/UnspecifiedInternalError'
        - $ref: '#/components/schemas/ValidationError'
        - $ref: '#/components/schemas/VerbNotImplemented'
    AlreadyExists:
      type: object
      properties:
        c:
          type: string
        d:
          $ref: '#/components/schemas/JsonObject'
    AuthorizationFailed:
      type: object
      properties:
        c:
          type: string
        d:
          $ref: '#/components/schemas/JsonObject'
    AuthorizationFailedForAPIKey:
      type: object
      properties:
        c:
          type: string
        d:
          $ref: '#/components/schemas/JsonObject'
    AuthorizationFailedForUser:
      type: object
      properties:
        c:
          type: string
        d:
          $ref: '#/components/schemas/JsonObject'
    AuthorizationMissing:
      type: object
      properties:
        c:
          type: string
        d:
          $ref: '#/components/schemas/JsonObject'
    BadEncoding:
      type: object
      properties:
        c:
          type: string
        d:
          $ref: '#/components/schemas/JsonObject'
    BadOrigin:
      type: object
      properties:
        c:
          type: string
        d:
          $ref: '#/components/schemas/JsonObject'
    DoesNotExist:
      type: object
      properties:
        c:
          type: string
        d:
          $ref: '#/components/schemas/JsonObject'
    InsufficientAPIKey:
      type: object
      properties:
        c:
          type: string
        d:
          $ref: '#/components/schemas/JsonObject'
    InvalidAPIKey:
      type: object
      properties:
        c:
          type: string
        d:
          $ref: '#/components/schemas/JsonObject'
    InvalidHeader:
      type: object
      properties:
        c:
          type: string
        d:
          $ref: '#/components/schemas/JsonObject'
    InvalidParameters:
      type: object
      properties:
        c:
          type: string
        d:
          $ref: '#/components/schemas/JsonObject'
    InvalidRequestBody:
      type: object
      properties:
        c:
          type: string
        d:
          $ref: '#/components/schemas/JsonObject'
    MissingHeader:
      type: object
      properties:
        c:
          type: string
        d:
          $ref: '#/components/schemas/JsonObject'
    MissingOrigin:
      type: object
      properties:
        c:
          type: string
        d:
          $ref: '#/components/schemas/JsonObject'
    MissingParameters:
      type: object
      properties:
        c:
          type: string
        d:
          $ref: '#/components/schemas/JsonObject'
    MissingRequestBody:
      type: object
      properties:
        c:
          type: string
        d:
          $ref: '#/components/schemas/JsonObject'
    RouteDeprecated:
      type: object
      properties:
        c:
          type: string
        d:
          $ref: '#/components/schemas/JsonObject'
    SchemeNotSupported:
      type: object
      properties:
        c:
          type: string
        d:
          $ref: '#/components/schemas/JsonObject'
    UnknownError:
      required:
        - s
        - co
        - m
      type: object
      properties:
        s:
          $ref: '#/components/schemas/HttpStatus'
        co:
          type: integer
          format: int32
        m:
          type: string
        c:
          type: string
        d:
          $ref: '#/components/schemas/JsonObject'
    UnspecifiedInternalError:
      type: object
      properties:
        c:
          type: string
        d:
          $ref: '#/components/schemas/JsonObject'
    ValidationError:
      type: object
      properties:
        c:
          type: string
        d:
          $ref: '#/components/schemas/JsonObject'
    VerbNotImplemented:
      type: object
      properties:
        c:
          type: string
        d:
          $ref: '#/components/schemas/JsonObject'
    JsonObject:
      type: object
    HttpStatus:
      required:
        - code
      type: object
      properties:
        code:
          type: integer
          format: int32

````