Getting started
API Developer Guide
Visa B2B Virtual Account Payment Method (VAPM) replaces paper invoices, checks, and plastic cards with virtual card numbers issued on demand. Each virtual card includes predefined spending controls to help reduce fraud and out-of-policy transactions.
B2B VAPM enables issuers, processors, fintechs, third-party payment providers, and travel agencies to provide corporate buyers with virtual card payments, spending limits, supplier controls, and reconciliation data. Enterprise Resource Planning (ERP) and Software-as-a-Service (SaaS) platforms can also integrate with the APIs on behalf of these providers.
Organizations that are not issuers must operate as a third-party agent (TPA) for a Visa member to access the production environment. All third-party implementations of the B2B VAPM APIs require an issuer relationship.
Supported use cases include accounts payable (AP) automation, payer-to-supplier payments, travel bookings, lodged-card programs, and employee expense management.
This guide documents three account and token types: Processor Primary Account Number (PAN), Visa Integrated Processing (VIP) pseudo account, and Virtual Payable Platform (VPP) / TSYS virtual account number (VAN). Documentation for an additional token type, Virtual Payment Account Number (VPAN) / Visa Virtual Card (VVC), is in development and will be added when available.
Decision guide
This guide is intended for solution architects, product managers, and technical evaluators.
Use this guide to answer two key questions:
- Should I integrate with B2B VAPM?
- Which account type best fits my use case?
Should I integrate with B2B VAPM?
B2B VAPM is designed to support automated corporate payments between buyers and suppliers. This table highlights the business scenarios that are a good fit for the API and those that fall outside its intended scope.
| This API is a good fit if you need to… | This API is not the right fit if you need to… |
|---|---|
| Automate accounts payable (AP) disbursements using virtual card numbers | Process consumer or retail card payments |
| Issue virtual cards to suppliers for single-use or recurring payments | Support non-Visa payment networks for Straight-Through Processing (STP). STP through CyberSource is available only for Visa transactions |
| Support Straight-Through Processing (STP) for Visa supplier payments through CyberSource | Issue physical cards or manage cardholder-facing products |
| Support travel or lodged-card programs with per-transaction spending controls | Process payments in a real-time consumer checkout flow without an issuer relationship |
| Manage expense programs with Spend Velocity, Exact Match, or Tolerance controls | Operate without PCI DSS compliance. Account management APIs return 16-digit account numbers |
| Bulk issue virtual accounts for high-volume B2B supplier programs | Bypass issuer relationship or processor certification requirements |
Choosing an account type
B2B VAPM supports three account types. The type you choose determines which endpoints are available, which processor you must use, and which onboarding steps apply.
| Feature | Visa Pseudo Account | TSYS VAN (Virtual Account Number) | Processor PAN |
|---|---|---|---|
| Workflow model | Proxy-pool account managed through Visa Commercial Payment Controls | Proxy-pool account managed through the TSYS Virtual Payable Platform (VPP) | Processor-provisioned account accessed through Bulk Requisition or Get Account Status |
| Issuance endpoint | Request Virtual Account (POST /vpa/v1/requisitionService) or Process Payments (POST /vpa/v1/payment/ProcessPayments) | Request Virtual Account or Process Payments | Request Virtual Account, or Bulk Requisition (POST /vpa/v1/bulkRequisitionService) |
| Request Virtual Account | Supported | Supported | Supported |
| Spending controls | Managed by Visa Commercial Payment Controls; separate Visa onboarding required | Spend Velocity and Exact Match applied at VPP; at least one rule still required on each request | Set at requisition time through Request Virtual Account |
| Spend Velocity, Exact Match, and Tolerance rules | Supported | Supported | Supported |
| STP support | Yes (CyberSource) | No | No |
| Mastercard buyers | Not supported | Supported | Not supported |
| Bulk Requisition | Yes | No | Yes |
| Get Account Status | Supported | Not supported | Supported |
| Regional availability | All regions | North America only | United States only; no new issuers are being onboarded |
| Processor requirement | Visa-certified tokenization processor required; the processor must complete tokenization certification with Visa before pseudo account issuance | TSYS VPP required | Processor supplies PANs directly; no Visa tokenization certification required |
| Payment controls onboarding required | Yes. The issuer must complete Visa Commercial Payment Controls onboarding before any pseudo account flow works | No | No |
Visa Pseudo Account flows depend on Visa Commercial Payment Controls, which is grouped under Visa Commercial Fraud Solutions. It has its own onboarding process and timeline separate from this API.
Confirm readiness with your Visa Implementation Manager before you commit to a pseudo account integration path. Some API field descriptions still use the earlier abbreviation VPC.
The TSYS Virtual Payable Platform operates in Eastern Time regardless of the time zone supplied in the Request Virtual Account or Process Payments request. Account for this when setting validity and rule dates for TSYS VAN buyers.
A Coordinated Universal Time (UTC) timestamp near midnight can resolve to the previous day in Eastern Time and cause a payment-date rejection. End-date handling is the same for Visa Pseudo Accounts and TSYS Virtual Accounts.
Next steps
After confirming that B2B VAPM fits your use case and selecting an account type:
- Review all eligibility and onboarding requirements in Prerequisites.
- Confirm sandbox access and issue your first virtual card in Quickstart.
Prerequisites
Complete these standard VDP setup tasks and product-specific requirements before you make any B2B Virtual Account Payment Method API calls.
Standard VDP setup
- Register for a VDP account at developer.visa.com.
- Complete the application approval process, if applicable to your products.
- Create a project and add the products and APIs required for your integration.
- Obtain API credentials from your project. B2B VAPM supports two VDP authentication modes: X-Pay Token and Mutual Auth (two-way SSL). See Headers and Authentication.
For detailed steps, see the Visa Developer Quick Start Guide.
Product-specific requirements
- Issuer relationship. Production access requires an established issuer relationship. Non-issuers must operate as third-party agents (TPA) of a Visa Member.
- PCI compliance. Payment Card Industry Data Security Standard (PCI DSS) compliance is required. Several account-management and payment endpoints return 16-digit account numbers. Your systems must meet PCI requirements before you use these endpoints.
- BIN tokenization. BIN tokenization or BIN mapping must be complete before any funding account API calls. A Bank Identification Number (BIN) is the first 6 to 8 digits of a card number that identifies the issuing bank.
- Processor certification (pseudo accounts only). If you use Visa pseudo accounts, your processor must complete tokenization certification with Visa before you can issue pseudo accounts.
- CyberSource registration (STP only). If you use Straight-Through Processing (STP) through CyberSource, the supplier must be registered with CyberSource and have a valid stpId before the first payment. The stpId is obtained from CyberSource, and obtaining it is a manual process today.
- Implementation Manager provisioning. A Visa Implementation Manager configures your CTE and production IDs. You cannot promote to production without completing this step.
- Payment controls onboarding (pseudo accounts only). If you use pseudo accounts, your issuer must complete onboarding to Visa Commercial Payment Controls. Pseudo account flows depend on it for spending-control management.
- Message Level Encryption (MLE). MLE is mandatory for new customers and is assigned when your project is set up. If it is enabled on your project, unencrypted requests fail. Load your MLE keys before you begin integration work.
Visa Commercial Payment Controls is a separate Visa product. Pseudo account issuance depends on it for spending-control management.
It has its own onboarding process that your issuer must complete before any pseudo account flow is possible. Confirm onboarding status with your Implementation Manager at the start of your integration, not after encountering errors.
Environment hosts and URL structure
Use these environment host URLs and URL patterns to construct B2B Virtual Account Payment Method API requests in sandbox, certification, and production environments.
Environment hosts
| Environment | Host |
|---|---|
| Sandbox | https://sandbox.api.visa.com |
| Certification Test Environment (CTE) | https://cert.api.visa.com |
| Production | https://api.visa.com |
URL structure
A full API URL consists of:
- Environment host, such as sandbox or production
- Product base path, such as /vpa/v1, /vpa/v2
- Endpoint path, such as /buyerManagement/buyer/get or /payment/ProcessPayments
Headers and authentication
B2B VAPM supports two Visa Developer Platform authentication modes: X-Pay Token and Mutual Auth (two-way SSL). It does not use HTTP Basic authentication or JSON Web Token (JWT) inbound authentication.
Three things must be in place before any business endpoint responds:
- One of the two supported authentication modes is configured. X-Pay Token sends a signed token in a header and your API key in the query string. Mutual Auth presents your client certificate on every call.
- Client Registration is complete for the target environment.
- Message Level Encryption (MLE) is configured if it is enabled on your project.
X-Pay Token
X-Pay Token uses two credentials from the Credentials tab of your Visa Developer project: an API key and a shared secret. The shared secret is never transmitted. It is the key you use to sign each request.
See the Visa Developer X-Pay Token guide.
Mutual Auth
With Mutual Auth, your client presents a certificate and private key installed on your machine. You do not send the X-PAY-TOKEN header and you do not append the apikey query parameter.
Per-request identifiers
Every request requires these identifiers in the request body, as applicable:
- clientId. Your client identifier, configured during Client Registration.
- buyerId. The identifier of the buyer associated with the request.
- proxyAccountNumber. The name of the proxy pool, where applicable.
Field-name casing varies by endpoint. Request Virtual Account uses uppercase messageID, clientID, and buyerID.
Get Security Code, Get Payment Details, and the account-management endpoints use lowercase messageId, clientId, and buyerId. Match each endpoint's casing exactly.
The messageId value must be unique per call, including on retries. Uniqueness is enforced. A duplicate value is rejected with a "message ID not unique" error, such as PP002 on Process Payments or CP002 on Cancel Payment.
Retrying with the same messageId is not idempotent. Generate a new Universally Unique Identifier (UUID) for every request.
Resend Payment has no specific duplicate-messageId error code. This is a known gap. Do not build retry logic that depends on one.
Message Level Encryption
Message Level Encryption (MLE) encrypts the request and response bodies with a project-specific key, on top of the transport-layer encryption.
MLE is mandatory for new customers. It is assigned when your project is set up. If MLE is enabled on your project, requests without encryption fail.
Existing integrations are not yet required to migrate, and no deadline has been announced. Visa expects existing customers to migrate. Plan the work rather than defer it.
- Download the MLE key pair from your VDP dashboard.
- Encrypt the request body and decrypt the response body.
- Include the Key ID as the MLE guide requires.
Endpoints that return an accountNumber or a securityCode are the highest-sensitivity cases. This includes the funding account APIs, Request Virtual Account, and Get Security Code.
Quickstart: Issue your first virtual card
Goal: Issue your first Visa virtual account in the sandbox environment, from a Visa Developer Platform (VDP) account through buyer onboarding, payment issuance, and security code retrieval.
The next two sections provide end-to-end implementation examples:
- Onboard a buyer demonstrates buyer, funding account, and proxy pool setup.
- Process a supplier payment demonstrates payment issuance and processing, including direct virtual account requests.
Complete the API calls in the documented sequence. Earlier calls generate values that are required by subsequent calls.
Quickstart issuance paths
This figure shows the two Quickstart issuance paths. Only the supplier payment path requires a supplier record and sends a supplier notification. The Bulk Requisition endpoint provides a third issuance path and is not included in this figure.
Before you begin
This tutorial uses the sandbox environment. The sandbox includes a preconfigured buyer, funding account, and proxy pool. No test data setup is required.
Send all requests to:
https://sandbox.api.visa.com
Before you begin, ensure that you have:
- A registered VDP account with B2B VAPM enabled for your project.
- Sandbox credentials from the VDP dashboard.
- An HTTP client, such as Postman, curl, or another REST API tool.
The sandbox environment returns predefined responses based on the configured examples. Response data does not vary based on the identifier values in the request.
The sample values clientId (B2BWS_1_1_1111) and buyerId (200031032) match the examples in the OpenAPI specification.
Use production identifiers only after you complete Certification Test Environment (CTE) testing and receive production credentials from your Implementation Manager.
Next steps
After completing the sandbox tutorial:
- Set up your own buyer, funding account, and proxy pool by following Onboard a Buyer.
- Process a supplier payment by following Process a Supplier Payment.
- Confirm your CTE and production identifiers with your Implementation Manager before moving to the next environment.
Onboard a buyer
The sandbox environment includes a preconfigured buyer, funding account, and proxy pool. In CTE and production environments, create these resources in this sequence:
- Create the buyer.
- Add a funding account.
- Create a proxy pool.
- Add suppliers (optional).
Complete the calls in this order. Each call returns values required by subsequent calls. Use lowercase characters for all identifier values.
Step 1: Create a buyer
The buyer is the top-level resource. It defines the company profile, notification settings, and payment configuration for associated resources. Child resources inherit these settings.
POST https://sandbox.api.visa.com/vpa/v1/buyerManagement/buyer/create?apikey={your-api-key}
Headers:
X-PAY-TOKEN: xv2:{utc-timestamp}:{hmac-sha256-hex}
Content-Type: application/json
Accept: application/json
Body:
{
"clientId": "B2BWS_1_1_1111",
"messageId": "1720545600000",
"contactInfo": {
"buyerId": "8887773",
"buyerName": "Acme Payments Inc",
"companyId": "8887773",
"contactName": "Alex Rivera",
"emailAddress": "[email protected]",
"phone1": "5125551234",
"addressLine1": "12301 Research Blvd",
"city": "Austin",
"state": "TX",
"zipCode": "78759",
"countryCode": "USA",
"defaultCurrencyCode": "USD"
},
"paymentConfig": {
"billingCurrency": "USD",
"allowableCurrencies": ["USD"],
"expirationDays": 30,
"expirationBufferDays": 5,
"paymentAdviceOption": "C"
},
"webServicesConfig": {
"webServicesEnabled": true,
"clientId": "B2BWS_1_1_1111",
"apiCodes": ["SMGS"]
}
}
Store the buyerId. Every later call requires it.
Set the companyId field to the processor company ID exactly as provided, including any leading zeros. Confirm the value with your Implementation Manager before submitting the request.
The Create Buyer operation creates a new company record. A companyId mismatch with an existing processor record does not cause this operation to fail. The mismatch is detected later during payment processing and returns one of these error codes:
- PP004
- PP010
- PP025
Error BSCB253 indicates that the company already exists and is unrelated to companyId validation during payment processing.
The relationship between companyId and buyerId is one-to-one. Each buyer maps to a single processor company, and each processor company maps to a single buyer.
Buyer templates reduce the amount of data required when onboarding multiple buyers. Templates are optional and are not required for an initial integration.
An issuer can create up to 20 buyer templates. After a buyer is linked to a template, the association is permanent. The template cannot be deleted, and the buyer cannot be reassigned to a different template.
Step 2: Add a funding account
The funding account is the 16-digit account number that all virtual accounts draw from. Every proxy pool and issued card charges back to it.
Payload shape depends on your processor integration mode. For an integrated processor, omit creditLimit and expirationDate; Visa retrieves both from the processor. For a non-integrated processor, provide creditLimit and expirationDate, and they must match processor records exactly. Set defaultAccount: true for the first funding account on a buyer. Use the Get Buyer API to check which processor integration mode applies to your buyer.
POST https://sandbox.api.visa.com/vpa/v1/accountManagement/fundingAccount/create?apikey={your-api-key}
Headers:
X-PAY-TOKEN: xv2:{utc-timestamp}:{hmac-sha256-hex}
Content-Type: application/json
Accept: application/json
Body:
{
"clientId": "B2BWS_1_1_1111",
"messageId": "1720545660000",
"buyerId": "8887773",
"accountNumber": "{funding-account-number}",
"currencyCode": "USD",
"defaultAccount": true,
"blockPurchases": false
}
A successful call returns AMCF000, "Funding Account has been created successfully."
This endpoint accepts and returns a 16-digit account number and is in Payment Card Industry Data Security Standard (PCI DSS) scope. Complete Bank Identification Number (BIN) tokenization or account mapping before calling the endpoint.
Step 3: Create a proxy pool
A proxy pool is the container that VAPM draws virtual accounts from when you issue a card. You pick the pool size and replenishment behavior at creation time.
- initialOrderCount. Number of virtual accounts loaded when the pool is first created.
- minAvailableAccounts. Threshold that triggers auto-replenishment.
- reOrderCount. Number of virtual accounts added on each reorder.
Set authControlEnabled: true if your buyer uses Visa Commercial Payment Controls for spending rules. This is required for Visa Pseudo Account and TSYS VAN pools.
POST https://sandbox.api.visa.com/vpa/v1/proxy/CreateProxyPool?apikey={your-api-key}
Headers:
X-PAY-TOKEN: xv2:{utc-timestamp}:{hmac-sha256-hex}
Content-Type: application/json
Accept: application/json
Body:
{
"clientId": "B2BWS_1_1_1111",
"messageId": "1720545720000",
"buyerId": "8887773",
"proxyAccountNumber": "AcmeMainPool",
"fundingAccountNumber": "{funding-account-number}",
"proxyPoolType": "1",
"proxyAccountType": "2",
"authControlEnabled": true,
"initialOrderCount": "50",
"minAvailableAccounts": "10",
"reOrderCount": "50"
}
The proxy pool is created immediately and is initially empty. VAPM populates the pool asynchronously.
If the create request fails, the response may return one of these error codes:
- PMCP035 - Invalid funding account number.
- PMCP036 - Authorization controls are required for pseudo or VAN buyers.
The proxyPoolType value determines whether an account number is returned to the pool for reuse or permanently consumed after use. It does not control whether a supplier can submit multiple transactions against a virtual account. Supplier usage is controlled by supplier configuration and spending controls. Define pool size and replenishment settings with your Implementation Manager.
Step 4: Check pool population
Proxy pool population occurs asynchronously and typically completes within 15 minutes. Population time varies based on system workload and the number of queued proxy pools.
Use the Get Proxy Pool endpoint to monitor proxyList.availableCards.
Poll the endpoint no more frequently than once every 30 seconds. More frequent polling does not accelerate population and increases API traffic.
POST https://sandbox.api.visa.com/vpa/v1/proxy/GetProxyPool?apikey={your-api-key}
Headers:
X-PAY-TOKEN: xv2:{utc-timestamp}:{hmac-sha256-hex}
Content-Type: application/json
Accept: application/json
Body:
{
"clientId": "B2BWS_1_1_1111",
"messageId": "1720546320000",
"buyerId": "8887773",
"proxyAccountNumber": "AcmeMainPool"
}
Expected response (abridged)
{
"GetProxyPoolResponse": {
"proxyList": {
"availableCards": "50",
"totalCards": "50",
"usedCards": "0"
}
}
}
You do not need to wait for proxy pool population to complete before issuing a payment. VAPM can process a payment using an account requested at issuance time. Use the availableCards value to verify pool health before moving to production.
Skip this step when using on-demand card issuance. Create a supplier only if Visa sends payment notifications directly to the supplier and the supplier redeems the virtual account in its own system. Set supplierType to VPA for standard suppliers or STP for CyberSource Straight-Through Processing suppliers. You can create suppliers at any time after the proxy pool is available.
POST https://sandbox.api.visa.com/vpa/v1/supplier/CreateSupplier?apikey={your-api-key}
Headers:
X-PAY-TOKEN: xv2:{utc-timestamp}:{hmac-sha256-hex}
Content-Type: application/json
Accept: application/json
Body:
{
"clientId": "B2BWS_1_1_1111",
"messageId": "1720546920000",
"buyerId": "8887773",
"supplierId": "SUP-ACME-102",
"supplierName": "Northwind Logistics",
"supplierType": "VPA",
"supplierAddressLine1": "500 Terry Francois Blvd",
"supplierCity": "San Francisco",
"supplierState": "CA",
"supplierPostalCode": "94158",
"supplierCountryCode": "USA",
"primaryEmailAddress": "[email protected]",
"supplierLanguage": "en_US"
}
Onboarding is complete after you create the buyer, funding account, and proxy pool.
Process a supplier payment
Use this issuance path when Visa sends a payment notification to the supplier and the supplier redeems the virtual account through the Visa Supplier Notification portal.
Visa selects an account from the proxy pool, applies the configured controls, and delivers the notification to the supplier.
Send a payment instruction
POST https://sandbox.api.visa.com/vpa/v1/payment/ProcessPayments?apikey={your-api-key}
Headers:
X-PAY-TOKEN: xv2:{utc-timestamp}:{hmac-sha256-hex}
Content-Type: application/json
Accept: application/json
Body:
{
"clientId": "B2BWS_1_1_1111",
"buyerId": "8887773",
"messageId": "msg-2026-07-09-0100",
"payment": {
"supplierID": "SUP-ACME-102",
"currencyCode": "USD",
"paymentGrossAmount": 4200.00,
"paymentDescription": "Invoice INV-20260709",
"paymentRequestDate": "2026-07-09",
"paymentExpiryDate": "2026-07-23",
"invoices": [
{ "invoiceNumber": "INV-20260709" }
]
}
}
The payment object also supports accountType, paymentType, accountLimit, accountNumber, and expirationDate. At least one spending rule is required on every call. For TSYS VAN-enabled buyers, Spend Velocity and Exact Match are also enforced at the TSYS Virtual Payable Platform (VPP), but a rule is still required on the request. A missing rule returns PP057.
Expected response
{
"ProcessResponse": {
"messageId": "msg-2026-07-09-0100",
"statusCode": "PP001",
"statusDesc": "Successfully processed.",
"accountNumber": "{virtual-account-number}",
"expirationDate": "07/2027"
}
}
A successful call returns HTTP 201 Created with statusCode PP001. There is no second status to poll. Process Payments does not return a paymentId. Retain the messageId you sent; it is the originalMessageId used to reference this payment on cancel, resend, and payment detail URL requests.
The paymentExpiryDate field (YYYY-MM-DD) specifies the date by which the supplier must redeem the payment. This value is different from the card expirationDate field (MM/YYYY), which specifies the virtual account expiration date.
Use expirationDate as the field name for card expiration values. References to cardAccountExpiryDate in previously published examples are incorrect.
Verify the payment
If you do not specify a date range, the endpoint returns data for the previous nine months.
When you specify a date range, the endpoint supports up to 27 months of data. The earliest supported start date is 27 months before the current date.
The endpoint returns a maximum of 250 payment records per request. Use resultSetNo to retrieve additional records when the result set exceeds this limit. Continue requesting subsequent result sets until hasMoreElements returns Y.
POST https://sandbox.api.visa.com/vpa/v1/payment/GetPaymentDetails?apikey={your-api-key}
Headers:
X-PAY-TOKEN: xv2:{utc-timestamp}:{hmac-sha256-hex}
Content-Type: application/json
Accept: application/json
Body:
{
"clientId": "B2BWS_1_1_1111",
"messageId": "quickstart-getpmt-001",
"buyerId": "8887773",
"resultSetNo": "1"
}
Store payment records locally if you require access to data older than 27 months.
Manage the payment lifecycle
Use these endpoints to manage an existing payment:
- Resend a notification when the supplier does not receive or act on the original notification.
- Cancel a payment that has not been collected.
Each request references the original payment by using the originalMessageId value.
Resend a payment notification (omit expirationDate to resend without extending the card)
POST https://sandbox.api.visa.com/vpa/v1/payment/ResendPayment?apikey={your-api-key}
Body:
{
"clientId": "B2BWS_1_1_1111",
"buyerId": "8887773",
"messageId": "msg-2026-07-09-0200",
"originalMessageId": "msg-2026-07-09-0100",
"accountNumber": "{virtual-account-number}",
"expirationDate": "2026-08-06"
}
Cancel a payment
POST https://sandbox.api.visa.com/vpa/v1/payment/CancelPayment?apikey={your-api-key}
Body:
{
"clientId": "B2BWS_1_1_1111",
"buyerId": "8887773",
"messageId": "msg-2026-07-09-0300",
"originalMessageId": "msg-2026-07-09-0100",
"accountNumber": "{virtual-account-number}"
}
Cancellation is supported only for payments that have not been collected. If the supplier has already collected the payment, the request fails with CP031 (payment already collected by supplier). After a payment is collected, it cannot be canceled. Resolve the transaction through your standard chargeback or refund process.
Other cancellation-related errors include:
- CP025 - The bank or buyer is not configured for VPA.
- CP032 - Cancellation is not supported for DPS buyers.
Request a virtual account directly
Request a new virtual account, apply a Spend Velocity (SPV) control to limit total spend, define the validity period, and retrieve an account from the sandbox proxy pool.
The response returns the 16-digit account number and the card expiration date.
Use uppercase characters for all identifier values in requests to this endpoint.
Key fields
- action. A to add, U to update, D to delete. Use A here.
- numberOfCards. 1. A single card returns its details inline.
- proxyPoolID. Your sandbox proxy pool. Optional if the buyer has only one single-use pool.
- requisitionDetails.startDate and endDate. The requisition validity window, in YYYY-MM-DD format. endDate cannot exceed 36 months from the date the card was first requested.
- requisitionDetails.timeZone. A UTC offset, such as UTC-08:00. The TSYS Virtual Payable Platform processes in Eastern Time regardless of this value.
- requisitionDetails.rules. At least one authorization rule. Each rule has a ruleCode and overrides.
Request
POST https://sandbox.api.visa.com/vpa/v1/requisitionService?apikey={your-api-key}
Headers:
X-PAY-TOKEN: xv2:{utc-timestamp}:{hmac-sha256-hex}
Content-Type: application/json
Accept: application/json
Body:
{
"action": "A",
"clientID": "B2BWS_1_1_1111",
"messageID": "quickstart-req-001",
"buyerID": "200031032",
"proxyPoolID": "Proxy12345",
"numberOfCards": "1",
"requisitionDetails": {
"startDate": "2026-07-10",
"endDate": "2026-07-17",
"timeZone": "UTC-08:00",
"rules": [
{
"ruleCode": "SPV",
"overrides": [
{ "sequence": "0", "overrideCode": "spendLimitAmount", "overrideValue": "500.00" },
{ "sequence": "0", "overrideCode": "amountCurrencyCode", "overrideValue": "840" },
{ "sequence": "0", "overrideCode": "rangeType", "overrideValue": "3" },
{ "sequence": "0", "overrideCode": "startDate", "overrideValue": "07/10/2026" },
{ "sequence": "0", "overrideCode": "endDate", "overrideValue": "07/17/2026" },
{ "sequence": "0", "overrideCode": "updateFlag", "overrideValue": "NOCHANGE" }
]
}
]
}
}
Expected response
{
"RequisitionVirtualAccountResponse": {
"messageID": "quickstart-req-001",
"accountNumber": "{virtual-account-number}",
"expirationDate": "07/2027",
"responses": [
{ "responseCode": "00", "responseDescription": "Request processed successfully." }
]
}
}
Save the accountNumber and expirationDate. Both values are required when retrieving the security code.
B2B VAPM supports three authorization rule types across all account types:
- Spend Velocity (SPV) limits total authorized spend across one or more transactions within a defined period. Use this rule for open-ended spending limits, such as project or departmental budgets.
- Exact Match (VPAS) requires a single authorization for the exact specified amount. Any amount above or below the defined value is declined. Use this rule for single-payment invoices.
- Tolerance (TOLRNC) allows a configurable variance from a specified amount.
Each requisition requires at least one authorization rule.
For SPV rules, rangeType accepts a numeric value.
| rangeType | Spend window |
|---|---|
| 1 | Recurring |
| 2 | Monthly |
| 3 | Date range |
| 4 | Weekly |
| 5 | Daily |
For a complete list of authorization rule codes and their supported override fields, see the B2B Virtual Account Payment Method Codes Reference.
Delete a virtual account
Delete a virtual account by using the same endpoint as issuance, with action: "D".
POST https://sandbox.api.visa.com/vpa/v1/requisitionService?apikey={your-api-key}
Body:
{
"clientID": "B2BWS_1_1_1111",
"buyerID": "8887773",
"messageID": "msg-2026-07-09-0400",
"action": "D",
"accountNumber": "{virtual-account-number}"
}
Deleting a virtual account cancels all associated payments and permanently disables the secure payment link. A deleted virtual account cannot be restored or reactivated. If you need to cancel only specific payments, cancel those payments individually instead of deleting the virtual account.
Retrieve the security code
The requisition response does not include the security code. Retrieve the security code in a separate request by using the accountNumber and expirationDate values returned by the requisition response.
Separating security code retrieval from card issuance reduces exposure of sensitive card data during the primary issuance workflow.
This endpoint requires lowercase identifier values. Specify expirationDate in MM/YYYY format.
Request
POST https://sandbox.api.visa.com/vpa/v1/accountManagement/GetSecurityCode?apikey={your-api-key}
Headers:
X-PAY-TOKEN: xv2:{utc-timestamp}:{hmac-sha256-hex}
Content-Type: application/json
Accept: application/json
Body:
{
"clientId": "B2BWS_1_1_1111",
"messageId": "quickstart-cvv-001",
"buyerId": "200031032",
"accountNumber": "{virtual-account-number}",
"expirationDate": "07/2027"
}
Expected response
{
"GetSecurityResponse": {
"messageId": "quickstart-cvv-001",
"statusCode": "CVV001",
"statusDesc": "Security code retrieved successfully.",
"securityCode": "123"
}
}
The security code is highly sensitive and has a limited validity period. Retrieve it only when required for payment processing.
Do not store, cache, or log the security code. Handle the value only within PCI DSS-compliant systems and processes.
Confirm success
You now have the information required to use the virtual account:
- A 16-digit account number.
- An expiration date in MM/YYYY format.
- A three-digit security code.
VAPM applies the configured Spend Velocity (SPV) rule to the virtual account. Authorizations that exceed the configured spending limit during the validity period are declined. Authorizations submitted on or after the end date are also declined.
Confirming successful integration
Your integration is successful when a Request Virtual Account or Process Payments request issues a virtual account and applies the configured spending controls.
Integration is confirmed when the supplier receives a payment notification and successfully authorizes a transaction within the configured spending limits.
These indicators confirm a successful integration:
- A Request Virtual Account or Process Payments request returns a successful response and issues a virtual account number.
- The supplier receives a payment notification with the expected payment details.
- The supplier successfully authorizes a test transaction within the configured spending limits and validity period.
- The proxy pool reports availableCards > 0, confirming that the pool has been populated.
Visa Commercial Payment Controls enforce the configured spending controls. For pseudo account implementations, issuers must complete Visa Commercial Payment Controls onboarding before end-to-end transaction validation can be performed.
A successful Create Buyer request does not confirm that the payment funding path is configured correctly. Complete the full onboarding process by creating the buyer, funding account, and proxy pool before testing virtual account issuance.
Validate before Production
Complete these validation steps in the Certification Test Environment (CTE) before requesting production access from your Implementation Manager.
Production access is granted after successful CTE certification.
In the CTE environment, buyer configuration uses your actual implementation settings, while virtual accounts and transactions use test data.
Connectivity and authentication
Validate these connectivity and authentication requirements in the Certification Test Environment (CTE):
- Use the CTE values provided by your Implementation Manager (clientId, buyerId, proxyAccountNumber) in all test requests.
- Verify that Message Level Encryption (MLE) is functioning correctly before testing account-number retrieval or payment issuance workflows. MLE is required for new implementations.
Buyer and funding account setup
Validate these prerequisites in the Certification Test Environment (CTE):
-
Create the buyer successfully.
- Verify that the companyId matches the processor company ID exactly, including any leading zeros. A mismatch is detected during payment processing and can return PP004, PP010, or PP025. The relationship between companyId and buyerId is one-to-one.
- Add a funding account and confirm that BIN tokenization or account mapping is complete at the processor level.
- For pseudo account implementations, confirm that processor tokenization certification with Visa is complete.
- For pseudo account implementations, confirm that issuer onboarding to Visa Commercial Payment Controls is complete.
Proxy pool and account availability
Validate these requirements in the Certification Test Environment (CTE):
- Create a proxy pool successfully by using (POST /vpa/v1/proxy/CreateProxyPool) and availableCards > 0, confirmed via POST /vpa/v1/proxy/GetProxyPool.
-
For TSYS VAN implementations, validate authorization rules and validity periods with the understanding that the TSYS Virtual Payable Platform processes dates and times in Eastern Time, regardless of the time zone specified in the request.
Proxy pool population is asynchronous and typically completes within 15 minutes. Population time can vary based on system workload and the number of queued proxy pools. A service-level commitment does not apply to pool population.
You do not need to wait for pool population to complete before issuing a payment. VAPM can process a payment by requesting an account at issuance time.
End-to-end validation
Validate these requirements in the Certification Test Environment (CTE):
- A Process Payments request completes successfully, issues a virtual account, applies the configured spending controls, and, for supplier payment flows, sends a payment notification to the supplier.
- Confirm that the supplier receives a payment notification containing the expected payment and virtual account details.
- Confirm that the supplier successfully authorizes a test transaction within the configured spending limits and validity period.
- The Get Payment Details endpoint returns the completed test transaction and associated payment information (POST /vpa/v1/payment/GetPaymentDetails).
PCI compliance
Verify that PCI compliance certification is in place for all systems that process account management responses. These responses contain sensitive payment data, including 16-digit account numbers and, for Get Security Code requests, security codes.
STP validation (STP integrations only)
Validate these requirements in the Certification Test Environment (CTE):
- Confirm that all STP suppliers are registered with CyberSource.
- Verify that each supplier has a valid stpId provided by CyberSource. Obtaining the stpId is a manual process. Requests that specify a missing or unregistered stpId return PP051.
- Verify that a test STP transaction completes successfully through CyberSource in the CTE environment.
Contact your Implementation Manager to obtain the complete CTE certification checklist before beginning production validation. The checklist may include additional certification requirements and approval criteria that are not covered in this documentation.
Production readiness
The Certification Test Environment (CTE) is a preproduction environment that closely mirrors production behavior. Unlike the sandbox environment, CTE credentials are not self-service.
CTE environment overview
Your Implementation Manager provisions the CTE values for clientId, buyerId, and proxyAccountNumber. The same provisioning model applies to the production environment.
Use CTE to complete end-to-end integration testing before requesting promotion to production. Production access is granted only after successful CTE certification.
CTE certification checklist
Complete these validation activities in the Certification Test Environment (CTE):
- Verify that your Implementation Manager has provisioned the required CTE identifiers, including clientId, buyerId, and proxyAccountNumber.
- Create at least one buyer, funding account, and proxy pool.
- Create at least one supplier.
- Issue at least one end-to-end payment and verify the transaction by using Get Payment Details.
- Validate the Cancel Payment and Resend Payment workflows if your implementation uses those capabilities.
- Validate application error handling for PP, CP, and RSP error codes.
- Verify that Get Payment Details pagination functions correctly for your expected transaction volume, including processing additional results when hasMoreElements indicates more records are available.
- For STP implementations, verify that CyberSource credentials and stpId values are valid in CTE.
- For pseudo account implementations, verify that Visa Commercial Payment Controls onboarding is complete.
- Verify that Message Level Encryption (MLE) functions correctly end to end.
- Obtain written approval from your Implementation Manager confirming that CTE testing is complete.
Production promotion gates
Verify that these requirements are complete before requesting production access:
- PCI DSS compliance: Ensure that all systems handling account management and payment responses meet PCI DSS requirements. These responses contain 16-digit account numbers and other cardholder data.
- Issuer relationship: Establish an issuer relationship or obtain Third-Party Agent (TPA) sponsorship before requesting production access.
- BIN tokenization or mapping: Complete tokenization or account mapping for all production BINs before using funding account APIs in the production environment.
- Message Level Encryption (MLE): Enable and validate MLE. MLE is required for new implementations. When MLE is enabled, requests that do not use encryption are rejected.
- CTE certification approval: Obtain confirmation from your Implementation Manager that all CTE certification requirements have been completed successfully.
- Production credentials: Obtain production clientId values and credentials from your Implementation Manager. Production credentials are provisioned and are not self-service.
Production go-live checklist
Complete these activities before processing production transactions:
-
Verify that your Implementation Manager has provisioned your production clientId and credentials.
-
Complete client registration in the production environment.
-
Validate connectivity to the production host before sending live traffic.
-
Process a low-value test payment and verify that the supplier receives the payment notification.
-
Verify that the Get Payment Details endpoint returns the test payment.
-
Monitor for these provisioning and configuration errors:
- PP003 - Invalid client ID
- PP004 - Buyer not found
- PP010 - Buyer does not belong to the calling issuer
- PP025 - Buyer is valid, but web services are not enabled
These errors typically indicate a provisioning or credential mismatch. Contact your Implementation Manager for assistance.
-
Verify that monitoring and alerting are in place for PP016 errors and HTTP 5xx responses before processing production transaction volumes.
Sandbox, CTE, and Production differences
| Aspect | Sandbox | CTE | Production |
|---|---|---|---|
| Host | sandbox.api.visa.com | cert.api.visa.com | api.visa.com |
| Credentials | VDP dashboard-provisioned | Implementation Manager-provisioned | Implementation Manager-provisioned |
| Responses | Static responses based on configured examples | Production-like behavior with test data | Production behavior with live data |
| Buyer configuration | Preconfigured sample buyer | Your implementation-specific configuration | Your implementation-specific configuration |
| Account numbers returned | Sample values that cannot be used for payment processing | Test account numbers for certification and validation | Live account numbers for production transactions |
| Transaction authorization | Not supported | Test transactions only | Live transaction authorization |
| Self-service setup | Supported | Not supported | Not supported |
| Access provisioning | Self-service | Controlled by the Implementation Manager | Controlled by the Implementation Manager |
| Error coverage | Limited subset of error responses | Full error catalog | Full error catalog |
| PCI DSS compliance required | No | No | Yes |
Use the sandbox environment for initial development and API familiarization. Use CTE for end-to-end integration validation and certification testing. Use the production environment only after completing CTE certification and receiving production credentials from your Implementation Manager.
Operational considerations
This figure shows the retry strategy for API requests. Retry requests that fail because of HTTP 5xx responses, network errors, PP016, or CP037.
Do not retry requests that fail because of business validation errors. Generate a new messageId for every retry attempt.
Retry classification
- Message ID uniqueness: Generate a unique messageId for every API request and retain it for audit and troubleshooting purposes. Duplicate message IDs are rejected with PP002 for Process Payments requests and CP002 for Cancel Payment requests. Generate a new UUID for every request, including retry attempts.
- Terminal payment states: Treat CP031 (payment already collected by supplier) and CP161 (payment already canceled) as terminal outcomes. Do not retry requests after either response code is returned.
- Retry behavior: Retry HTTP 5xx responses, network failures, PP016, and CP037 by using exponential backoff with jitter. Limit retries to three attempts. Do not retry PP, CP, or RSP business validation errors because these responses indicate issues with request data or resource state.
- PCI DSS requirements: Handle security codes returned by Get Security Code only within PCI DSS-compliant systems. Do not store, cache, or log security codes. Mask all but the last four digits of account numbers in application logs.
-
Parse response formats explicitly:
B2B VAPM endpoints use multiple response
structures. Determine the request outcome by evaluating the appropriate response object
for the endpoint being called:
Endpoint family Where the outcome appears Fields to read Most core /vpa endpoints responseStatus Fields within responseStatus Endpoints that return additional error information errorObject errorCode , errorMessage Payment endpoints Response wrapper (for example, ProcessResponse ) statusCode , statusDesc -
Production deletions are permanent. Deleting a virtual account, funding account, or proxy pool permanently removes the resource and cannot be reversed. Before deleting a resource, verify that no active or pending payments are associated with it.