Transfer API

Transfer funds between your currency accounts.

Request

Authorization: {your_credentials}
Content-Type: application/vnd.worldpay.accounts.transfer-v1+json

POST https://try.access.worldpay.com/accounts/transfer/

Request example

{
"sourceAccountNumber":"0000550000000001",
"targetAccountNumber":"0000550000000002",
"amount":123.45,
"narrative":"CurrencyTransfer12",
"quoteID":"Q0000000BV"
}

Mandatory parameters

Field NameDescriptionData Type/FormatMin-Max LengthValidation Criteria
sourceAccountNumberSource Account Number from where the funds will be taken from. The first 6 characters indicate the domainID of the merchant. The rest determines the specific account number.String16-16Alphanumeric only. Special characters are restricted.
targetAccountNumberTarget Account Number to which the funds will be transferred. The first 6 characters indicate the domainID of the merchant. The rest determines the specific account number.String16-16Alphanumeric only. Special characters are restricted.
amountNumeric only (must be grater than 0). Use dot (.) as decimal point. Up to 7 digits before decimal point and up to 2 decimal places.
narrativeA unique value supplied by your customer for the transfer. Must be unique for the domain the source account belongs to.String6-34Alphanumeric only. Special characters allowed: List of allowed special chars: ** |+=%!£$^&*()-_<>@[]~#:;',.?/¬`\ Only double backslash is allowed. Spaces are allowed.

Optional parameter

Field NameDescriptionData Type/FormatMin-Max LengthValidation Criteria
quoteIdA value that represents a unique FX quote that is pre-lodged with the treasury.String1-50Alphanumeric only. NO special characters.

Response

Successful response fields

Body of the response

There is no body for a successful response. Only HTTP status 202 will be returned.

Error response examples

Example 1:

{

    "validationErrors": [

        {

            "errorName": "fieldHasInvalidValue",

            "message": "Source account number must be 16 characters",

            "jsonPath": "$.SourceAccountNumber"

        }

    ],

    "errorName": "bodyDoesNotMatchSchema",

    "message": "The json body provided does not match the expected schema"

}

Example 2:

{

    "errorName": "FieldHasInvalidValue",

    "message": "Amount to transfer cannot be greater than the remaining balance of -0.54 GBP"

}

Error response codes

ScenarioHTTP codeCustom codeError nameError messageComments/Help/Examples
JWT not present, or invalid401TRAU06"unauthorizedRequest"The request is unauthorized
Authorization Failed - incorrect or no domain entitlements403TRAF18"Forbidden"
JWT entitlements incorrect403TRAF18"Forbidden"
sourceAccount is child to targetAccount403TRAF18"Forbidden"
Account resource not found404TRAN15"notFound"
Account number not found404TRAN15"Could not find details for accountNumber"
Correlation ID not valid400TAP01"headerHasInvalidValue""WP-CorrelationId must be a GUID"
Caller ID invalid400TAP01"headerHasInvalidValue""WP-CallerId must contain only alphanumeric, dot (.) and hyphen (-) characters"
Source account number not present400TRAB05"Schema validation failed""Source account number is mandatory"
Target account number not present400TRAB05"Schema validation failed""Target account number is mandatory"
Source account number more or less than 16 chars400TRAB05"Schema validation failed""Source account number must be 16 characters"
Target account number more or less of 16 chars400TRAB05"Schema validation failed""Target account number must be 16 characters"
Narrative not present400TRAB05"Schema validation failed""Narrative is mandatory"
Narrative less than 6 or more than 34400TRAB05"Schema validation failed""Narrative must be at least 6 and no more than 34 characters"
Amount not present400TRAB05"Schema validation failed""Empty value for amount"
Amount is invalid - not numerical400TRAB05"Schema validation failed""Invalid value for amount. It should be numerical"
Amount is invalid - more than 2 decimal places400TRAB05"Schema validation failed""Amount should have a maximum of 2 decimal places"
Amount is invalid - negative value or less than 1 digit400TRAB05"Schema validation failed""Amount should be grater than 0"
Account resource not found404TRAN15"not found""Resource not found"
Account number not found404TRAN15"not found""Could not find details for accountNumber {accountNumber}"
A downstream service is down500TRAE11"internalErrorOccurred""Something went wrong"
Balance in source account is less than the value in amount field of the request402TRAU08"FiledHasInvalidValue""Amount to transfer cannot be grater than the remaining balance of {clearedBalance} {currency}""Amount to transfer cannot be grater than the remaining balance of 1258.25 USD"
EPACS - 409 idempotency409TRAX12"Duplicate Entry""Duplicate request detected: Narrative - {narrative}""Duplicate request detected: Narrative - CurrencyTransfer12"