Base: https://api.sajilosport.com/api

Khelau — Mobile Developer API Documentation

Base URL: https://your-domain.com/api

Auth: Laravel Sanctum — Bearer token in Authorization header

Content-Type: application/json

API Prefix: All routes live under /api/


Module Index

ModuleFileDescription
Authentication01-auth.mdRegister, login, OTP, social auth, devices
Venues02-venues.mdVenue search, details, images, nearby
Courts03-courts.mdCourt info, availability, pricing, schedule
Bookings04-bookings.mdCreate, view, cancel futsal court bookings
Payments05-payments.mdeSewa, Khalti, FonePay, cash, refunds
Wallet06-wallet.mdWallet balance, top-up, transactions
Coupons07-coupons.mdValidate discount codes at checkout
Reviews08-reviews.mdSubmit and read venue reviews
Tournaments09-tournaments.mdBrowse tournaments, register a team
Indoor Games10-indoor-games.mdBook PS/chess/table-tennis/carrom etc.
Profile and Notifications11-profile-notifications.mdProfile, avatar, push token, notifications
Error Reference00-errors.mdStandard HTTP error codes and shapes

Authentication Quick-Start

All protected endpoints require:

Authorization: Bearer <token>

Obtain the token from POST /api/auth/login or POST /api/auth/otp/verify.

Tokens do not expire automatically — revoke per-device via DELETE /api/auth/devices/{tokenId}.


Standard Response Envelope

Success — single resource

{
  "data": { ... }
}

Success — collection

{
  "data": [ ... ],
  "links": { "first": "...", "last": "...", "prev": null, "next": "..." },
  "meta": { "current_page": 1, "total": 42, "per_page": 15 }
}

Error

{
  "message": "Human-readable error description."
}

Validation Error (422)

{
  "message": "The given data was invalid.",
  "errors": {
    "field_name": ["Error detail."]
  }
}

Rate Limits

Endpoint groupLimit
POST /api/auth/register10 requests / 1 min
POST /api/auth/loginConfigurable (throttle:login)
POST /api/auth/otp/*Configurable (throttle:otp)

All other endpoints: default 60 req / min.


Roles Reference

RoleDescription
customerRegular app users
venue_ownerOwns a venue / SaaS tenant
managerVenue manager (staff)
staffVenue front-desk
super_adminPlatform admin

Most mobile customer flows require only the customer role. Staff-facing endpoints are clearly marked in each module doc.