AmarEvents API Docs
A clean, read-only REST API to access event data from amarevents.zone.id. Embed event listings, check ticket availability, or pull full stats for your own events.
All endpoints require an API key. Two key types exist with different access levels and rate limits.
Sending Your Key
Pass your API key in one of two ways:
Option 1 — Authorization Header (Recommended)
Authorization: Bearer ae_u_your_key_here
Option 2 — Query Parameter
https://amarevents.zone.id/api/events?api_key=ae_u_your_key_here
How to Get a Key
Create an account
Sign up at amarevents.zone.id/register — it's free.
Go to API Keys dashboard
Visit amarevents.zone.id/dashboard/api-keys after logging in.
Create a key
Choose a name, select key type (User or Organizer), and click Create. Your key is shown once — copy it immediately.
Start making requests
Pass the key via Authorization header or ?api_key= param. You're ready.
Use these shared keys to test the API without creating an account. They return real public data.
These keys are publicly visible and shared. For any real integration, generate your own key.
All code examples on this page use the mock user key. Copy-paste and run them — they'll work immediately.
Paste your own API key (or use a mock key) and fire a real request straight from this page — no terminal needed.
Requests go out from your own browser directly to https://amarevents.zone.id/api using the key above — nothing is sent through our servers, and your key is never stored.
Go from zero to a working API call in under a minute.
curl -H "Authorization: Bearer ae_u_test_0000000000000000000000000000000000000000000000" \
https://amarevents.zone.id/api/events
const response = await fetch('https://amarevents.zone.id/api/events', { headers: { 'Authorization': 'Bearer ae_u_test_0000000000000000000000000000000000000000000000' } }); const data = await response.json(); console.log(data.data);
$ch = curl_init('https://amarevents.zone.id/api/events'); curl_setopt($ch, CURLOPT_RETURNTRANSFER, true); curl_setopt($ch, CURLOPT_HTTPHEADER, [ 'Authorization: Bearer ae_u_test_0000000000000000000000000000000000000000000000' ]); $json = curl_exec($ch); curl_close($ch); $data = json_decode($json, true); print_r($data['data']);
import requests headers = {'Authorization': 'Bearer ae_u_test_0000000000000000000000000000000000000000000000'} r = requests.get('https://amarevents.zone.id/api/events', headers=headers) data = r.json() print(data['data'])
Example Response
{
"success": true,
"data": [
{
"id": 29,
"name": "Thakurgaon 7.5K Friendship Run",
"date": "2025-10-03",
"deadline": "2025-09-26 01:30:00",
"location": "Thakurgaon",
"category": "Sports",
"organization_id": 16,
"organizer": "Thakurgaon Runners",
"price_from": "499",
"price_to": "499",
"ticket_type_count": 1
}
],
"pagination": {
"total": 5,
"page": 1,
"limit": 20,
"pages": 1
}
}
Limits are enforced per API key, per second. Headers on every response show your current usage.
Every response includes these headers:
X-RateLimit-Limit: 3 X-RateLimit-Remaining: 2 X-RateLimit-Reset: 1719600001 X-RateLimit-Window: per-second
All errors follow the same shape: {"success": false, "error": "message here"}
These endpoints work with either a User or Organizer key. They only return public events.
Returns a paginated list of upcoming public events, sorted by date ascending.
Query Parameters
| Name | Type | Description | |
|---|---|---|---|
| page | int | optional | Page number, default 1 |
| limit | int | optional | Results per page, default 20, max 50 |
| search | string | optional | Search by event name or location |
| category | string | optional | Filter by category e.g. Sports, Education |
| organization_id | int | optional | Filter to one organizer's events |
curl -H "Authorization: Bearer ae_u_test_0000000000000000000000000000000000000000000000" \ "https://amarevents.zone.id/api/events?category=Sports&limit=5"
const res = await fetch('https://amarevents.zone.id/api/events?category=Sports&limit=5', { headers: { 'Authorization': 'Bearer ae_u_test_0000000000000000000000000000000000000000000000' } }); const { data, pagination } = await res.json();
Returns past events sorted by date descending. Includes a total_attendees count per event.
Query Parameters
| Name | Type | Description | |
|---|---|---|---|
| page | int | optional | Page number |
| limit | int | optional | Max 50 |
| search | string | optional | Search by name |
| category | string | optional | Filter by category |
curl -H "Authorization: Bearer ae_u_test_0000000000000000000000000000000000000000000000" \ "https://amarevents.zone.id/api/events/past"
Returns complete event info including ticket types, registration fields, and computed flags like is_registration_open.
URL Parameters
| Name | Type | Description | |
|---|---|---|---|
| id | int | required | Event ID |
curl -H "Authorization: Bearer ae_u_test_0000000000000000000000000000000000000000000000" \ "https://amarevents.zone.id/api/events/29"
const eventId = 29; const res = await fetch(`https://amarevents.zone.id/api/events/${eventId}`, { headers: { 'Authorization': 'Bearer ae_u_test_0000000000000000000000000000000000000000000000' } }); const { data } = await res.json(); console.log(data.is_registration_open);
Response Includes
Returns all ticket types for an event with real-time availability. Useful for building a ticket widget.
curl -H "Authorization: Bearer ae_u_test_0000000000000000000000000000000000000000000000" \ "https://amarevents.zone.id/api/events/29/tickets"
{
"success": true,
"event_id": 29,
"data": [
{
"id": 12,
"name": "7.5K Run",
"price": "499",
"capacity": 100,
"description": "Standard race entry",
"sold": "63",
"available": 37,
"sold_out": false
}
]
}Returns all events belonging to your organization, including registration counts, revenue, and pending approvals.
Query Parameters
| Name | Type | Description | |
|---|---|---|---|
| status | string | optional | upcoming | past | all (default: all) |
| privacy | string | optional | public | private |
| search | string | optional | Filter by event name |
| page | int | optional | Page number |
| limit | int | optional | Max 50 |
curl -H "Authorization: Bearer ae_o_test_1111111111111111111111111111111111111111111111" \ "https://amarevents.zone.id/api/my/events?status=upcoming"
const res = await fetch('https://amarevents.zone.id/api/my/events?status=upcoming', { headers: { 'Authorization': 'Bearer ae_o_test_1111111111111111111111111111111111111111111111' } }); const { data, organization } = await res.json();
Each Event Includes
Deep detail for a single event you own. Includes per-ticket-type breakdowns, daily registration trends, and top ambassadors.
curl -H "Authorization: Bearer ae_o_test_1111111111111111111111111111111111111111111111" \ "https://amarevents.zone.id/api/my/events/29"
Response Includes
{
"success": true,
"data": {
"id": 29,
"name": "Thakurgaon 7.5K Friendship Run",
"stats": {
"total": "84",
"approved": "63",
"pending": "18",
"rejected": "3",
"revenue": "31437"
},
"daily_registrations": [
{ "date": "2025-09-05", "registrations": "12", "approved": "9" }
],
"top_ambassadors": [
{ "username": "runner_ali", "referrals": "14" }
]
}
}Aggregated summary across your entire organization — perfect for a dashboard overview widget.
curl -H "Authorization: Bearer ae_o_test_1111111111111111111111111111111111111111111111" \ "https://amarevents.zone.id/api/my/stats"