Qr Bill
Return a Swiss QR code as an image
POST /qr-code
Generate a QR code image from the payment information
Request
Fields
Field |
Type |
Description |
Required |
creditor |
object |
Field |
Type |
Description |
Required |
name |
string |
Full name of beneficiary |
YES |
addressLine1 |
string |
Street and building number or P.O. Box |
NO |
addressLine2 |
string |
Postal code and town |
YES |
country |
string |
ISO 3166-1 alpha-2 code, default: CH |
NO |
|
YES |
currency |
string |
the currency code (default: CHF) |
NO |
amount |
string |
What amount is to be paid (string representation of decimal using "." as delimiter) |
NO |
customerIdentification |
string |
You receive this number from your bank (BESR-ID). Unless your bank is PostFinance, in that case leave empty |
YES |
referenceNumber |
string |
This is what you will need to identify incoming payments (e.g. an invoice number) |
NO |
paymentMessage |
string |
Optional human-readable message that can be used to indicate the payment purpose, in addition to the reference number |
NO |
iban |
string |
Which bank account will receive the payment (IBAN or QR-IBAN) |
YES |
ultimateDebtor |
object |
Field |
Type |
Description |
Required |
name |
string |
Full name of debtor |
YES |
addressLine1 |
string |
Street and building number or P.O. Box |
NO |
addressLine2 |
string |
Postal code and town |
YES |
country |
string |
ISO 3166-1 alpha-2 code, default: CH |
NO |
|
NO |
paymentPart |
boolean |
If true or 1 , and asking for image/png , then the PNG image will include the payment part. Otherwise, the PNG image will only include the QR code. |
NO |
Headers
Header |
Value |
Content-Type |
application/json
|
Accept |
application/pdf will return the whole printable payment part
-
image/png will only return QR code by default, but might return the whole printable payment part if
paymentPart is specified
image/svg+xml will only return the QR code
-
application/json can be combined with one image format. Image format will fall back on PNG
|
Response
Status Codes
Headers
Header |
Value |
Content-Type |
success is application/json , image/svg+xml ,
image/png or application/pdf , failure is
application/json
|