API Documentation
Integrate Royal Icon Events into your applications.
REST API
Standard REST endpoints
JWT Auth
Secure token-based auth
Webhooks
Real-time event notifications
Base URL
https://royaliconevents.co.keAuthentication
Include your JWT token in the Authorization header:
Authorization: Bearer <your-token>GET
/api/eventsList all published eventsGET
/api/events/[slug]Get event by slugPOST
/api/events AuthCreate a new eventPUT
/api/events/[id] AuthUpdate an eventDELETE
/api/events/[id] AuthDelete an eventGET
/api/competitionsList all active competitionsGET
/api/competitions/[slug]Get competition by slugPOST
/api/competitions AuthCreate a new competitionPOST
/api/votes AuthCast a voteGET
/api/leaderboard/[period]Get leaderboard by periodPOST
/api/payments/checkout AuthCreate payment sessionPOST
/api/auth/loginLogin with email/passwordPOST
/api/auth/registerRegister new accountGET
/api/ogGenerate OG image (SVG)POST
/api/poster AuthGenerate event poster (SVG)Example Request
# List events
curl -X GET https://royaliconevents.co.ke/api/events \
-H "Content-Type: application/json"
# Create payment session
curl -X POST https://royaliconevents.co.ke/api/payments/checkout \
-H "Authorization: Bearer YOUR_TOKEN" \
-H "Content-Type: application/json" \
-d {"amount": 2000, "currency": "KES", "method": "mpesa_stk"}