---
title: "Get personal access token policy settings"
url: "https://nov18-dev.movespot.fyi/apis/konnect-organizations-3/versions/0fabbb32-5b59-4682-8ca3-0695a9f4759c/operations/get-organizations-personal-access-token-settings"
---

> Full API specification: https://nov18-dev.movespot.fyi/apis/konnect-organizations-3/versions/0fabbb32-5b59-4682-8ca3-0695a9f4759c.md

# Get personal access token policy settings

`GET` `/organizations/{organizationId}/personal-access-token-settings`

Operation ID: `get-organizations-personal-access-token-settings`

Get personal access token policy settings. Only organization administrators are authorized to perform this action.

## Path parameters

- `organizationId` (string, uuid, required) - UUID representing an organization.

## Responses

- `200` - Response containing personal access token settings.
- `401` - Unauthorized
- `403` - Forbidden

## OpenAPI definition

```yaml
openapi: 3.0.3
info:
  title: Konnect Organizations
  version: 3.0.0
servers:
  - url: https://global.api.konghq.com/v3
    description: Global Base URL
paths:
  /organizations/{organizationId}/personal-access-token-settings:
    parameters:
      - $ref: "#/components/parameters/OrganizationIdParameter"
    get:
      operationId: get-organizations-personal-access-token-settings
      summary: Get personal access token policy settings
      description: Get personal access token policy settings. Only organization
        administrators are authorized  to perform this action.
      responses:
        "200":
          $ref: "#/components/responses/PersonalAccessTokenSettingsResponse"
        "401":
          $ref: "#/components/responses/Unauthorized"
        "403":
          $ref: "#/components/responses/Forbidden"
      security:
        - personalAccessToken: []
        - konnectAccessToken: []
        - serviceAccessToken: []
      tags:
        - Personal Access Tokens
security:
  - personalAccessToken: []
  - konnectAccessToken: []
  - serviceAccessToken: []
components:
  parameters:
    OrganizationIdParameter:
      name: organizationId
      in: path
      description: UUID representing an organization.
      required: true
      schema:
        $ref: "#/components/schemas/OrganizationId"
  responses:
    PersonalAccessTokenSettingsResponse:
      description: Response containing personal access token settings.
      content:
        application/json:
          schema:
            type: object
            properties:
              pats_enabled:
                type: boolean
                default: true
              max_expiration_period_days:
                $ref: "#/components/schemas/MaxPATExpirationPeriodDays"
            additionalProperties: false
            required:
              - pats_enabled
              - max_expiration_period_days
          examples:
            Personal Access Token Settings Response:
              $ref: "#/components/examples/PersonalAccessTokenSettingsResponse"
    Unauthorized:
      description: Unauthorized
      content:
        application/problem+json:
          schema:
            $ref: "#/components/schemas/UnauthorizedError"
          examples:
            UnauthorizedExample:
              $ref: "#/components/examples/UnauthorizedExample"
    Forbidden:
      description: Forbidden
      content:
        application/problem+json:
          schema:
            $ref: "#/components/schemas/ForbiddenError"
          examples:
            UnauthorizedExample:
              $ref: "#/components/examples/ForbiddenExample"
  schemas:
    OrganizationId:
      description: UUID representing an organization.
      type: string
      format: uuid
      example: 5f9fd312-a987-4628-b4c5-bb4f4fddd5f7
      readOnly: true
    MaxPATExpirationPeriodDays:
      type: integer
      maximum: 365
      minimum: 1
    UnauthorizedError:
      allOf:
        - $ref: "#/components/schemas/BaseError"
        - type: object
          properties:
            status:
              example: 401
            title:
              example: Unauthorized
            type:
              example: https://httpstatuses.com/401
            instance:
              example: kong:trace:1234567890
            detail:
              example: Invalid credentials
    ForbiddenError:
      allOf:
        - $ref: "#/components/schemas/BaseError"
        - type: object
          properties:
            status:
              example: 403
            title:
              example: Forbidden
            type:
              example: https://httpstatuses.com/403
            instance:
              example: kong:trace:1234567890
            detail:
              example: Forbidden
    BaseError:
      description: standard error
      type: object
      properties:
        status:
          description: >
            The HTTP status code of the error. Useful when passing the response

            body to child properties in a frontend UI. Must be returned as an
            integer.
          type: integer
          readOnly: true
        title:
          description: |
            A short, human-readable summary of the problem. It should not
            change between occurences of a problem, except for localization.
            Should be provided as "Sentence case" for direct use in the UI.
          type: string
          readOnly: true
        type:
          description: The error type.
          type: string
          readOnly: true
        instance:
          description: |
            Used to return the correlation ID back to the user, in the format
            kong:trace:<correlation_id>. This helps us find the relevant logs
            when a customer reports an issue.
          type: string
          readOnly: true
        detail:
          description: >
            A human readable explanation specific to this occurence of the
            problem.

            This field may contain request/entity data to help the user
            understand

            what went wrong. Enclose variable values in square brackets. Should
            be

            provided as "Sentence case" for direct use in the UI.
          type: string
          readOnly: true
      required:
        - status
        - title
        - instance
        - detail
      title: Error
  examples:
    PersonalAccessTokenSettingsResponse:
      value:
        pats_enabled: true
        max_expiration_period_days: 365
    UnauthorizedExample:
      value:
        status: 401
        title: Unauthorized
        instance: kong:trace:8347343766220159418
        detail: Unauthorized
    ForbiddenExample:
      value:
        status: 403
        title: Forbidden
        instance: kong:trace:2723154947768991354
        detail: You do not have permission to perform this action
  securitySchemes:
    personalAccessToken:
      type: http
      scheme: bearer
      bearerFormat: Token
      description: >
        The personal access token is meant to be used as an alternative to
        basic-auth when accessing Konnect via APIs.

        You can generate a Personal Access Token (PAT) from the [personal access
        token page](https://cloud.konghq.com/global/account/tokens/) in the
        Konnect dashboard.

        The PAT token must be passed in the header of a request, for example:

        `curl -X GET 'https://global.api.konghq.com/v2/users/' --header
        'Authorization: Bearer kpat_xgfT...'`
    konnectAccessToken:
      type: http
      scheme: bearer
      bearerFormat: JWT
      description: >
        The Konnect access token is meant to be used by the Konnect dashboard
        and the decK CLI authenticate with.
    serviceAccessToken:
      type: http
      scheme: bearer
      bearerFormat: JWT
      description: |
        The Service access token is meant to be used between internal services.
```
