Update event registration guest details
The secret order token authorizes changes when magic-link management is enabled. Cancelled/refunded/expired registrations cannot be edited. V2 requires the current version or returns 409 with current_version. Only guests, groups and sponsors on this order are mutable; applicable active question types/options are validated and blank answers removed. Sponsor logo upload must belong to the organization; supplied contact nulls clear values. Group completeness and ticket readiness are recalculated.
curl --request PUT \
--url https://api.gratona.com/v1/frontend/public/events/{clientSlugOrId}/{eventSlug}/orders/{token} \
--header 'Content-Type: application/json' \
--data '
{
"version": "sha256:aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
"groups": [
{
"id": 42,
"label": "Doe family",
"answers": [
{
"answer": "Vegetarian",
"question_id": 42,
"field_key": "dietary"
}
]
}
],
"attendees": [
{
"id": 42,
"first_name": "Jane",
"last_name": "Doe",
"email": "jane@example.org",
"phone": "+12565550123",
"answers": [
{
"answer": "Vegetarian",
"question_id": 42,
"field_key": "dietary"
}
]
}
],
"sponsors": [
{
"id": 42,
"company_name": "Example",
"contact_name": "Example",
"contact_email": "Example",
"contact_phone": "Example",
"public_visibility": false,
"notes": "Example",
"renewal_follow_up_requested": false,
"renewal_follow_up_at": "2026-10-20T12:00:00Z",
"logo_upload_id": 42,
"logo_upload_key": "logos/example.png",
"logo_file_name": "example.png"
}
]
}
'import requests
url = "https://api.gratona.com/v1/frontend/public/events/{clientSlugOrId}/{eventSlug}/orders/{token}"
payload = {
"version": "sha256:aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
"groups": [
{
"id": 42,
"label": "Doe family",
"answers": [
{
"answer": "Vegetarian",
"question_id": 42,
"field_key": "dietary"
}
]
}
],
"attendees": [
{
"id": 42,
"first_name": "Jane",
"last_name": "Doe",
"email": "jane@example.org",
"phone": "+12565550123",
"answers": [
{
"answer": "Vegetarian",
"question_id": 42,
"field_key": "dietary"
}
]
}
],
"sponsors": [
{
"id": 42,
"company_name": "Example",
"contact_name": "Example",
"contact_email": "Example",
"contact_phone": "Example",
"public_visibility": False,
"notes": "Example",
"renewal_follow_up_requested": False,
"renewal_follow_up_at": "2026-10-20T12:00:00Z",
"logo_upload_id": 42,
"logo_upload_key": "logos/example.png",
"logo_file_name": "example.png"
}
]
}
headers = {"Content-Type": "application/json"}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({
version: 'sha256:aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa',
groups: [
{
id: 42,
label: 'Doe family',
answers: [{answer: 'Vegetarian', question_id: 42, field_key: 'dietary'}]
}
],
attendees: [
{
id: 42,
first_name: 'Jane',
last_name: 'Doe',
email: 'jane@example.org',
phone: '+12565550123',
answers: [{answer: 'Vegetarian', question_id: 42, field_key: 'dietary'}]
}
],
sponsors: [
{
id: 42,
company_name: 'Example',
contact_name: 'Example',
contact_email: 'Example',
contact_phone: 'Example',
public_visibility: false,
notes: 'Example',
renewal_follow_up_requested: false,
renewal_follow_up_at: '2026-10-20T12:00:00Z',
logo_upload_id: 42,
logo_upload_key: 'logos/example.png',
logo_file_name: 'example.png'
}
]
})
};
fetch('https://api.gratona.com/v1/frontend/public/events/{clientSlugOrId}/{eventSlug}/orders/{token}', 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://api.gratona.com/v1/frontend/public/events/{clientSlugOrId}/{eventSlug}/orders/{token}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_POSTFIELDS => json_encode([
'version' => 'sha256:aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa',
'groups' => [
[
'id' => 42,
'label' => 'Doe family',
'answers' => [
[
'answer' => 'Vegetarian',
'question_id' => 42,
'field_key' => 'dietary'
]
]
]
],
'attendees' => [
[
'id' => 42,
'first_name' => 'Jane',
'last_name' => 'Doe',
'email' => 'jane@example.org',
'phone' => '+12565550123',
'answers' => [
[
'answer' => 'Vegetarian',
'question_id' => 42,
'field_key' => 'dietary'
]
]
]
],
'sponsors' => [
[
'id' => 42,
'company_name' => 'Example',
'contact_name' => 'Example',
'contact_email' => 'Example',
'contact_phone' => 'Example',
'public_visibility' => false,
'notes' => 'Example',
'renewal_follow_up_requested' => false,
'renewal_follow_up_at' => '2026-10-20T12:00:00Z',
'logo_upload_id' => 42,
'logo_upload_key' => 'logos/example.png',
'logo_file_name' => 'example.png'
]
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.gratona.com/v1/frontend/public/events/{clientSlugOrId}/{eventSlug}/orders/{token}"
payload := strings.NewReader("{\n \"version\": \"sha256:aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\n \"groups\": [\n {\n \"id\": 42,\n \"label\": \"Doe family\",\n \"answers\": [\n {\n \"answer\": \"Vegetarian\",\n \"question_id\": 42,\n \"field_key\": \"dietary\"\n }\n ]\n }\n ],\n \"attendees\": [\n {\n \"id\": 42,\n \"first_name\": \"Jane\",\n \"last_name\": \"Doe\",\n \"email\": \"jane@example.org\",\n \"phone\": \"+12565550123\",\n \"answers\": [\n {\n \"answer\": \"Vegetarian\",\n \"question_id\": 42,\n \"field_key\": \"dietary\"\n }\n ]\n }\n ],\n \"sponsors\": [\n {\n \"id\": 42,\n \"company_name\": \"Example\",\n \"contact_name\": \"Example\",\n \"contact_email\": \"Example\",\n \"contact_phone\": \"Example\",\n \"public_visibility\": false,\n \"notes\": \"Example\",\n \"renewal_follow_up_requested\": false,\n \"renewal_follow_up_at\": \"2026-10-20T12:00:00Z\",\n \"logo_upload_id\": 42,\n \"logo_upload_key\": \"logos/example.png\",\n \"logo_file_name\": \"example.png\"\n }\n ]\n}")
req, _ := http.NewRequest("PUT", url, payload)
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.put("https://api.gratona.com/v1/frontend/public/events/{clientSlugOrId}/{eventSlug}/orders/{token}")
.header("Content-Type", "application/json")
.body("{\n \"version\": \"sha256:aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\n \"groups\": [\n {\n \"id\": 42,\n \"label\": \"Doe family\",\n \"answers\": [\n {\n \"answer\": \"Vegetarian\",\n \"question_id\": 42,\n \"field_key\": \"dietary\"\n }\n ]\n }\n ],\n \"attendees\": [\n {\n \"id\": 42,\n \"first_name\": \"Jane\",\n \"last_name\": \"Doe\",\n \"email\": \"jane@example.org\",\n \"phone\": \"+12565550123\",\n \"answers\": [\n {\n \"answer\": \"Vegetarian\",\n \"question_id\": 42,\n \"field_key\": \"dietary\"\n }\n ]\n }\n ],\n \"sponsors\": [\n {\n \"id\": 42,\n \"company_name\": \"Example\",\n \"contact_name\": \"Example\",\n \"contact_email\": \"Example\",\n \"contact_phone\": \"Example\",\n \"public_visibility\": false,\n \"notes\": \"Example\",\n \"renewal_follow_up_requested\": false,\n \"renewal_follow_up_at\": \"2026-10-20T12:00:00Z\",\n \"logo_upload_id\": 42,\n \"logo_upload_key\": \"logos/example.png\",\n \"logo_file_name\": \"example.png\"\n }\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.gratona.com/v1/frontend/public/events/{clientSlugOrId}/{eventSlug}/orders/{token}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"version\": \"sha256:aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\n \"groups\": [\n {\n \"id\": 42,\n \"label\": \"Doe family\",\n \"answers\": [\n {\n \"answer\": \"Vegetarian\",\n \"question_id\": 42,\n \"field_key\": \"dietary\"\n }\n ]\n }\n ],\n \"attendees\": [\n {\n \"id\": 42,\n \"first_name\": \"Jane\",\n \"last_name\": \"Doe\",\n \"email\": \"jane@example.org\",\n \"phone\": \"+12565550123\",\n \"answers\": [\n {\n \"answer\": \"Vegetarian\",\n \"question_id\": 42,\n \"field_key\": \"dietary\"\n }\n ]\n }\n ],\n \"sponsors\": [\n {\n \"id\": 42,\n \"company_name\": \"Example\",\n \"contact_name\": \"Example\",\n \"contact_email\": \"Example\",\n \"contact_phone\": \"Example\",\n \"public_visibility\": false,\n \"notes\": \"Example\",\n \"renewal_follow_up_requested\": false,\n \"renewal_follow_up_at\": \"2026-10-20T12:00:00Z\",\n \"logo_upload_id\": 42,\n \"logo_upload_key\": \"logos/example.png\",\n \"logo_file_name\": \"example.png\"\n }\n ]\n}"
response = http.request(request)
puts response.read_body{
"data": {
"id": 42,
"order_number": "EVT-42-001",
"status": "completed",
"payment_status": "paid",
"payment_method": "Example",
"payment_instructions": "Example",
"gateway": "Example",
"payment_intent_id": "Example",
"subtotal_amount": 25,
"discount_amount": 25,
"donation_amount": 25,
"fees_covered_amount": 25,
"tax_deductible_amount": 25,
"non_deductible_amount": 25,
"total_amount": 25,
"currency": "USD",
"purchaser_name": "Example",
"purchaser_email": "Example",
"version": "sha256:aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
"reservation_expires_at": "2026-10-20T12:00:00Z",
"quote_fingerprint": "Example",
"quote_snapshot": {
"quote_fingerprint": "sha256:1792497900:aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
"expires_at": "2026-10-20T12:00:00Z",
"currency": "USD",
"availability": {
"event_state": "open",
"admissions_requested": 42,
"admissions_remaining": 42
},
"lines": [
{
"source": "ticket",
"source_id": 42,
"label": "General admission",
"units": 42,
"admissions_per_unit": 42,
"admissions": 42,
"pre_reserved_units": 42,
"unit_amount": "25.00",
"fair_market_value": "25.00",
"subtotal": "25.00",
"discount": "25.00",
"total": "25.00",
"non_deductible": "25.00",
"snapshot": {
"name": "General admission",
"code": "Example",
"tier": "Example",
"registration_group_kind": "individual",
"group_label_prompt": "Example",
"attendee_details_timing": "checkout",
"admissions_per_unit": 42,
"unit_amount": "25.00",
"fair_market_value": "25.00"
}
}
],
"promo_code_id": 42,
"promo_code": "Example",
"subtotal": "25.00",
"discount": "25.00",
"fee_coverage": "25.00",
"donation": "25.00",
"tax_deductible": "25.00",
"non_deductible": "25.00",
"total": "25.00",
"attendee_slots": 42
},
"line_items": [
{
"type": "ticket",
"label": "General admission",
"ticket_type_id": 42,
"sponsor_package_id": 42,
"auction_item_id": 42,
"auction_bid_id": 42,
"quantity": 42,
"unit_amount": 25,
"line_total": 25,
"fair_market_total": 25,
"discount": 25,
"admissions_per_unit": 42,
"admissions": 42,
"source_snapshot": {
"name": "General admission",
"code": "Example",
"tier": "Example",
"registration_group_kind": "individual",
"group_label_prompt": "Example",
"attendee_details_timing": "checkout",
"admissions_per_unit": 42,
"unit_amount": "25.00",
"fair_market_value": "25.00"
}
}
],
"metadata": {
"registration_version": 42,
"conversion_intents": {
"recurring_gift": false,
"child_sponsorship": false
},
"sponsorship_interest": {
"program_id": 42,
"recipient_id": 42,
"recipient_label": "Alex",
"url": "/frontend/view_entity/42/7/9"
}
},
"receipt_snapshot": {
"receipt_type": "event_combined_receipt",
"event_id": 42,
"event_name": "Annual Gala",
"order_number": "EVT-42-001",
"donation_id": 42,
"currency": "USD",
"subtotal_amount": 25,
"discount_amount": 25,
"fees_covered_amount": 25,
"total_amount": 25,
"tax_deductible_amount": 25,
"non_deductible_amount": 25,
"donation_amount": 25,
"payment_method": "Example",
"payment_status": "paid",
"payment_instructions": "Example",
"line_items": [
{
"type": "ticket",
"label": "General admission",
"ticket_type_id": 42,
"sponsor_package_id": 42,
"auction_item_id": 42,
"auction_bid_id": 42,
"quantity": 42,
"unit_amount": 25,
"line_total": 25,
"fair_market_total": 25,
"discount": 25,
"admissions_per_unit": 42,
"admissions": 42,
"source_snapshot": {
"name": "General admission",
"code": "Example",
"tier": "Example",
"registration_group_kind": "individual",
"group_label_prompt": "Example",
"attendee_details_timing": "checkout",
"admissions_per_unit": 42,
"unit_amount": "25.00",
"fair_market_value": "25.00"
}
}
],
"issued_at": "2026-10-20T12:00:00Z",
"receipt_note": "Ticket fair market value is separated from deductible event support.",
"adjustment_type": "refund",
"refunded_amount": 25,
"active_total_amount": 25,
"active_tax_deductible_amount": 25,
"adjustment_reason": "Example",
"adjusted_at": "2026-10-20T12:00:00Z"
},
"receipt_sent_at": "2026-10-20T12:00:00Z",
"registration_questions": [
{
"field_key": "dietary",
"field_label": "Dietary requirements",
"field_type": "text",
"options": [
"Vegetarian"
],
"scope": "buyer",
"required": false,
"id": 42,
"help_text": "Example",
"applies_to_ticket_type_ids": [
42
]
}
],
"event": {
"id": 42,
"branding_program_id": 42,
"name": "Annual Gala",
"slug": "annual-gala",
"starts_at": "2026-10-20T12:00:00Z",
"timezone": "Africa/Kampala",
"location": {
"mode": "released_full",
"label": "Kampala",
"venue": "Example",
"address": "Example",
"map_allowed": false
}
},
"registration_groups": [
{
"id": 42,
"source_kind": "ticket",
"source_id": 42,
"event_ticket_type_id": 42,
"kind": "individual",
"label": "Example",
"admissions_reserved": 42,
"attendee_details_timing": "checkout",
"status": "complete",
"source_snapshot": {
"name": "General admission",
"code": "Example",
"tier": "Example",
"registration_group_kind": "individual",
"group_label_prompt": "Example",
"attendee_details_timing": "checkout",
"admissions_per_unit": 42,
"unit_amount": "25.00",
"fair_market_value": "25.00"
},
"details_completed_at": "2026-10-20T12:00:00Z",
"answers": [
{
"id": 42,
"question_id": 42,
"question": {
"field_key": "dietary",
"field_label": "Dietary requirements",
"field_type": "text",
"options": [
"Vegetarian"
],
"scope": "buyer",
"required": false
},
"answer": "Vegetarian"
}
],
"attendee_ids": [
42
]
}
],
"attendees": [
{
"id": 42,
"event_registration_group_id": 42,
"event_ticket_type_id": 42,
"ticket_code": "EVT-42-00001",
"name": "Jane Doe",
"first_name": "Example",
"last_name": "Example",
"email": "Example",
"ticket_type": "Example",
"table": "Example",
"status": "registered",
"qr_token": "<string>",
"details_completed_at": "2026-10-20T12:00:00Z",
"qr_url": "Example",
"wallet_pass_url": "Example",
"wallet_pass_status": "inactive",
"checked_in_at": "2026-10-20T12:00:00Z",
"answers": [
{
"id": 42,
"question_id": 42,
"question": {
"field_key": "dietary",
"field_label": "Dietary requirements",
"field_type": "text",
"options": [
"Vegetarian"
],
"scope": "buyer",
"required": false
},
"answer": "Vegetarian"
}
],
"metadata": {
"source": "Example",
"event_sponsor_id": 42,
"sponsor_ticket_slot": 42
}
}
],
"sponsors": [
{
"id": 42,
"company_name": "Example",
"contact_name": "Example",
"contact_email": "Example",
"contact_phone": "Example",
"notes": "Example",
"status": "active",
"amount": 25,
"fair_market_value": 25,
"included_tickets_assigned": 42,
"public_visibility": false,
"renewal_follow_up_at": "2026-10-20T12:00:00Z",
"logo_upload_id": 42,
"logo_url": "Example",
"package": {
"id": 42,
"name": "Example",
"tier": "Example",
"included_tickets": 42,
"included_tables": 42
},
"deliverables": [
{
"id": 42,
"type": "logo",
"label": "Logo placement",
"status": "pending",
"due_at": "2026-10-20T12:00:00Z",
"completed_at": "2026-10-20T12:00:00Z"
}
]
}
],
"auction_items": [
{
"id": 42,
"event_auction_item_id": 42,
"name": "Example",
"amount": 25,
"quantity": 42,
"status": "paid",
"bidder_name": "Example",
"bidder_email": "Example"
}
],
"payment_reconciliation_required": false,
"payment_provider_status": "Example"
}
}{
"message": "Not Found",
"status": "error"
}{
"message": "Registration changed; reload the current version.",
"error_code": "invalid_reference",
"details": {}
}{
"errors": {},
"status": "error",
"message": "The given data was invalid."
}{
"message": "Something went wrong. Please try again.",
"status": "error",
"error": "invalid_request",
"code": "DONOR_NOT_FOUND"
}Path Parameters
Public organization slug or numeric ID.
"example-foundation"
Event slug within the organization.
"annual-gala"
Secret order management capability.
"issued-order-token"
Body
Required current management version for V2; obtain from GET order.
96"sha256:aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa"
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Response
Update event registration guest details completed.
Show child attributes
Show child attributes
curl --request PUT \
--url https://api.gratona.com/v1/frontend/public/events/{clientSlugOrId}/{eventSlug}/orders/{token} \
--header 'Content-Type: application/json' \
--data '
{
"version": "sha256:aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
"groups": [
{
"id": 42,
"label": "Doe family",
"answers": [
{
"answer": "Vegetarian",
"question_id": 42,
"field_key": "dietary"
}
]
}
],
"attendees": [
{
"id": 42,
"first_name": "Jane",
"last_name": "Doe",
"email": "jane@example.org",
"phone": "+12565550123",
"answers": [
{
"answer": "Vegetarian",
"question_id": 42,
"field_key": "dietary"
}
]
}
],
"sponsors": [
{
"id": 42,
"company_name": "Example",
"contact_name": "Example",
"contact_email": "Example",
"contact_phone": "Example",
"public_visibility": false,
"notes": "Example",
"renewal_follow_up_requested": false,
"renewal_follow_up_at": "2026-10-20T12:00:00Z",
"logo_upload_id": 42,
"logo_upload_key": "logos/example.png",
"logo_file_name": "example.png"
}
]
}
'import requests
url = "https://api.gratona.com/v1/frontend/public/events/{clientSlugOrId}/{eventSlug}/orders/{token}"
payload = {
"version": "sha256:aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
"groups": [
{
"id": 42,
"label": "Doe family",
"answers": [
{
"answer": "Vegetarian",
"question_id": 42,
"field_key": "dietary"
}
]
}
],
"attendees": [
{
"id": 42,
"first_name": "Jane",
"last_name": "Doe",
"email": "jane@example.org",
"phone": "+12565550123",
"answers": [
{
"answer": "Vegetarian",
"question_id": 42,
"field_key": "dietary"
}
]
}
],
"sponsors": [
{
"id": 42,
"company_name": "Example",
"contact_name": "Example",
"contact_email": "Example",
"contact_phone": "Example",
"public_visibility": False,
"notes": "Example",
"renewal_follow_up_requested": False,
"renewal_follow_up_at": "2026-10-20T12:00:00Z",
"logo_upload_id": 42,
"logo_upload_key": "logos/example.png",
"logo_file_name": "example.png"
}
]
}
headers = {"Content-Type": "application/json"}
response = requests.put(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({
version: 'sha256:aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa',
groups: [
{
id: 42,
label: 'Doe family',
answers: [{answer: 'Vegetarian', question_id: 42, field_key: 'dietary'}]
}
],
attendees: [
{
id: 42,
first_name: 'Jane',
last_name: 'Doe',
email: 'jane@example.org',
phone: '+12565550123',
answers: [{answer: 'Vegetarian', question_id: 42, field_key: 'dietary'}]
}
],
sponsors: [
{
id: 42,
company_name: 'Example',
contact_name: 'Example',
contact_email: 'Example',
contact_phone: 'Example',
public_visibility: false,
notes: 'Example',
renewal_follow_up_requested: false,
renewal_follow_up_at: '2026-10-20T12:00:00Z',
logo_upload_id: 42,
logo_upload_key: 'logos/example.png',
logo_file_name: 'example.png'
}
]
})
};
fetch('https://api.gratona.com/v1/frontend/public/events/{clientSlugOrId}/{eventSlug}/orders/{token}', 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://api.gratona.com/v1/frontend/public/events/{clientSlugOrId}/{eventSlug}/orders/{token}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_POSTFIELDS => json_encode([
'version' => 'sha256:aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa',
'groups' => [
[
'id' => 42,
'label' => 'Doe family',
'answers' => [
[
'answer' => 'Vegetarian',
'question_id' => 42,
'field_key' => 'dietary'
]
]
]
],
'attendees' => [
[
'id' => 42,
'first_name' => 'Jane',
'last_name' => 'Doe',
'email' => 'jane@example.org',
'phone' => '+12565550123',
'answers' => [
[
'answer' => 'Vegetarian',
'question_id' => 42,
'field_key' => 'dietary'
]
]
]
],
'sponsors' => [
[
'id' => 42,
'company_name' => 'Example',
'contact_name' => 'Example',
'contact_email' => 'Example',
'contact_phone' => 'Example',
'public_visibility' => false,
'notes' => 'Example',
'renewal_follow_up_requested' => false,
'renewal_follow_up_at' => '2026-10-20T12:00:00Z',
'logo_upload_id' => 42,
'logo_upload_key' => 'logos/example.png',
'logo_file_name' => 'example.png'
]
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.gratona.com/v1/frontend/public/events/{clientSlugOrId}/{eventSlug}/orders/{token}"
payload := strings.NewReader("{\n \"version\": \"sha256:aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\n \"groups\": [\n {\n \"id\": 42,\n \"label\": \"Doe family\",\n \"answers\": [\n {\n \"answer\": \"Vegetarian\",\n \"question_id\": 42,\n \"field_key\": \"dietary\"\n }\n ]\n }\n ],\n \"attendees\": [\n {\n \"id\": 42,\n \"first_name\": \"Jane\",\n \"last_name\": \"Doe\",\n \"email\": \"jane@example.org\",\n \"phone\": \"+12565550123\",\n \"answers\": [\n {\n \"answer\": \"Vegetarian\",\n \"question_id\": 42,\n \"field_key\": \"dietary\"\n }\n ]\n }\n ],\n \"sponsors\": [\n {\n \"id\": 42,\n \"company_name\": \"Example\",\n \"contact_name\": \"Example\",\n \"contact_email\": \"Example\",\n \"contact_phone\": \"Example\",\n \"public_visibility\": false,\n \"notes\": \"Example\",\n \"renewal_follow_up_requested\": false,\n \"renewal_follow_up_at\": \"2026-10-20T12:00:00Z\",\n \"logo_upload_id\": 42,\n \"logo_upload_key\": \"logos/example.png\",\n \"logo_file_name\": \"example.png\"\n }\n ]\n}")
req, _ := http.NewRequest("PUT", url, payload)
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.put("https://api.gratona.com/v1/frontend/public/events/{clientSlugOrId}/{eventSlug}/orders/{token}")
.header("Content-Type", "application/json")
.body("{\n \"version\": \"sha256:aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\n \"groups\": [\n {\n \"id\": 42,\n \"label\": \"Doe family\",\n \"answers\": [\n {\n \"answer\": \"Vegetarian\",\n \"question_id\": 42,\n \"field_key\": \"dietary\"\n }\n ]\n }\n ],\n \"attendees\": [\n {\n \"id\": 42,\n \"first_name\": \"Jane\",\n \"last_name\": \"Doe\",\n \"email\": \"jane@example.org\",\n \"phone\": \"+12565550123\",\n \"answers\": [\n {\n \"answer\": \"Vegetarian\",\n \"question_id\": 42,\n \"field_key\": \"dietary\"\n }\n ]\n }\n ],\n \"sponsors\": [\n {\n \"id\": 42,\n \"company_name\": \"Example\",\n \"contact_name\": \"Example\",\n \"contact_email\": \"Example\",\n \"contact_phone\": \"Example\",\n \"public_visibility\": false,\n \"notes\": \"Example\",\n \"renewal_follow_up_requested\": false,\n \"renewal_follow_up_at\": \"2026-10-20T12:00:00Z\",\n \"logo_upload_id\": 42,\n \"logo_upload_key\": \"logos/example.png\",\n \"logo_file_name\": \"example.png\"\n }\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.gratona.com/v1/frontend/public/events/{clientSlugOrId}/{eventSlug}/orders/{token}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"version\": \"sha256:aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa\",\n \"groups\": [\n {\n \"id\": 42,\n \"label\": \"Doe family\",\n \"answers\": [\n {\n \"answer\": \"Vegetarian\",\n \"question_id\": 42,\n \"field_key\": \"dietary\"\n }\n ]\n }\n ],\n \"attendees\": [\n {\n \"id\": 42,\n \"first_name\": \"Jane\",\n \"last_name\": \"Doe\",\n \"email\": \"jane@example.org\",\n \"phone\": \"+12565550123\",\n \"answers\": [\n {\n \"answer\": \"Vegetarian\",\n \"question_id\": 42,\n \"field_key\": \"dietary\"\n }\n ]\n }\n ],\n \"sponsors\": [\n {\n \"id\": 42,\n \"company_name\": \"Example\",\n \"contact_name\": \"Example\",\n \"contact_email\": \"Example\",\n \"contact_phone\": \"Example\",\n \"public_visibility\": false,\n \"notes\": \"Example\",\n \"renewal_follow_up_requested\": false,\n \"renewal_follow_up_at\": \"2026-10-20T12:00:00Z\",\n \"logo_upload_id\": 42,\n \"logo_upload_key\": \"logos/example.png\",\n \"logo_file_name\": \"example.png\"\n }\n ]\n}"
response = http.request(request)
puts response.read_body{
"data": {
"id": 42,
"order_number": "EVT-42-001",
"status": "completed",
"payment_status": "paid",
"payment_method": "Example",
"payment_instructions": "Example",
"gateway": "Example",
"payment_intent_id": "Example",
"subtotal_amount": 25,
"discount_amount": 25,
"donation_amount": 25,
"fees_covered_amount": 25,
"tax_deductible_amount": 25,
"non_deductible_amount": 25,
"total_amount": 25,
"currency": "USD",
"purchaser_name": "Example",
"purchaser_email": "Example",
"version": "sha256:aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
"reservation_expires_at": "2026-10-20T12:00:00Z",
"quote_fingerprint": "Example",
"quote_snapshot": {
"quote_fingerprint": "sha256:1792497900:aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
"expires_at": "2026-10-20T12:00:00Z",
"currency": "USD",
"availability": {
"event_state": "open",
"admissions_requested": 42,
"admissions_remaining": 42
},
"lines": [
{
"source": "ticket",
"source_id": 42,
"label": "General admission",
"units": 42,
"admissions_per_unit": 42,
"admissions": 42,
"pre_reserved_units": 42,
"unit_amount": "25.00",
"fair_market_value": "25.00",
"subtotal": "25.00",
"discount": "25.00",
"total": "25.00",
"non_deductible": "25.00",
"snapshot": {
"name": "General admission",
"code": "Example",
"tier": "Example",
"registration_group_kind": "individual",
"group_label_prompt": "Example",
"attendee_details_timing": "checkout",
"admissions_per_unit": 42,
"unit_amount": "25.00",
"fair_market_value": "25.00"
}
}
],
"promo_code_id": 42,
"promo_code": "Example",
"subtotal": "25.00",
"discount": "25.00",
"fee_coverage": "25.00",
"donation": "25.00",
"tax_deductible": "25.00",
"non_deductible": "25.00",
"total": "25.00",
"attendee_slots": 42
},
"line_items": [
{
"type": "ticket",
"label": "General admission",
"ticket_type_id": 42,
"sponsor_package_id": 42,
"auction_item_id": 42,
"auction_bid_id": 42,
"quantity": 42,
"unit_amount": 25,
"line_total": 25,
"fair_market_total": 25,
"discount": 25,
"admissions_per_unit": 42,
"admissions": 42,
"source_snapshot": {
"name": "General admission",
"code": "Example",
"tier": "Example",
"registration_group_kind": "individual",
"group_label_prompt": "Example",
"attendee_details_timing": "checkout",
"admissions_per_unit": 42,
"unit_amount": "25.00",
"fair_market_value": "25.00"
}
}
],
"metadata": {
"registration_version": 42,
"conversion_intents": {
"recurring_gift": false,
"child_sponsorship": false
},
"sponsorship_interest": {
"program_id": 42,
"recipient_id": 42,
"recipient_label": "Alex",
"url": "/frontend/view_entity/42/7/9"
}
},
"receipt_snapshot": {
"receipt_type": "event_combined_receipt",
"event_id": 42,
"event_name": "Annual Gala",
"order_number": "EVT-42-001",
"donation_id": 42,
"currency": "USD",
"subtotal_amount": 25,
"discount_amount": 25,
"fees_covered_amount": 25,
"total_amount": 25,
"tax_deductible_amount": 25,
"non_deductible_amount": 25,
"donation_amount": 25,
"payment_method": "Example",
"payment_status": "paid",
"payment_instructions": "Example",
"line_items": [
{
"type": "ticket",
"label": "General admission",
"ticket_type_id": 42,
"sponsor_package_id": 42,
"auction_item_id": 42,
"auction_bid_id": 42,
"quantity": 42,
"unit_amount": 25,
"line_total": 25,
"fair_market_total": 25,
"discount": 25,
"admissions_per_unit": 42,
"admissions": 42,
"source_snapshot": {
"name": "General admission",
"code": "Example",
"tier": "Example",
"registration_group_kind": "individual",
"group_label_prompt": "Example",
"attendee_details_timing": "checkout",
"admissions_per_unit": 42,
"unit_amount": "25.00",
"fair_market_value": "25.00"
}
}
],
"issued_at": "2026-10-20T12:00:00Z",
"receipt_note": "Ticket fair market value is separated from deductible event support.",
"adjustment_type": "refund",
"refunded_amount": 25,
"active_total_amount": 25,
"active_tax_deductible_amount": 25,
"adjustment_reason": "Example",
"adjusted_at": "2026-10-20T12:00:00Z"
},
"receipt_sent_at": "2026-10-20T12:00:00Z",
"registration_questions": [
{
"field_key": "dietary",
"field_label": "Dietary requirements",
"field_type": "text",
"options": [
"Vegetarian"
],
"scope": "buyer",
"required": false,
"id": 42,
"help_text": "Example",
"applies_to_ticket_type_ids": [
42
]
}
],
"event": {
"id": 42,
"branding_program_id": 42,
"name": "Annual Gala",
"slug": "annual-gala",
"starts_at": "2026-10-20T12:00:00Z",
"timezone": "Africa/Kampala",
"location": {
"mode": "released_full",
"label": "Kampala",
"venue": "Example",
"address": "Example",
"map_allowed": false
}
},
"registration_groups": [
{
"id": 42,
"source_kind": "ticket",
"source_id": 42,
"event_ticket_type_id": 42,
"kind": "individual",
"label": "Example",
"admissions_reserved": 42,
"attendee_details_timing": "checkout",
"status": "complete",
"source_snapshot": {
"name": "General admission",
"code": "Example",
"tier": "Example",
"registration_group_kind": "individual",
"group_label_prompt": "Example",
"attendee_details_timing": "checkout",
"admissions_per_unit": 42,
"unit_amount": "25.00",
"fair_market_value": "25.00"
},
"details_completed_at": "2026-10-20T12:00:00Z",
"answers": [
{
"id": 42,
"question_id": 42,
"question": {
"field_key": "dietary",
"field_label": "Dietary requirements",
"field_type": "text",
"options": [
"Vegetarian"
],
"scope": "buyer",
"required": false
},
"answer": "Vegetarian"
}
],
"attendee_ids": [
42
]
}
],
"attendees": [
{
"id": 42,
"event_registration_group_id": 42,
"event_ticket_type_id": 42,
"ticket_code": "EVT-42-00001",
"name": "Jane Doe",
"first_name": "Example",
"last_name": "Example",
"email": "Example",
"ticket_type": "Example",
"table": "Example",
"status": "registered",
"qr_token": "<string>",
"details_completed_at": "2026-10-20T12:00:00Z",
"qr_url": "Example",
"wallet_pass_url": "Example",
"wallet_pass_status": "inactive",
"checked_in_at": "2026-10-20T12:00:00Z",
"answers": [
{
"id": 42,
"question_id": 42,
"question": {
"field_key": "dietary",
"field_label": "Dietary requirements",
"field_type": "text",
"options": [
"Vegetarian"
],
"scope": "buyer",
"required": false
},
"answer": "Vegetarian"
}
],
"metadata": {
"source": "Example",
"event_sponsor_id": 42,
"sponsor_ticket_slot": 42
}
}
],
"sponsors": [
{
"id": 42,
"company_name": "Example",
"contact_name": "Example",
"contact_email": "Example",
"contact_phone": "Example",
"notes": "Example",
"status": "active",
"amount": 25,
"fair_market_value": 25,
"included_tickets_assigned": 42,
"public_visibility": false,
"renewal_follow_up_at": "2026-10-20T12:00:00Z",
"logo_upload_id": 42,
"logo_url": "Example",
"package": {
"id": 42,
"name": "Example",
"tier": "Example",
"included_tickets": 42,
"included_tables": 42
},
"deliverables": [
{
"id": 42,
"type": "logo",
"label": "Logo placement",
"status": "pending",
"due_at": "2026-10-20T12:00:00Z",
"completed_at": "2026-10-20T12:00:00Z"
}
]
}
],
"auction_items": [
{
"id": 42,
"event_auction_item_id": 42,
"name": "Example",
"amount": 25,
"quantity": 42,
"status": "paid",
"bidder_name": "Example",
"bidder_email": "Example"
}
],
"payment_reconciliation_required": false,
"payment_provider_status": "Example"
}
}{
"message": "Not Found",
"status": "error"
}{
"message": "Registration changed; reload the current version.",
"error_code": "invalid_reference",
"details": {}
}{
"errors": {},
"status": "error",
"message": "The given data was invalid."
}{
"message": "Something went wrong. Please try again.",
"status": "error",
"error": "invalid_request",
"code": "DONOR_NOT_FOUND"
}