Loading…
Integrate Geerok's crypto exchange infrastructure into your platform. Sell crypto to your users using our API.
Geerok uses session-based authentication with httpOnly cookies. To make authenticated requests:
POST /api/auth/sign-in with email and passwordcredentials: "include" in fetch calls// Example: Sign in and make authenticated request
const login = await fetch("https://geerok.name.ng/api/auth/sign-in", {
method: "POST",
credentials: "include",
headers: { "Content-Type": "application/json" },
body: JSON.stringify({ email: "user@example.com", password: "password" })
})
// Then all subsequent calls
const wallet = await fetch("https://geerok.name.ng/api/user/wallet", {
credentials: "include"
})
const { balance } = await wallet.json()
console.log("Balance:", balance) // e.g. 25000All errors return a JSON body with an error field and an appropriate HTTP status code.
// Error response format
{ "error": "Human-readable error message" }
// Common status codes:
// 400 — Bad request (missing/invalid fields)
// 401 — Unauthorized (not signed in)
// 400 — Insufficient balance
// 503 — Exchange temporarily unavailable (balance refunded)
// 500 — Internal server error/api/auth/sign-upCreate a new user account
{ "email": "user@example.com", "password": "min8chars", "fullName": "John Doe", "phone": "+234..." }{ "success": true, "message": "Verification email sent", "needsVerification": true }/api/auth/sign-inSign in and create session
{ "email": "user@example.com", "password": "yourpassword" }{ "success": true, "user": { "id": 1, "email": "user@example.com" } }/api/auth/sign-out Auth requiredDestroy current session
{ "success": true }/api/auth/forgot-passwordSend password reset email
{ "email": "user@example.com" }{ "success": true }/api/auth/reset-passwordReset password with token
{ "token": "reset_token", "password": "newpassword" }{ "success": true }/api/user/wallet Auth requiredGet authenticated user wallet balance
{ "balance": 25000.00 }/api/user/price?symbol=BTC Auth requiredGet live Naira price for any token
{ "symbol": "BTC", "naira_price": 98500000, "usdt_price": 61562, "provider": "P3", "usd_ngn_rate": 1600, "spread_percent": 2.5 }/api/user/settingsGet public platform settings
{ "usd_ngn_rate": "1600", "min_deposit_naira": "5000", "kyc_basic_price": "2000" }/api/user/buy-crypto Auth requiredPlace a crypto buy order. Deducts wallet balance immediately. Auto-refunds on failure within 5 minutes.
{ "tokenSymbol": "BTC", "nairaAmount": 50000, "walletAddress": "bc1q..." }{ "success": true, "orderId": 42, "orderNumber": "GRK-1234567" }/api/user/otc-tokens Auth requiredList all available Peer Exchange tokens
{ "tokens": [{ "id": 1, "name": "Pi Network", "ticker": "PI", "price_naira": 9000, "allow_buy": true, "allow_sell": true }] }/api/user/otc-order Auth requiredPlace a Peer Exchange buy or sell order
{ "tokenId": 1, "nairaAmount": 5000, "walletAddress": "pi_address", "type": "buy" }{ "success": true, "orderId": 43, "orderNumber": "GRK-OTC-1234567" }/api/user/deposit-infoGet bank accounts and deposit settings (public)
{ "bank_accounts": "[{...}]", "min_deposit": "5000", "deposit_fee_percent": "0" }/api/user/deposit Auth requiredSubmit a deposit request after bank transfer
{ "amount_naira": 10000, "bank_name": "GTB", "reference": "TXN123456" }{ "success": true }/api/user/notifications Auth requiredGet user notifications and unread count
{ "notifications": [...], "unreadCount": 3 }/api/user/notifications Auth requiredMark all notifications as read
{ "success": true }/api/user/kyc-tickets Auth requiredList user KYC support tickets
{ "tickets": [...] }/api/user/kyc-tickets Auth requiredSubmit a new KYC support ticket (deducts wallet)
{ "problemType": "Liveness check failed", "platform": "Bybit", "description": "...", "tier": "basic" }{ "success": true, "ticket": {...} }/api/user/sidra-appointments Auth requiredList user Sidra appointments
{ "appointments": [...] }/api/user/sidra-appointments Auth requiredBook a Sidra verification appointment
{ "username": "sidra_user", "phone": "+234...", "preferred_date": "2026-02-20", "preferred_time": "10:00 AM", "notes": "..." }{ "success": true, "appointment": {...} }/api/user/profile Auth requiredGet authenticated user profile
{ "user": { "full_name": "John", "email": "john@example.com", "phone": "..." } }/api/user/profile Auth requiredUpdate user profile
{ "full_name": "John Doe", "phone": "+234..." }{ "success": true }/api/user/change-password Auth requiredChange user password
{ "currentPassword": "old", "newPassword": "new8chars" }{ "success": true }To integrate Geerok into your platform or for higher limits, contact us at developers@geerok.name.ng