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

# Get countries

> Returns the list of countries where Hub2 is available



## OpenAPI

````yaml get /data/countries
openapi: 3.0.0
info:
  title: Hub2 Service · Api
  description: |-
    This is the Hub2 api reference |
          Please check https://docs.hub2.io/ for the full documentation |
          Rate limits of endpoints are here : https://docs.hub2.io/en/details/limits.html.
  version: 2.149.1
  contact:
    name: Hub2
    url: https://www.hub2.io/
    email: contact@hub2.io
servers: []
security: []
tags:
  - name: Payments
    description: >-
      Best known as the PAY-IN API, it provides endpoints for merchants to
      perform Hub2 PAY-IN transactions.
  - name: Transfers
    description: >-
      Best known as the PAY-OUT API, it provides endpoints for merchants to
      perform Hub2 PAY-OUT transactions.
  - name: IRT
    description: International Remittance Transfers
  - name: Balance
    description: ''
  - name: Webhooks
    description: ''
  - name: Provisioning
    description: ''
  - name: Payment on Terminal
    description: ''
  - name: Receipt
    description: ''
  - name: Sms
    description: ''
  - name: Data
    description: ''
  - name: Compliance
    description: ''
  - name: Recipient
    description: ''
  - name: Delegation
    description: ''
  - name: Deposits
    description: ''
  - name: Payment Links
    description: ''
  - name: Submerchants
    description: ''
paths:
  /data/countries:
    get:
      tags:
        - Data
      summary: Get countries
      description: Returns the list of countries where Hub2 is available
      operationId: PublicDataController_getCountries
      parameters:
        - name: method
          required: false
          in: query
          description: The payment method type
          schema:
            example: mobile_money
            enum:
              - mobile_money
              - credit_card
              - bank_transfer
            type: string
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                type: array
                items:
                  $ref: '#/components/schemas/CountryDto'
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ApiBadRequestErrorAlias'
        '500':
          description: Internal error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ApiInternalErrorAlias'
components:
  schemas:
    CountryDto:
      type: object
      properties:
        id:
          type: string
          description: Id of the country
          example: co_9emDKLlFsYRNWOPiG4pnK
        code:
          type: string
          description: The code of the country. Follows the ISO 3166-1 alpha-2
          example: SN
        name:
          type: string
          description: Name of the country
          example: Sénégal
      required:
        - id
        - code
        - name
    ApiBadRequestErrorAlias:
      type: object
      properties:
        status:
          type: number
          description: HTTP error code.
          example: 400
        error:
          description: HTTP error description.
          allOf:
            - $ref: '#/components/schemas/InternalApiBadRequestError'
      required:
        - status
        - error
    ApiInternalErrorAlias:
      type: object
      properties:
        type:
          type: string
          description: The type of this error.
          example: internal_error
        code:
          type: string
          description: The error code for this error.
          example:
            - internal_error
            - wrong_credentials
            - not_granted
            - live_mode_not_granted
            - invalid_sandbox_msisdn
            - invalid_url
            - orange_invalid_url
            - wrong_provider
            - override_business_name
            - do_not_override_business_name
        message:
          type: string
          description: The error message describing what happens to throw this error.
          example: An error occurred on our system. Please try again later.
      required:
        - type
        - code
        - message
    InternalApiBadRequestError:
      type: object
      properties:
        statusCode:
          type: number
          description: HTTP error code.
          example: 400
        message:
          description: >-
            Detailed error message or array of messages to describe what's
            wrong.
          example:
            - destination.provider must be a string
          type: array
          items:
            type: string
        error:
          type: string
          description: The error message
          example: Bad Request
      required:
        - statusCode
        - message
        - error

````