Get dynamic checkout form for order checkout
curl --request GET \
--url https://b.anny.co/api/ui/checkout-formimport requests
url = "https://b.anny.co/api/ui/checkout-form"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://b.anny.co/api/ui/checkout-form', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://b.anny.co/api/ui/checkout-form",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://b.anny.co/api/ui/checkout-form"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://b.anny.co/api/ui/checkout-form")
.asString();require 'uri'
require 'net/http'
url = URI("https://b.anny.co/api/ui/checkout-form")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body{
"sections": [
{
"id": "customer",
"title": "Customer",
"fields": [
{
"id": "email",
"type": "email",
"label": "Email",
"required": true
},
{
"id": "first_name",
"type": "text",
"label": "First name",
"required": true
}
]
},
{
"id": "legal",
"title": "Legal",
"fields": [
{
"id": "legal_document_acceptances",
"type": "checkbox-group",
"label": "Agreements",
"required": true
}
]
}
],
"values": {
"email": "jane@example.com",
"first_name": "Jane"
},
"meta": {
"order_id": 12345,
"payment_methods": [
{
"slug": "card",
"label": "Credit card"
}
]
}
}Internal UI
Get dynamic checkout form for order checkout
Returns dynamic checkout field definitions and validation metadata. Supports prefill via remember customer token (rct).
GET
/
api
/
ui
/
checkout-form
Get dynamic checkout form for order checkout
curl --request GET \
--url https://b.anny.co/api/ui/checkout-formimport requests
url = "https://b.anny.co/api/ui/checkout-form"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://b.anny.co/api/ui/checkout-form', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://b.anny.co/api/ui/checkout-form",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://b.anny.co/api/ui/checkout-form"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://b.anny.co/api/ui/checkout-form")
.asString();require 'uri'
require 'net/http'
url = URI("https://b.anny.co/api/ui/checkout-form")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body{
"sections": [
{
"id": "customer",
"title": "Customer",
"fields": [
{
"id": "email",
"type": "email",
"label": "Email",
"required": true
},
{
"id": "first_name",
"type": "text",
"label": "First name",
"required": true
}
]
},
{
"id": "legal",
"title": "Legal",
"fields": [
{
"id": "legal_document_acceptances",
"type": "checkbox-group",
"label": "Agreements",
"required": true
}
]
}
],
"values": {
"email": "jane@example.com",
"first_name": "Jane"
},
"meta": {
"order_id": 12345,
"payment_methods": [
{
"slug": "card",
"label": "Credit card"
}
]
}
}Abfrageparameter
Order id. Required unless bookings[] is provided.
Order access token. Required unless bookings[] is provided.
Reserved booking ids to build a checkout form without oid/oat.
Remember customer token used to prefill returned form values.
⌘I