Orders
Create Order
Initialize a new ticket order for an event
POST
Documentation Index
Fetch the complete documentation index at: https://mintlify.com/GoodnessFx/GatePass/llms.txt
Use this file to discover all available pages before exploring further.
This endpoint creates a new order for purchasing event tickets. It supports both crypto and fiat payment methods, with integration for Flutterwave, Paystack, and M-Pesa payment gateways.
Authentication
Bearer token for authentication
Request Body
The ID of the event for which tickets are being purchased
The ID of the ticket tier to purchase
Number of tickets to purchase (must be at least 1)
Payment method type:
CRYPTO or FIATPayment gateway for fiat payments:
paystack, flutterwave, or mpesaCustomer email address (defaults to authenticated user’s email)
Customer name (defaults to authenticated user’s name)
Response
Indicates if the order was successfully created
Unique identifier for the created order
Payment reference for tracking the transaction
Payment gateway checkout URL (for Flutterwave)
Order Model
The Order object contains the following fields:- id: Unique order identifier (CUID)
- totalAmount: Total order amount including platform fees (2.5%)
- quantity: Number of tickets purchased
- currency: Payment currency (e.g., NGN, USD, ETH)
- paymentMethod: CRYPTO or FIAT
- paymentStatus: PENDING, COMPLETED, or FAILED
- customerEmail: Customer’s email address
- customerName: Customer’s name
- userId: ID of the purchasing user
- eventId: ID of the event
- createdAt: Order creation timestamp
- updatedAt: Last update timestamp
Platform Fees
GatePass applies a 2.5% platform fee on top of the ticket price. The total amount is calculated as:Payment Flow
- Order Initialization: Create an order with this endpoint
- Payment Processing: User completes payment through the gateway
- Webhook Verification: Payment gateway sends webhook to GatePass
- Order Confirmation: Order status updated to COMPLETED
- Ticket Minting: NFT tickets minted on blockchain (if applicable)
- Notification: User receives confirmation notification