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

# Get master data

> Return master/reference data required for card operations based on top level customer
(card types, categories, products, statuses, reasons, groups, regions, countries).


**Performance expectations:**<br />
**p50:** 950 ms, **p99:** 1300 ms.<br />
Measured on successful requests (2xx), server-side only.<br />
[How to interpret these metrics](/performance)


## OpenAPI

````yaml /openapi.yaml get /master/all
openapi: 3.1.0
info:
  title: Corpay APIs
  version: 1.0.0
  description: >
    Corpay APIs for customer profile management, card management, transaction
    history, and master data retrieval.
servers:
  - url: https://apigwuat.corpay.com
    description: Test environment
  - url: https://apigw.corpay.com
    description: Production environment
security:
  - oauth2ClientCredentials: []
tags:
  - name: Customer
    description: Customer profile and account lifecycle APIs
  - name: Card
    description: Card retrieval, ordering and lifecycle APIs
  - name: Geosearch
    description: >-
      Search and retrieve detailed information about charging locations and
      stations
  - name: Remote Charging
    description: >-
      Control charging sessions remotely including starting and stopping
      sessions, and monitoring session status
  - name: EV Session
    description: >-
      Access and manage charging session data including history, status, and
      detailed session information
  - name: Transaction
    description: Transaction history APIs
  - name: Master
    description: Master/reference data APIs
  - name: Webhooks
    description: Event callback payloads sent by Corpay
paths:
  /master/all:
    get:
      tags:
        - Master
      summary: Get master data
      description: >
        Return master/reference data required for card operations based on top
        level customer

        (card types, categories, products, statuses, reasons, groups, regions,
        countries).
      operationId: getMasterData
      responses:
        '200':
          description: Master data
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/MasterData'
              example:
                $ref: '#/components/schemas/MasterData/example'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '403':
          $ref: '#/components/responses/Forbidden'
        '404':
          $ref: '#/components/responses/NotFound'
        '500':
          $ref: '#/components/responses/InternalServerError'
components:
  schemas:
    MasterData:
      example:
        cardCategory:
          - id: 201
            name: Driver Card
        cardGroup:
          - cardTypeId: 1
            id: 3001
            name: Fleet Group A
        cardType:
          - defaultPurchaseCategoryId: 101
            description: Card used for EV charging
            id: 1
            isEV: false
            name: EV Card
        country:
          - countryCode: NLD
            id: 1
            name: Netherlands
        fuelProductRestrictions:
          - id: 1
            name: diesel
        product:
          - id: 1001
            name: Diesel Fuel
        purchaseCategory:
          - id: 101
            name: Fuel
            productRestrictionId: 1
        reason:
          - cardTypeId: 1
            description: Card Lost
            id: 1
        region:
          - id: 1
            name: Alemere
        status:
          - id: 1
            name: Active
      properties:
        cardCategory:
          items:
            properties:
              id:
                type: integer
              name:
                type: string
            type: object
          type: array
        cardGroup:
          items:
            properties:
              cardTypeId:
                type: integer
              id:
                type: integer
              name:
                type: string
            type: object
          type: array
        cardType:
          items:
            properties:
              defaultPurchaseCategoryId:
                type: integer
              description:
                type: string
              id:
                type: integer
              isEV:
                type: boolean
              name:
                type: string
            type: object
          type: array
        country:
          items:
            properties:
              countryCode:
                type: string
              id:
                type: integer
              name:
                type: string
            type: object
          type: array
        fuelProductRestriction:
          items:
            properties:
              id:
                type: integer
              name:
                type: string
            type: object
          type: array
        product:
          items:
            properties:
              code:
                type: string
              id:
                type: integer
              name:
                type: string
            type: object
          type: array
        purchaseCategory:
          items:
            properties:
              cardTypeId:
                type: integer
              id:
                type: integer
              name:
                type: string
              productRestrictionId:
                type: integer
            type: object
          type: array
        reason:
          items:
            properties:
              cardTypeId:
                type: integer
              description:
                type: string
              id:
                type: integer
            type: object
          type: array
        region:
          items:
            properties:
              id:
                type: integer
              name:
                type: string
            type: object
          type: array
        status:
          items:
            properties:
              id:
                type: integer
              name:
                type: string
            type: object
          type: array
      type: object
    Error:
      example:
        errorCode: ER-001
        errorDescription: Invalid request parameters
      properties:
        errorCode:
          type: string
        errorDescription:
          type: string
      required:
        - errorCode
        - errorDescription
      type: object
  responses:
    BadRequest:
      content:
        application/json:
          example:
            errorCode: ER-001
            errorDescription: Invalid request parameters
          schema:
            $ref: '#/components/schemas/Error'
      description: Bad request - validation error
    Unauthorized:
      description: Unauthorized - missing or invalid authentication token
    Forbidden:
      description: Forbidden - insufficient permissions
    NotFound:
      description: Not found - resource does not exist
    InternalServerError:
      content:
        application/json:
          example:
            errorCode: ER-012
            errorDescription: >-
              The server encountered an unexpected condition and could not
              complete the request. Please contact Corpay Support.
          schema:
            $ref: '#/components/schemas/Error'
      description: Internal server error
  securitySchemes:
    oauth2ClientCredentials:
      description: >
        Use OAuth2 client credentials to obtain a bearer token.


        Token endpoint:

        `POST <BASE_URL>/keycloak/realms/longship/protocol/openid-connect/token`


        Use the same base URL as the selected API server:

        - Test environment: `https://apigwuat.corpay.com`

        - Production environment: `https://apigw.corpay.com`


        Example:

        ```bash

        curl --location
        '<BASE_URL>/keycloak/realms/longship/protocol/openid-connect/token' \

        --header 'accept: application/json' \

        --data-urlencode 'grant_type=client_credentials' \

        --data-urlencode 'client_id=.......' \

        --data-urlencode 'client_secret=......'

        ```
      flows:
        clientCredentials:
          scopes: {}
          tokenUrl: /keycloak/realms/longship/protocol/openid-connect/token
      type: oauth2

````