Request Batch

You can create virtual accounts between 10 and 5000 through an array.

POST {{api_base_url}}/api/virtual-account-batch

Request Batch

Request Body

Name
Type
Description

externalId*

string

Mandatory. An ID that is meaningful to you and your system. It must be unique and alphanumeric, no characters allowed.

accountNumber*

string

Your Localpayment account number

country*

string

beneficiary*

Object

Party Object

beneficiary.type*

string

Possible values: "COMPANY" or "INDIVIDUAL"

beneficiary.name*

string

Individual / company name

beneficiary.lastname

string

Only for INDIVIDUAL type / Ignored for COMPANY.

beneficiary.document

Object

document.type

string

Document type (related to the beneficiary's residence. Must be Brazilian resident "CPF"; "CNPJ")

document.id

string

Identity document id. Usually numbers or combination of numbers and letters (related to the beneficiary's residence).

address

Object

Party Object

address.street

String

Street address

address.number

String

number address

address.country

String

Country address

accounts*

array

Array of beneficiaries

address.zipcode

string

Address zip code

address.city

string

City of the address

address.state

string

State address

{
    "externalId": "{{externalId}}",
    "internalId": "{{internalId}}",
    "accountNumber": "{{YourAccountNumber}}",
    "status": {
        "code": "100",
        "description": "INPROGRESS",
        "detail": "Batch Process Virtual Account in progress"
    },
    "comment": "For obtaining the asynchronous response, kindly submit a request to the service after a brief interval. GET {api_environment_url}/api/virtual-account-batch/1707400608-1707400608515"
}

Example: Virtual Account request

{
  "externalId": "{{externalId}}",
  "accountNumber": "{{YourAccountNumber}}",
  "country": "MEX",
  "name": "Virtual Account",
   [
    {
      "externalId": "1111111111-1",
      "beneficiary": {
        "type": "INDIVIDUAL",
        "name": "BeneficiaryName",
        "lastname": "BeneficiaryLastname",
        "document": {
          "id": "MAL180222MS6",
          "type": "RFC"
        },
        "address": {
          "city": "city",
          "state": "state",
          "zipcode": "zipcode",
          "street": "street",
          "number": "number",
          "country": "country"
        }
      }
    },
    {
      "externalId": "1111111111-2",
      "beneficiary": {
        "type": "INDIVIDUAL",
        "name": "BeneficiaryName",
        "lastname": "BeneficiaryLastname",
        "document": {
          "id": "LEKF8111119Z5",
          "type": "RFC"
        }
      }
    },
    {
      "externalId": "1111111111-3",
      "beneficiary": {
        "type": "INDIVIDUAL",
        "name": "BeneficiaryName",
        "lastname": "BeneficiaryLastname",
        "document": {
          "id": "MAL180212MS6",
          "type": "RFC"
        },
        "address": {
          "city": "city",
          "state": "state",
          "zipcode": "zipcode",
          "street": "street",
          "number": "number",
          "country": "country"
        }
      }
    },
    {
      "externalId": "1111111111-4",
      "beneficiary": {
        "type": "INDIVIDUAL",
        "name": "BeneficiaryName",
        "lastname": "BeneficiaryLastname",
        "document": {
          "id": "LEKF8111219Z5",
          "type": "RFC"
        }
      }
    },
    {
      "externalId": "1111111111-5",
      "beneficiary": {
        "type": "INDIVIDUAL",
        "name": "BeneficiaryName",
        "lastname": "BeneficiaryLastname",
        "document": {
          "id": "LEKF8511119Z5",
          "type": "RFC"
        },
        "address": {
          "city": "city",
          "state": "state",
          "zipcode": "zipcode",
          "street": "street",
          "number": "number",
          "country": "country"
        }
      }
    },
    {
      "externalId": "1111111111-6",
      "beneficiary": {
        "type": "INDIVIDUAL",
        "name": "BeneficiaryName",
        "lastname": "BeneficiaryLastname",
        "document": {
          "id": "MAL190222MS6",
          "type": "RFC"
        }
      }
    },
    {
      "externalId": "1111111111-7",
      "beneficiary": {
        "type": "INDIVIDUAL",
        "name": "BeneficiaryName",
        "lastname": "BeneficiaryLastname",
        "document": {
          "type": "DNI",
          "id": "28000006"
        },
        "address": {
          "city": "city",
          "state": "state",
          "zipcode": "zipcode",
          "street": "street",
          "number": "number",
          "country": "country"
        }
      }
    },
    {
      "externalId": "1111111111-8",
      "beneficiary": {
        "type": "INDIVIDUAL",
        "name": "BeneficiaryName",
        "lastname": "BeneficiaryLastname",
        "document": {
          "id": "MAL180221MS6",
          "type": "RFC"
        }
      }
    },
    {
      "externalId": "1111111111-9",
      "beneficiary": {
        "type": "INDIVIDUAL",
        "name": "BeneficiaryName",
        "lastname": "BeneficiaryLastname",
        "document": {
          "id": "MAL180822MS6",
          "type": "RFC"
        },
        "address": {
          "city": "city",
          "state": "state",
          "zipcode": "zipcode",
          "street": "street",
          "number": "number",
          "country": "country"
        }
      }
    },
    {
      "externalId": "1111111111-10",
      "beneficiary": {
        "type": "INDIVIDUAL",
        "name": "BeneficiaryName",
        "lastname": "BeneficiaryLastname",
        "document": {
          "id": "LEKF9111119Z5",
          "type": "RFC"
        }
      }
    },
    {
      "externalId": "1111111111-11",
      "beneficiary": {
        "type": "INDIVIDUAL",
        "name": "BeneficiaryName",
        "lastname": "BeneficiaryLastname",
        "document": {
          "id": "LEKF8111112Z5",
          "type": "RFC"
        },
        "address": {
          "city": "city",
          "state": "state",
          "zipcode": "zipcode",
          "street": "street",
          "number": "number",
          "country": "country"
        }
      }
    },
    {
      "externalId": "1111111111-12",
      "beneficiary": {
        "type": "INDIVIDUAL",
        "name": "BeneficiaryName",
        "lastname": "BeneficiaryLastname",
        "document": {
          "id": "MAL183222MS6",
          "type": "RFC"
        },
        "address": {
          "city": "city",
          "state": "state",
          "zipcode": "zipcode",
          "street": "street",
          "number": "number",
          "country": "country"
        }
      }
    }
  ]
}'

Check your virtual accounts

Using the api

To query the virtual accounts created using the endpoint by specifying the "ExternalId".

ExternalId query

GET {{api_base_url}}/api/virtual-account-batch/External ID

Headers

Name
Type
Description

Authorization*

String

Mandatory. JWT token in format Bearer eyj0.... For more information about authentication, please refer to Authentication.

Request Body

Name
Type
Description

externalId

String

An ID that is meaningful to you and your system. Must be unique.

{
"externalId": "{{externalId}}",
    "internalId": "{{internalId}}",
    "accountNumber": "{{accountNumber}}",
    "status": {
        "code": "200",
        "description": "COMPLETED",
        "detail": "Batch Process Virtual Account completed"
    },
    "comment": "The batch process is done - The process started at = 2024-02-08 16:01:17.486 - Total accounts requested = N - Total accounts created = N - The process finished at = 2024-02-08 16:01:20.058 - ",
    "csvFormatResponse": "internal_id,external_id,bank_account\n2094b1fa-90d4-462c-a41b-b714ad1c18f2,
	d0deb404-ba1b-453f-bc86-62267f003x11,111111119800014111\nde15c603-9bce-4568-ad01-470df19d111a,
	d25b4942-1510-4f7e-b458-8725ac6e1111,111111119800014112\nb910d8fc-ef07-44f9-bce5-03b67770111c,
	c6b412fc-94e0-46a3-9ce1-110c11fff05c,111111119800014113\n493cc772-32b3-4d30-bbff-a72c7d929a11,
	0243d9d0-c92d-4054-847d-111ac2a37f11,111111119800014114\nf360736f-74eb-43f9-aa8a-a37815e88d11,
	a5cf86df-24d4-4d01-b821-1116eb4d111d,111111119800014115\n8dbcff2c-8b02-454b-89c6-7095ead1cb1c,
	9c4ebe0f-6a14-4bf6-a4d3-c111c57ed9ee,111111119800014116\n65a3d8b1-71eb-4646-afb4-84458ca1111e,
	8a7de341-3bee-48f2-b189-b5d61111b998,111111119800014117\n1d525efa-b5cd-4d98-8f48-414111b11fc1,
	a5ff37c7-3e11-4df9-baf0-8a8847451b11,111111119800014118\nb10bf99b-fe71-45df-9783-74e4bf1111ce"
	}

Using the front

You can consult in the front the generation of accounts from the menu: Payin/virtual Account and enter the query data in the filter.

Last updated