Request Money (Invoice)
The Request Money (Send Invoice) feature allows for a user to "request payment" from a party using an email. Users of the API can use this functionality as part of an existing invoicing capability for a different provider.
Request Money from a business in your local currency (or USD, Euro, GBP)
You can request payment from a business and attach an invoiced using createInvoice. For example:
POST https://sandbox-api.veem.com/veem/v1.2/invoices
Headers
There are 2 headers necessary for the use of this endpoint:
- X-request-id: This is a number unique to the current API request, and follows the UUID format. Reusing this header without changing the value will result in a 409 (Conflict) status. An example X-request-id is as follows:
48855846-628d-4177-b071-80332a116f0a
- Authorization: This header holds the bearer token required to use Veem's public API, and belongs to the owner account. Failure to use a valid bearer token will result in a 404 (Not Found) status. An example of a valid token is as follows:
Bearer c047594b-082c-4da1-be89-08fe3770f4b3See Get Access Token section to generate your bearerToken
Request payload
{
"notes": "Invoice test",
"payer": {
"type": "Business",
"email": "[email protected]",
"phone": "5511941618581",
"lastName": "last_name",
"firstName": "first_name",
"countryCode": "US",
"businessName": "US Payer",
"bank": {
"bankAccountNumber": "12345678",
"bankInstitutionNumber": "879",
"bankName": "Bank of France",
"currencyCode": "USD",
"iban": "FR1420041010050500013M02606",
"isoCountryCode": "US",
"routingNumber": "041215032",
"swiftBic": "CUCXCATT",
"transitCode": "45622"
},
"business": {
"address":{
"countryCode":"CA",
"street":"123 Main",
"postalCode":"123456",
"province":"Cognac",
"city":"Marcel"
},
"entity": "Corporation",
"taxIdNumber": "XAXX010101000"
},
"phoneCountryCode": "+1",
"subIndustry": "Software",
"industry": "Software, IT and Telecommunications"
},
"amount": {
"number": 100,
"currency": "USD"
},
"fundingMethod": {
"id": 55115,
"type": "Card"
},
"purposeOfPayment": "Services",
"purposeOfPaymentDescription": "Services",
"extraInfo": {
"customInfo": {
"custom1": "test"
}
},
"goodFundsPayment" : false,
"sweepToWalletId" : 51244, // See Partner Notes
"accountId": 944208 // See Partner Notes
}Request Parameters
The following table contains detailed information on the payload's parameters, such as the parameter name, whether it is mandatory or not, formatting (if applicable), and size of the parameter. You can retrieve various fields such as countryCode, bankName, bankCode, swiftCode, and purposeOfPayment from the Country-Currency-Map endpoint. Please refer to the following link: country-currency-map.
Parameter | Mandatory? | Format/Values | Size (in chars) |
|---|---|---|---|
notes | No | String | 128 (Max) |
payer.firstName | Yes | String | 64 (Max) |
payer.lastName | Yes | String | 64 (Max) |
payer.email | Yes | String | 254 (Max) |
payer.phone | Yes | String | 32 (Max) |
payer.countryCode | Yes | ISO 3166-1 alpha-2 standard (eg. US, BE, BT etc) | 2 |
payer.type | Yes | Business or Personal | |
payer.industry | Yes | Agriculture | |
payer.subIndustry | Yes |
| |
payer.businessName | Yes | String | 128 (Max) |
payer.phoneCountryCode | Yes | Country code (such as +1 for US or Canada, +31 for Netherlands etc. More info available below the table)
| 2-5 |
payer.business.address.countryCode | Yes | ISO 3166-1 alpha-2 standard (eg. US, BE, BT etc) | 2 |
payer.business.address.street | Yes | String | 128 (Max) |
payer.business.address.province |
| String | 64 (Max) |
payer.business.address.state |
| String | 64 (Max) |
payer.business.address.postalCode | Yes | String | 64 (Max) |
payer.business.address.city | Yes | String | 64 (Max) |
payer.business.entity | Yes |
| |
payer.business.taxIdNumber | Yes | String | 32 (Max) |
payer.bank.isoCountryCode | Yes | ISO 3166-1 alpha-2 standard (eg. US, BE, BT etc) | 2 |
payer.bank.bankName | Yes | String (Note: Bank name and bank routing number MUST be valid) | 128 (Max) |
payer.bank.currencyCode | Yes | Currency Code (ISO 4217) | 3 |
payer.bank.bankAccountNumber | Yes | String
| |
payer.bank.routingNumber | Yes | Refer to your financial institution of choice for the correct routingNumber for said institution | |
payer.bank.swiftBic |
| String | 64 (Max) |
payer.bank.bankInstitutionNumber |
| String | |
payer.bank.bic |
| String | 64 (Max) |
payer.bank.iban |
| String | 34 (Max) |
amount.number | Yes | BigDecimal | |
amount.currency | Yes | Currency Code (ISO 4217) | 3 |
fundingMethod.id | Yes | Long (Bank ID of payer) | |
fundingMethod.type | Yes |
| |
goodFundsPayment | No | Boolean | |
accountId | No | Number |
Partner Notes:
- If
sweepToWalletIdis present we are moving the funds to the specified wallet ID. If it is not present we try to find the credit default funding method. - A partner account can be configured to make this API request on behalf of their customers. This requires internal configuration for the partner account by Veem. Once the internal configuration is enabled, the API request can be made using partner account bearer token.
accountIdis an optional parameter, this needs to be included on the request body in case of partner making an API request on behalf of their customer. This is the customer Veem accountId.
Response payload
{
"id": 456351,
"status": "Sent",
"exchangeRate": {
"fromAmount": 100.00,
"fromCurrency": "USD",
"toAmount": 98.50,
"toCurrency": "USD"
},
"claimLink": "https://apps.qa.veem.com/CustomerApp/Dashboard/Claim/Request/PaymentC?paymentId=456351-Invoice",
"invoiceExtraInfo": {
"customInfo": {
"custom1": "test"
}
},
"payeeAccountId": 944208,
"payerAccountId": 945266,
"payer": {
"email": "[email protected]",
"countryCode": "US",
"phoneCountryCodeIfPhoneOrElseSpace": " "
},
"goodFundsPayment": false,
"extraInfo": {
"customInfo": {
"custom1": "test"
}
},
"amount": {
"number": 100.00,
"currency": "USD"
},
"notes": "Invoice test",
"requestId": "48855846-628d-4177-b071-80332a116f0a",
"sweepToWalletId": 51244,
}Updated 7 days ago
