Here you find information on the validations that occur throughout the payment process.
Different data validations occur in the three steps of the payment process:
When initiating a payment, the Klarna payments API uses the request payload to validate the attributes of the created session. We validate that:
locale
and purchase_country
are alignedtax
is aligned to the standards in the Handle tax articleWhen updating the cart, the Klarna payments API takes any updated data as a new session to validate.
When getting the authorization, the authorize()
call triggers a risk and fraud assessment on Klarna’s side.
In this step, we check that the address fulfills all country standards and exists in the records of that specific country. If this information is broken, the validation fails.
If any address field - in either billing or shipping - is incorrect, you get an error message specifying what field is failing.
When creating an order, we validate the data against the most recent purchase and customer information you send us. This applies to both scenarios, recurring and one-time payments.
By considering the last payload you send, we ensure that both yours and our side keep the most updated data. We validate the following:
If the data shared when creating an order matches the data shared when getting authorization and no other details have been added in between, the validation is successful.
If you share customer details up until creating an order but not when getting authorization, an empty payload matches the customer data you are sending, and the validation is successful.