Front-end Order Creation
Checkout Session Confirm
Changed onPurpose
Confirms the creation of an authorization where the buyer gave consent to the purchase and was accepted by Billie.
Preconditions:
- Session id of the Session Create Call
- Request body created with the response values received in the widget.
Success
- Response Code: HTTP 202
- response body: state -> created
- response body: uuid -> ID of the created order
Attention
- The duration and the objects delivery_address and amount you can copy from the widget response to the new request object.
- The amount must be the same as submitted via the widget.
- The debtor_company object from the widget response needs to be rebuilt to an object hierarchy debtor with company_address
put/checkout-sessions/{sessionId}/confirm
Request
- Base URLhttps://paella-sandbox.billie.io/api/v2
- AuthOAuth 2PasswordToken URL/oauth/token
- TypeScriptA function with typed inputs. Its response is checked against the schema.
Path parameters
sessionIdstring uuid required
Example:12345667-890a-bcde-f123-34567890abcd
Request body
Example request
{
"amount": {
"gross": 260.27,
"tax": 60.15,
"net": 200.12
},
"debtor": {
"name": "Billie GmbH",
"company_address": {
"street": "Charlottenstr. 4",
"house_number": "4",
"city": "Berlin",
"postal_code": "10969",
"country": "DE"
}
},
"delivery_address": {
"street": "Charlottenstr. 4",
"house_number": "4",
"city": "Berlin",
"postal_code": "10969",
"country": "DE"
},
"external_code": "DE123456-1"
}Response
Order data successfully confirmed
Example response
{
"external_code": "C-10123456789-0001",
"uuid": "12345667-890a-bcde-f123-34567890abcd",
"state": "created",
"decline_reason": "debtor_not_identified",
"amount": {
"gross": 260.27,
"net": 200.12,
"tax": 60.15
},
"unshipped_amount": {
"gross": 260.27,
"net": 200.12,
"tax": 60.15
},
"duration": 30,
"created_at": "2019-01-20 14:00:00",
"delivery_address": {
"country": "DE"
},
"debtor": {
"name": "C-10123456789-0001",
"company_address": {
"country": "DE"
},
"billing_address": {
"country": "DE"
},
"external_data": {
"address": {
"country": "DE"
}
}
},
"invoices": [
{
"uuid": "12345667-890a-bcde-f123-34567890abcd",
"due_date": "2019-03-20",
"created_at": "2019-03-20"
}
],
"selected_payment_method": "bank_transfer",
"payment_methods": [
{
"type": "bank_transfer",
"data": {
"mandate_execution_date": "2019-01-20 14:00:00"
}
}
]
}Changes
- info
endpoint added
- info