Q:
While requesting:
POST corporate/v2/payments
using DOMETSIC_KID_TRANSFER_NO template_id, all payments sent to the bank by our PSU (Payment Service User) are rejected with the following error message:
"http_code":400},"error":{"request":{"url":"/v2/payments"},"failures":[{"code":"error.validation","description":"must not be null","path":"paymentInstruction.creditor.address.line1","type":"NotNull"}]}
Why is that?
A:
The error occurs as you provide creditor.address field without "line1". If the creditor.address is provided (it's optional), then it needs to include "line1" field.
Refer to:
Initiate payment (Corporate Payout API)
Note: you may also consider omitting the whole "address" field in the request if you are not sure what to provide there, as it's optional in the template_id: DOMETSIC_KID_TRANSFER_NO.