Payment Methods Guide


Introduction

This guide describes the internal payment method codes in B2Brouter and their corresponding encoding in UBL, Facturae, and FatturaPA.

Equivalencies:

  • B2Brouter internal field: payment_method
  • Facturae field: PaymentMeans (element at /facturae:Facturae/Invoices/Invoice/PaymentDetails/Installment/PaymentMeans
  • UBL field: cbc:PaymentMeansCode (element at /Invoice/cac:PaymentMeans/cbc:PaymentMeansCode)
  • FatturaPA field: ModalitaPagamento (element at /p:FatturaElettronica/FatturaElettronicaBody/DatiPagamento/DettaglioPagamento/ModalitaPagamento
  • CII field: TypeCode (element at rsm:SupplyChainTradeTransaction/ram:ApplicableHeaderTradeSettlement/ram:SpecifiedTradeSettlementPaymentMeans/ram:TypeCode)
  • Business Terms ID: BT-81

1. Payment Codes Table

MethodInternal ReferenceUBLFacturaeFatturaPADescription
CASH11001MP01Payment by currency (including bills and coins) in circulation, including checking account deposits.
DEBIT24902MP19Direct debit (The amount is to be, or has been, directly debited to the customer's bank account.)
HOLD3803MP12Indicates that the bank should hold the payment for collection by the beneficiary or other instructions.
TRANSFER43004MP05Bank transfer (The amount is to be, or has been, directly debited to the customer's bank account.)
AWARDING7ZZZ07Payment by assignment or award
PAGARE N O106010MP06Non transferable promissory note. Payment by an unconditional promise in writing made by one person to another, signed by the maker, engaging to pay on demand or at a fixed or determinable future time a sum certain in money, to order or to bearer.
CHEQUE112011MP02Payment by a pre-printed form on which instructions are given to an account holder (a bank or building society) to pay a stated sum to a named recipient.
REPOSITION12ZZZ12MP22Open account reimbursement.
SPECIAL/OTHER13ZZZ13MP22Defines any other payment method; use payment_method_text for custom descriptions.
COMPENSATION149714MP22Amounts which two partners owe to each other to be compensated in order to avoid useless payments.
PLUSGIRO155015MP18A standard Swedish payment method using the postal giro system.
CHEQUE B172317MP03Payment by a pre-printed form, which has been completed by a financial institution, on which instructions are given to an account holder (a bank or building society) to pay a stated sum to a named recipient.
BANK CARD194819MP08Payment by means of a card issued by a bank or other financial institution.
DEBIT TRANSFER313104MP13Payment by debit movement of funds from one account to another.
CREDIT CARD545419MP08Payment made by means of credit card
BANKGIRO565604MP03Payment method using the bank giro network.
TRANSFER SEPA585804MP05Credit transfer inside the Single Euro Payment Area (SEPA) system.
DEBIT SEPA595902MP19Direct debit inside the Single Euro Payment Area (SEPA) system.
GIRO101ZZZ13Giro
PAY NOW102ZZZ13Immediate payment (Pay Now)

2. Using the Endpoints

Below we show how to use the main endpoints to manage payments and bank accounts associated with contacts and invoices.

2.1. Create Bank Accounts

When creating a bank account, you must specify the account type to indicate which fields to use:

  • number: use the number field only.
    • number: Bank account number.
  • iban: use iban and bic.
    • iban: International Bank Account Number.
    • bic: SWIFT code of the bank.

Request Example:

curl --request POST \
     --url https://app-staging.b2brouter.net/accounts/{{ACCOUNT_ID}}/bank_accounts \
     --header 'X-B2B-API-Key: {{YOUR_API_KEY}}' \
     --header 'accept: application/json' \
     --header 'content-type: application/json' \
     --data '
{
  "bank_account": {
    "type": "number",
    "number": "ES9121000418450200051332",
    "name": "Ejemplo S.L.",
    "sufix": 123                                        #Suffix used for the creditor identifier in SEPA files
  }
}
'

Sample Response:

{
  "bank_account": {
    "type": "number",
    "id": 3296,                                         #Keep this ID to call the bank account on future requests
    "name": "Ejemplo S.L.",
    "number": "ES9121000418450200051332",
    "sufix": 123,
    "country": "es",
    "created_at": "2025-07-14T11:37:02.000Z",
    "updated_at": "2025-07-14T11:37:02.000Z"
  }
}

API Reference: https://developer.b2brouter.net/reference/create-bank-account

2.2. Create Contact

Configuring the payment details for invoices sent to a contact is useful to avoid managing this information each time you need to send a document.

Request Example:

curl --request POST \
     --url https://app-staging.b2brouter.net/projects/{{ACCOUNT_ID}}/clients.json \
     --header 'X-B2B-API-Key: {{YOUR_API_KEY}}' \
     --header 'accept: application/json' \
     --header 'content-type: application/json' \
     --data '
{
  "client": {
    ...
    "terms": "custom",
    "payment_method": 4,                                #Predefined payment method
    "payment_reminder_days": 2,
    "payment_method_text": "Example text",
    "bank_account_id": 3296,                            #ID of a previously created bank account.
    "bank_account_number": "IT12345678901"              #CONTACT account number, just needed in some payment methods
    ...
  }
}
'

API Reference: https://developer.b2brouter.net/reference/create-contact

2.3. Create Invoice

You don’t need to re-specify any payment fields that were already set on the contact unless you need to override them. To minimize API calls, include all required payment details—such as payment_method, bank_account_id, payment_terms, etc.—directly in the Create Invoice request instead of creating Contacts or Bank Accounts beforehand.

Request Example:

curl --request POST \
     --url https://app-staging.b2brouter.net/projects/{{ACCOUNT_ID}}/invoices.json \
     --header 'X-B2B-API-Key: {{YOUR_API_KEY}}' \
     --header 'content-type: application/json' \
     --data '

    {"invoice": {
        ...
        "payment_method": 4,
        "contact_iban": "DE44100000000123456789",
        "payment_reminder_days": 5,
        "bank_account_id": 3296
        ...    
    }}
    '

And if you haven’t provided bank_account_id, you can always include the bank_account object:

    {"invoice": {
        ...
        "bank_account": {
            "type": "number",
            "number": "ES9121000418450200051332"
    },
        ...    
    }}
    '