NovoPayment Alias Directory API

The Alias Directory API enables a set of operations to store and manage users' information safely for sending funds between them. One of the main advantages of using NovoPayment's Alias Directory is that the information sent in each transaction is the alias; therefore, sensitive data such as a PAN is not exposed in each transaction.

Operations 14

POST /alias Create Alias #
POST /alias/find Find alias #
GET /alias/{aliasId} Get alias by aliasId #
PUT /alias/{aliasId} Update Alias #
DELETE /alias/{aliasId} Delete Alias by aliasId #
POST /alias/paymentinstruments Create Payment Instrument #
PUT /alias/paymentinstruments/primary Set Primary Payment Instrument #
PUT /alias/paymentinstruments/status Update Payment Instrument Status #
DELETE /alias/{aliasId}/paymentinstruments/{paymentInstrumentId} Delete Payment Instrument #
DELETE /alias/{aliasId}/favorites/{favoriteName} Delete Alias Favorite by AliasId and favoriteName #
GET /alias/{aliasId}/favorites Get Alias Favorites or Filter by Favorite Name #
POST /alias/favorites Create Alias Favorite #
POST /alias/account Create account #
DELETE /alias/{aliasId}/account/{accountId} Remove account #

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/alias-directory"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Discovery needs no key. Ratings and market analysis are Pro.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

novopayment-alias-directory-openapi.yml Raw ↑
openapi: 3.0.0
info:
  description: >
    The Alias Directory API enables a set of operations to store and
    manage users' information safely for sending funds between them.

    One of the main advantages of using NovoPayment's Alias Directory is that the information sent in each transaction is the alias; therefore, sensitive data such as a PAN  is not exposed in each transaction. 

    Clients can choose the alias type among phone number, email address, national ID, or even a customized unique alias in the system.


    One alias can have more than one payment instrument and each alias must have associated one primary payment instrument to receive the funds.

    Also, one alias can have some accounts associated.


    Below operations are available for Alias Directory API:


    Alias Administration:

    - Create Alias

    - Find alias

    - Get Alias Information (by AliasId)

    - Update Alias

    - Delete Alias (by aliasId)
  

    Payment Instruments:

    - Create Payment Instrument

    - Set Primary Payment Instrument

    - Update payment Instrument Status
  

    Favorite:

    - Create Alias Favorite

    - Get Alias Favorites or Filter by Favorite Name

    - Delete Alias Favorite by AliasId and favoriteName
   

    Accounts:

    - Create Account

    - Remove account


  version: v1
  title: Alias Directory API
  contact: 
    email: "support@novopaymen.com"
servers:
  - description: Sandbox
    url: https://sandbox-api.novopayment.com/aliasdirectory/v1

tags:
  - name: Alias Admin
    description: Alias Administrator
  - name: Payment Instruments
    description: Payment Instruments, cards management 
  - name: Favorites
    description: Favorites management 
  - name: Accounts
    description: account management 


paths:
  /alias:
    post:
      tags:
        - Alias Admin
      operationId: createAlias
      summary: Create Alias
      description: >
        Create an alias with an associated primary payment instrument to
        use it in funds transfers.
      requestBody:
        $ref: "#/components/requestBodies/CreateAliasInfoRequest"
      responses:
        "200":
          $ref: "#/components/responses/RSCreateAlias200"
        "400":
          $ref: "#/components/responses/RSCreateAlias400"
        "401":
          $ref: "#/components/responses/RS401"
        "500":
          $ref: "#/components/responses/RS500"
        default:
          $ref: "#/components/responses/RS500"
  /alias/find:
    post:

      tags:
        - Alias Admin
      operationId: findAlias
      summary: Find alias
      description: >
        Search if someone exists in an alias directory.
      requestBody:
        $ref: "#/components/requestBodies/FindAliasRequest"
      responses:
        "200":
          $ref: "#/components/responses/RSFindAlias200"
        "400":
          $ref: "#/components/responses/RSFindAlias400"
        "401":
          $ref: "#/components/responses/RS401"
        "500":
          $ref: "#/components/responses/RS500"
        default:
          $ref: "#/components/responses/RS500"
  "/alias/{aliasId}":
    get:
      tags:
        - Alias Admin
      summary: Get alias by aliasId
      description: >
        Obtains the information of the alias by a unique identifier called
        AliasID
      operationId: GetAliasByAliasId
      parameters:
        - $ref: "#/components/parameters/aliasId"
      responses:
        "200":
          $ref: "#/components/responses/RSGetAliasByAliasId200"
        "400":
          $ref: "#/components/responses/RSGetAliasByAliasId400"
        "401":
          $ref: "#/components/responses/RS401UpdateAlias"
        "500":
          $ref: "#/components/responses/RS500"
        default:
          $ref: "#/components/responses/RS500"
    put:
      tags:
        - Alias Admin
      summary: Update Alias
      description: >
        This operation updates information of the alias and cardholder in
        the directory.
      operationId: UpdateAlias
      parameters:
        - $ref: "#/components/parameters/aliasId"
      requestBody:
        $ref: "#/components/requestBodies/RQUpdateAlias"
      responses:
        "200":
          $ref: "#/components/responses/RSUpdateAlias200"
        "400":
          $ref: "#/components/responses/RSUpdateAlias400"
        "401":
          $ref: "#/components/responses/RS401UpdateAlias"
        "500":
          $ref: "#/components/responses/RS500"
        default:
          $ref: "#/components/responses/RS500"
    delete:
      tags:
        - Alias Admin
      summary: Delete Alias by aliasId
      description: |
        Delete an existing alias from the alias directory
      operationId: DeleteAliasByAliasId
      parameters:
        - $ref: "#/components/parameters/aliasId"
      responses:
        "200":
          $ref: "#/components/responses/RSDeleteAliasByAliasId200"
        "400":
          $ref: "#/components/responses/RSDeleteAliasByAliasId400"
        "401":
          description: Unauthorized
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/RS401"
              examples:
                Invalid Access Token:
                  $ref: "#/components/examples/InvalidAccessToken"
                Access Token Expired:
                  $ref: "#/components/examples/AccessTokenExpired"
        
        "500":
          $ref: "#/components/responses/RS500"
        default:
          $ref: "#/components/responses/RS500"          
   
       
  /alias/paymentinstruments:

    post:
      tags:
        - Payment Instruments
      operationId: createPayment
      summary: Create Payment Instrument
      description: >
        This operation creates a new payment instrument and associates it
        to an existing alias.
      requestBody:
        $ref: "#/components/requestBodies/CreatePaymentInstrumentRequest"
      responses:
        "200":
          $ref: "#/components/responses/RSAddPaymentInstrument200"
        "400":
          $ref: "#/components/responses/RSAddPaymentInstrument400"
        "401":
          $ref: "#/components/responses/RS401"
        "500":
          $ref: "#/components/responses/RS500"
        default:
          $ref: "#/components/responses/RS500"          
  /alias/paymentinstruments/primary:
    put:
      tags:
        - Payment Instruments
      summary: Set Primary Payment Instrument
      description: >
        This operation sets a primary payment instrument associated to an
        alias. An alias can only have one primary payment Instrument.


        Only a payment instrument in active status can be a primary payment instrument.
      operationId: SetPrimaryPaymentInstrument
      requestBody:
        $ref: "#/components/requestBodies/PaymentInstrumentPrimaryRequest"
      responses:
        "200":
          $ref: "#/components/responses/RSSetPrimaryPaymentInstrument200"
        "400":
          $ref: "#/components/responses/RSSetPrimaryPaymentInstrument400"
        "401":
          $ref: "#/components/responses/RS401"
        "500":
          $ref: "#/components/responses/RS500"
        default:
          $ref: "#/components/responses/RS500"          
  /alias/paymentinstruments/status:
    put:
      tags:
        - Payment Instruments
      summary: Update Payment Instrument Status
      description: |
        Update the payment instrument status.
      operationId: UpdatePaymentInstrumentStatus
      requestBody:
        $ref: "#/components/requestBodies/UpdateStatusPaymentInstrumentCoreRequest"
      responses:
        "200":
          $ref: "#/components/responses/RSUpdatePaymentInstrumentStatus200"
        "400":
          $ref: "#/components/responses/RSUpdatePaymentInstrumentStatus400"
        "401":
          $ref: "#/components/responses/RS401"
        "500":
          $ref: "#/components/responses/RS500"   
        default:
          $ref: "#/components/responses/RS500"          
  "/alias/{aliasId}/paymentinstruments/{paymentInstrumentId}":
    delete:
      tags:
        - Payment Instruments
      summary: Delete Payment Instrument
      description: >
        Disable the payment Instrument associated with an alias.

        __*A__ Primary Payment Instrument cannot be deleted, the user must set another payment instrument as primary before deletion.
      operationId: DeletePaymentInstrument
      parameters:
        - in: path
          name: aliasId   # Note the name is the same as in the path
          required: true
          schema:
            type: string
            maxLength: 32
            minLength: 32
            pattern: "^[0-9a-fA-F]{32}$"
          description: Identificator from Alias Parent.
          example: "c3c90deb537246ea8689ed6f5a9a3d23"
        - $ref: "#/components/parameters/paymentInstrumentId"
      responses:
        "200":
          $ref: "#/components/responses/RSDeletePaymentInstrument200"
        "400":
          $ref: "#/components/responses/RSDeletePaymentInstrument400"
        "401":
          $ref: "#/components/responses/RS401"
        "500":
          $ref: "#/components/responses/RS500"
        default:
          $ref: "#/components/responses/RS500"


  /alias/{aliasId}/favorites/{favoriteName}:
    delete:
      tags:
        - Favorites
      summary: Delete Alias Favorite by AliasId and favoriteName 
      description: >
              Delete Alias Favorite by AliasId and favoriteName 
      operationId: DeleteFavorite
      parameters:
        - in: path
          name: aliasId   # Note the name is the same as in the path
          required: true
          schema:
            type: string
            maxLength: 32
            minLength: 32
            pattern: "^[0-9a-fA-F]{32}$"
          description: Unique identifier of an Alias in NovoPayment.
          example: "c3c90deb537246ea8689ed6f5a9a3d23"
        - in: path
          name: favoriteName   # Note the name is the same as in the path
          required: true
          schema:
            type: string
            maxLength: 32
            minLength: 1
            pattern: "^\\w+$"
          description: Favorite Name, favorite to be deleted.
          example: "MOTHER"
      responses:
        "200":
          $ref: "#/components/responses/RSDeleteFavorite200"
        "400":
          $ref: "#/components/responses/RSDeleteFavorite400"
        "401":
          $ref: "#/components/responses/RS401"
        "500":
          $ref: "#/components/responses/RS500"
        default:
          $ref: "#/components/responses/RS500"

  /alias/{aliasId}/favorites:
    get:
      tags:
        - Favorites
      summary: Get Alias Favorites or Filter by Favorite Name
      description: >
              Obtain alias  and associated alias favorites  (or specific favorite)
      operationId: GetFavorite
      parameters:
        - in: path
          name: aliasId   # Note the name is the same as in the path
          required: true
          schema:
            type: string
            pattern: ^[A-Za-z0-9]{1,32}$
            maxLength: 32
            minLength: 32
          description: Unique identifier of an Alias in NovoPayment.
          example: c3c90deb537246ea8689ed6f5a9a3d23
          
        - in: query
          name: favoriteName   # Note the name is the same as in the path
          schema:
            type: string
            minLength: 0
            maxLength: 32
            pattern: ^[A-Za-z0-9]{1,50}$
          description: Favorite name , conditional if present filter by name
          example: MOTHER
          
      responses:
        "200":
          $ref: "#/components/responses/RSGetFavorite200"
        "400":
          $ref: "#/components/responses/RSGetFavorite400"
        "401":
          $ref: "#/components/responses/RS401"
        "500":
          $ref: "#/components/responses/RS500"     
        default:
          $ref: "#/components/responses/RS500"

  /alias/favorites:
    post:
      tags:
        - Favorites
      summary: Create Alias Favorite
      description: >
              Create Alias Favorite
      operationId: CreateFavorite
      requestBody:
        $ref: "#/components/requestBodies/CreateAliasFavoriteRequest"
      responses:
        "200":
          $ref: "#/components/responses/RSCreateFavorite200"
        "400":
          $ref: "#/components/responses/RSCreatetFavorite400"
        "401":
          $ref: "#/components/responses/RS401"
        "500":
          $ref: "#/components/responses/RS500"    
        default:
          $ref: "#/components/responses/RS500" 

  /alias/account:
    post:
      tags:
        - Accounts
      summary: Create account 
      description: >
              This operations creates a new account and associates it to an existing alias.
      operationId: createAccount   
      requestBody:
        $ref: "#/components/requestBodies/CreateAccountRequest"
      responses:
        "200":
          $ref: "#/components/responses/RSCreateAccount200"
        "400":
          $ref: "#/components/responses/RSCreateAccount400"
        "401":
          $ref: "#/components/responses/RS401"
        "500":
          $ref: "#/components/responses/RS500"    
        default:
          $ref: "#/components/responses/RS500"
  /alias/{aliasId}/account/{accountId}:
    delete:
      tags:
        - Accounts
      summary: Remove account 
      description: >
              Remove account associated with an alias
      operationId: removeAccount
      parameters:
        - in: path
          name: aliasId   # Note the name is the same as in the path
          required: true
          schema:
            type: string
            maxLength: 32
            minLength: 32
            pattern: "^[0-9a-fA-F]{32}$"
          description: Unique identifier of an Alias in NovoPayment. This data is for personal use, it is required for administration and management of your alias.
          example: "c3c90deb537246ea8689ed6f5a9a3d23"
        - $ref: "#/components/parameters/accountId"
      responses:
        "200":
          $ref: "#/components/responses/RSDeleteAccount200"
        "400":
          $ref: "#/components/responses/RSDeleteAccount400"
        "401":
          $ref: "#/components/responses/RS401"
        "500":
          $ref: "#/components/responses/RS500"    
        default:
          $ref: "#/components/responses/RS500"                        
security:
  - oAuth2ClientCredentials: []
components:
  securitySchemes:
    oAuth2ClientCredentials:
      type: oauth2
      description: >
        See [Oauth2
        API](https://developer.novopayment.com/api/authentication-method-and-encryption/oauth2-api)
      flows:
        clientCredentials:
          tokenUrl: https://sandbox-api.novopayment.com/oauth2/token
          scopes: {}
  examples:

    RQEndpointCreateAlias:
      value:
        alias: "519-990808"
        aliasType: "MOBILE"
        directoryCountry: "USA"
        cardHolder:
          firstName: "Andres"
          lastName: "Rendon"
          documentType:
            code: "GOVERNMENT_ID"
          documentNumber: "3146787"
          email: "adr@gmail.com"
          address:
            name: "Home"
            country: "USA"
            line1: "801 Metro Center Bl"
            line2: "Provisioning Boulevard"
            city: "Austin"
            state: "TX"
            postalCode: "78759"
        paymentInstrument:
          cardToken: Maz9oPb4PpW0QxPU0pAA6KYzE2vlEkNitMc+bmibFgo=
          cvvNumber: i5eMuNnaVHqIjz4PFHj23w==
          description: "InterBanco"
          brandType: "VISA"
          issuerName: "VISA_CARD"
          bankAccountNumber: "35426789"
          issuerCountryCode: "USA"

    RQEndpointCreateAliasAccount:
      value:
        alias: "519-990808"
        aliasType: "MOBILE"
        directoryCountry: "USA"
        cardHolder:
          firstName: "Andres"
          lastName: "Rendon"
          documentType:
            code: "GOVERNMENT_ID"
          documentNumber: "3146787"
          email: "adr@gmail.com"
          address:
            name: "Home"
            country: "USA"
            line1: "801 Metro Center Bl"
            line2: "Provisioning Boulevard"
            city: "Austin"
            state: "TX"
            postalCode: "78759"     
        accounts:
          - accountName: "Account Mom"
            accountType:
              title: "SAVING"
            accountNumberEncrypt: "VfogTyySFtvqCLb2L/zm7aT0P5M8GGYneWHGy5HQMVI="
            accountInternalId: "0458a69b-e70d-49b3-86d2-81d6b7569979"
            accountIdentify: "DEFAULT"
            countryCode: "USA"
            currencyCode: "USD"
    RQEndpointCreateAliasTotal:
      value:
        alias: "519-990808"
        aliasType: "MOBILE"
        directoryCountry: "USA"
        cardHolder:
          firstName: "Andres"
          lastName: "Rendon"
          documentType:
            code: "GOVERNMENT_ID"
          documentNumber: "3146787"
          email: "adr@gmail.com"
          address:
            name: "Home"            
            country: "USA"
            line1: "801 Metro Center Bl"
            line2: "Provisioning Boulevard"
            city: "Austin"
            state: "TX"
            postalCode: "78759" 
        paymentInstrument:
          cardToken: Maz9oPb4PpW0QxPU0pAA6KYzE2vlEkNitMc+bmibFgo=
          cvvNumber: i5eMuNnaVHqIjz4PFHj23w==
          description: "InterBanco"
          brandType: "VISA"
          issuerName: "VISA_CARD"
          bankAccountNumber: "35426789"
          issuerCountryCode: "USA"        
        accounts:
          - accountName: "Account Mom"
            accountType:
              title: "SAVING"
            accountNumberEncrypt: "VfogTyySFtvqCLb2L/zm7aT0P5M8GGYneWHGy5HQMVI="
            accountInternalId: "0458a69b-e70d-49b3-86d2-81d6b7569979"
            accountIdentify: "DEFAULT"
            countryCode: "USA"
            currencyCode: "USD"


    RQEndpointFindAlias:
      value:
        alias: 
          - "juan@gmail.com"
          - "3102582546"
        filter:   
          - field: "BRAND_TYPE"
            value: 
              - "VISA"

    RQEndpointCreatePaymentInstrument:
      value:
        aliasId: 5d1bf399902e42f79681c5be8dfdcb02
        paymentInstrument:
          cardToken: VPEEIIsMLff5b+uwX2rwexWuS+vAtSWm4ZjlYNKeK84=
          cvvNumber: i5eMuNnaVHqIjz4PFHj23w==
          description: Visa Card
          brandType: VISA
          issuerName: Interbank
          bankAccountNumber: "3542677745586"
          issuerCountryCode: USA
    RQEndpointSetPrimaryPaymentInstrumentAliasId:
      value:
        aliasId: 1ec407924bd24dc2863785b941fe6157
        paymentInstrumentId: 8d24929d0981421395fc02b9591474c4
    RQEndpointUpdatePaymentInstrumentStatus:
      value:
        alias: 519-990808
        aliasType: MOBILE
        paymentInstrumentId: 258aeef8fc7343a2a5b17c723c46185f
        paymentInstrumentStatus: ACTIVE
        detail: 
          method: "TOKENIZATION"
          metadata: 
           - field: "TOKEN"
             value: "TK**4565341354125"

    RQEndpointUpdateAlias:
      value:
        alias: "email@gmail.com"
        aliasType: "EMAIL"
        directoryCountry: "USA"
        cardHolder:
          firstName: "Juan"
          lastName: "Perez"
          documentType:
            code: "GOVERNANT_ID"
          documentNumber: "43526789"
          email: "juan@gmail.com"
          address:
            name: "Home"
            country: "USA"
            line1: "10808 Research"
            line2: "Provisioning Boulevard"
            city: "Austin"
            state: "TX"
            postalCode: "78759"

    
    RQEndpointCreateAliasFavoriteWhitAlias:
      value:
        aliasParent: 
          aliasId: "42f7d071fe0a41549bd68fe4d7ff1187"
        aliasFavorite:
          alias: "002-00005"
          aliasType: "MOBILE"
          favoriteName: "MOTHER"
    RQEndpointCreateAliasFavoriteWhitoutAlias:
      value:
        aliasParent: 
          aliasId: "42f7d071fe0a41549bd68fe4d7ff1187"
        aliasFavorite:
          favoriteName: "MOTHER"
          cardToken: "A4AhbfkEZft/EkcXNlXO8ww+N/EFG2DFarSkC4q1leI="
          cardHolder:
            address:
              name: "Home"
              country: "USA"
              city: "Bogota05"
              line1: "Cr9 45 -05"
              line2: "Boulevard05"
              postalCode: "20051"
              state: "CU0"
            documentNumber: "334675605"
            documentType:
              code: "GOVERNMENT_ID"
            email: "test05@gmail.com"
            firstName: "Adriana"
            lastName: "Santost"
    RQEndpointCreateAccount:
      value:
        aliasId: "5d1bf399902e42f79681c5be8dfdcb02"
        account:
          accountType: 
            title: "SAVING"
          accountNumberEncrypt: "bXgZyYJ5OmRjEuJq9BWSxwpxwBappGeW6N+PHky5UhM="
          accountInternalId: "0458a69b-e70d-49b3-86d2-81d6b7569979"
          countryCode: "USA"
          currencyCode: "USD"
          accountName: "John Doe" 
          accountIdentify : "DEFAULT"

    RQEndpointCreateAliasFavWhitoutAliasAccount:
      value:
        aliasParent: 
          aliasId: "42f7d071fe0a41549bd68fe4d7ff1187"
        aliasFavorite:
          favoriteName: "MOTHER"
          cardHolder:
            address:
              name: "Home"
              country: "USA"
              city: "Bogota05"
              line1: "Cr9 45 -05"
              line2: "Boulevard05"
              postalCode: "20051"
              state: "CU0"
            documentNumber: "334675605"
            documentType:
              code: "GOVERNMENT_ID"
            email: "test05@gmail.com"
            firstName: "Adriana"
            lastName: "Santost"
          account:
            accountName: "Account Mom"
            accountType:
              title: "SAVING"
            accountNumberEncrypt: "VfogTyySFtvqCLb2L/zm7aT0P5M8GGYneWHGy5HQMVI="
            accountIdentify: "DEFAULT"
            countryCode: "USA"
            currencyCode: "USD"

    HeaderParamsRequired:
      value:
        code: 400.09.001
        message: Header Params Required
        datetime: "2020-01-03T16:05:56.517Z"
    InvalidAlias:
      value:
        code: 400.09.102
        message: Invalid alias
        datetime: "2020-01-03T16:05:56.517Z"

    ComplianceList:
      value:
        code: 400.09.431
        message: User has hits in compliance lists 
        datetime: "2020-01-03T16:05:56.517Z"
    IssuerCountryNotSupported:
      value:
        code: 400.09.446
        message: Issuer country not supported  
        datetime: "2020-01-03T16:05:56.517Z"
    InvalidCardStatus:
      value:
        code: 400.09.362
        message: Invalid card status  
        datetime: "2020-01-03T16:05:56.517Z"
    CardIsInvalid:
      value:
        code: 400.09.427
        message: Card is invalid  
        datetime: "2020-01-03T16:05:56.517Z"
    CardHasTheSameStatus:
      value:
        code: 400.09.393
        message: The card has the status of the requested action.  
        datetime: "2020-01-03T16:05:56.517Z"
    CardIsNotActive:
      value:
        code: 400.09.367
        message: The card is not active   
        datetime: "2020-01-03T16:05:56.517Z"
    InvalidParameters:
      value:
        code: 400.09.396
        message: Invalid parameters.   
        datetime: "2020-01-03T16:05:56.517Z"
        data:
          errors:
            - message: "Field aliasType: invalid alias type"

    InvalidFindAliasParameters:
      value:
        code: 400.09.396
        message: Invalid parameters.   
        datetime: "2020-01-03T16:05:56.517Z"
        data:
          errors:
            - message: "Field alias: is required"
    InvalidTenantId:
      value:
        code: 400.09.004
        message: Invalid Tenant ID   
        datetime: "2020-01-03T16:05:56.517Z"
    InvalidEncryptedData:
      value:
        code: 400.09.320
        message: Invalid Encrypted Data   
        datetime: "2020-01-03T16:05:56.517Z"
    AliasAlreadyExist:
      value:
        code: 400.09.459
        message: Alias already exists  
        datetime: "2020-01-03T16:05:56.517Z"
    AliasNotFound:
      value:
        code: 400.09.448
        message: Alias not found   
        datetime: "2020-01-03T16:05:56.517Z"
    InvalidAccessToken:
      value:
        code: 401.09.990
        message: Invalid Access Token
        datetime: "2020-01-03T16:05:56.517Z"
    AccessTokenNotApproved:
      value:
        code: 401.09.991
        message: Access Token not approved
        datetime: "2020-01-03T16:05:56.517Z"
    InvalidSignature:
      value:
        code: 401.09.992
        message: Invalid signature
        datetime: "2020-01-03T16:05:56.517Z"
    AccessTokenExpired:
      value:
        code: 401.09.993
        message: Access token expired
        datetime: "2020-01-03T16:05:56.517Z"
    InternalServerError:
      value:
        code: 500.09.999
        message: Internal Server Error
        datetime: "2020-01-03T16:05:56.517Z"
    CardNotFound:
      value:
        code: 400.09.487
        message: Card not found
        datetime: "2020-01-03T16:05:56.517Z"
    DeletionPrimaryPaymentInstrumentIsNoAllowed:
      value:
        code: 400.09.539
        message: Deletion of the primary payment instrument is not allowed
        datetime: "2020-01-03T16:05:56.517Z"
    InvalidParametersDeletePI:
      value:
        code: 400.09.396
        message: Invalid parameters.   
        datetime: "2020-01-03T16:05:56.517Z"
        data:
          errors:
            - message: "paymentInstrumentId: must not be blank"
    InvalidParametersDeleteAlias:
      value:
        code: 400.09.396
        message: Invalid parameters.   
        datetime: "2020-01-03T16:05:56.517Z"
        data:
          errors:
            - message: "Field aliasId: invalid value"
    FavoriteNotFound:
      value:
        code: 404.09.498
        message: Favorite name not found
        datetime: "2020-01-03T16:05:56.517Z"
    Unregistered :
      value:
        code: 400.09.099
        message: Unregistered devices
        datetime: "2020-01-03T16:05:56.517Z"       
    TenantNotFound :
      value:
        code: 400.09.357
        message: Tenant not found.
        datetime: "2020-01-03T16:05:56.517Z"   
    FavoriteAlreadyExists:
      value:
        code: 404.09.495
        message: Favorite already exists
        datetime: "2020-01-03T16:05:56.517Z"       
    ExceedsMaximumNumberEmissions:
      value:
        code: 404.09.017
        message: Favorite already exists
        datetime: "2020-01-03T16:05:56.517Z"   
    AliasParentMustBeDifferentFromAliasFavorite:
      value:
        code: 404.09.497
        message: Alias parent must be different from alias favorite
        datetime: "2020-01-03T16:05:56.517Z" 
    AliasAccountExistFavorite:
      value:
        code: 404.09.015
        message: Account is already registered
        datetime: "2020-01-03T16:05:56.517Z" 


    UnableProcessRequest:
      value:
        code: 400.09.105
        message: Unable process request
        datetime: "2020-01-03T16:05:56.517Z" 

    UserAlreadyHasARegisteredAlias:
      value:
        code: 400.09.401
        message: User already has a registered alias  
        datetime: "2020-01-03T16:05:56.517Z"   
    InvalidIdentityDocumentType:
      value:
        code: 400.09.554
        message: Invalid identity document type  
        datetime: "2020-01-03T16:05:56.517Z"  
    CardNotAllowed:
      value:
        code: 400.09.101
        message: Card not allowed  
        datetime: "2020-01-03T16:05:56.517Z"
    AccountRegistered:
      value:
        code: 400.09.015
        message: Account is already registered
        datetime: "2020-01-03T16:05:56.517Z"
    AccountNotFound:
      value:
        code: 400.09.448
        message: The requested account does not belong to the customer. Please verify your information and try again.   
        datetime: "2020-01-03T16:05:56.517Z"
  parameters:
    aliasId:
      name: aliasId
      in: path
      description: |
        Unique identifier of an Alias in NovoPayment.
        This field is required if the alias is not sent.  This data is for personal use, it is required for administration and management of your alias.
      required: true
      example: "0300a633fcbf48a38d225afbd9fd43fa"
      schema:
        type: string
        maxLength: 32
        minLength: 32
        pattern: "^[0-9a-fA-F]{32}$"
    
    accountId:
      name: accountId
      in: path
      description: |
        Unique identifier for an account in NovoPayment.
      required: true
      schema:
        type: string
        maxLength: 32
        minLength: 32
        pattern: "^[0-9a-fA-F]{32}$"
      example: "8d24929d0981421395fc02b9591474c4"    
    paymentInstrumentId:
      name: paymentInstrumentId
      in: path
      description: |
        Payment instrument identificator.
      required: true
      schema:
        type: string
        maxLength: 32
        minLength: 32
        pattern: "^[0-9a-fA-F]{32}$"
      example: "8d24929d0981421395fc02b9591474c4"
  schemas:

    Accounts:
              type: array
              maxItems: 10
              xml:
                name: accounts
                wrapped: true
              items:
                $ref: '#/components/schemas/Account'
                
    AccountsInput:
      type: array
      maxItems: 2
      xml:
        name: accounts
        wrapped: true
      items:
        $ref: '#/components/schemas/Account'   
    
    Account:
      type: object
      description: Detailed account information, conditional if cards no present
      required:
        - accountType
        - accountNumberEncrypt
        - countryCode
        - currencyCode
        - accountIdentify
      additionalProperties: false
      properties:
        accountId:
          type: string
          description: >
           account identificator.
          example: 1297ceb1-cd42-4586-940d-6471d733d53e
          maxLength: 50
          pattern: ^(?!\s)(?!.*\s$).{1,50}$
        accountInternalId:
            type: string
            description: >
             account Internal UUID. (**this field should be unique**)
            example: 0458a69b-e70d-49b3-86d2-81d6b7569979
            maxLength: 36
            pattern: ^(?!\s)(?!.-*\s$).{1,50}$
        accountName:
          type: string
          description: >
           account Name.
          example: "AccountPrincipal"
          maxLength: 50
          pattern: ^(?!\s)(?!.*\s$).{1,50}$
        accountType:
          $ref: "#/components/schemas/AccountType"
        accountNumber:
          type: string
          description: >
           masked account number.
          example: "********1432"
          maxLength: 34
        accountNumberEncrypt:
          type: string
          description: >
           account number encrypted with aes256.
          example: "bXgZyYJ5OmRjEuJq9BWSxwpxwBappGeW6N+PHky5UhM="
          maxLength: 100
        accountIdentify:
          type: string
          description: >
            allow values DEFAULT, IBAN
          example: "IBAN"
          maxLength: 10
          pattern: (\s)*|DEFAULT|IBAN
        countryCode:
          type: string
          description: >
            Country code in ISO 3166 alpha-3 code or Country Code (numeric).
          example: USA
          minLength: 3
          maxLength: 3
          pattern: ^(?!\s)(?!.*\s$).{3,3}$
        currencyCode:
          type: string
          description: >
            Currency code  alpha-3 code or Numeric Code (numeric).
          example: USD
          minLength: 3
          maxLength: 3
          pattern: ^(?!\s)(?!.*\s$).{3,3}$
        bankCode:
          type: string
          example: "01" 
          maxLength: 70
          minLength: 1
          description: "bank's code"
        bankName:
          type: string
          example: "banco de bogota" 
          maxLength: 70
          minLength: 1
          description: "bank's name"
        

    CreateAliasInfoRequest:
      type: object
      required:
        - alias
        - aliasType
        - directoryCountry
        - cardHolder
      additionalProperties: false
      properties:
        alias:
          type: string
          description: >
            Attribute that identifies the alias associated to the cardholder.
            If it is a number, it must be in an international format with the
            1-3 digit country calling code.
          example: CUSTOM00051
          maxLength: 50
          pattern: ^(?!\s)(?!.*\s$).{1,50}$
        aliasType:
          type: string
          description: |
            __Allowed values:__
            __MOBILE,__
            __EMAIL,__
            __IDENTIFICATION,__
            __IBAN,__
            __CUSTOM__
          e

# --- truncated at 32 KB (121 KB total) ---
# Full source: https://raw.githubusercontent.com/api-evangelist/novopayment/refs/heads/main/openapi/novopayment-alias-directory-openapi.yml