API Reference

DeveloperDocumentation

Integrate Rally Tiles into your applications with our REST API. Build custom experiences, sync data, and extend functionality.

REST
API Style
JSON
Data Format
HTTPS
Secure Only
24/7
Uptime

Quick Start

Get started with the Rally Tiles API in minutes.

Base URL

https://rallytiles.com/api

All API endpoints use HTTPS and return JSON responses.

Authentication

Authorization: Bearer <token>

Most endpoints require authentication via session tokens.

API Endpoints

Complete reference for all available endpoints.

Health

System health and status endpoints

GET
/api/healthz
None

System health check

Response

{
  "ok": true,
  "version": "1.0.0",
  "db": true,
  "redis": true
}

Campaigns

Campaign and board management endpoints

GET
/api/campaigns
Required

List user's campaigns

Response

{
  "campaigns": [
    {
      "id": "cuid123",
      "title": "Spring Tournament Fund",
      "slug": "spring-tournament-2025",
      "status": "active",
      "goalCents": 505000,
      "raisedCents": 234500,
      "boards": [...]
    }
  ]
}
POST
/api/campaigns
Required

Create new campaign

Request Body

{
  "title": "Championship Fund",
  "type": "team",
  "goalCents": 500000,
  "deadline": "2025-06-01T00:00:00Z"
}

Response

{
  "campaign": {
    "id": "cuid456",
    "title": "Championship Fund",
    "slug": "championship-fund-2025",
    "status": "draft"
  }
}

Boards

Board and slot management endpoints

GET
/api/boards/{boardId}
None (public)

Get board details with slots

Response

{
  "board": {
    "id": "board123",
    "minNum": 1,
    "maxNum": 100,
    "slots": [
      {
        "id": "slot1",
        "number": 1,
        "status": "sold",
        "supporterName": "John Doe",
        "amountCents": 100
      }
    ]
  }
}
POST
/api/boards/{boardId}/reserve
None (rate limited)

Reserve slots for checkout

Request Body

{
  "slotIds": [1, 25, 50],
  "ownerToken": "uuid-token"
}

Response

{
  "ok": true,
  "holds": [
    {
      "slotId": 1,
      "expiresAt": "2025-01-20T10:15:00Z"
    }
  ]
}
POST
/api/boards/{boardId}/release
None (rate limited)

Release held slots

Request Body

{
  "slotIds": [1, 25],
  "ownerToken": "uuid-token"
}

Response

{
  "ok": true,
  "released": [1, 25]
}

Checkout

Payment and donation processing

POST
/api/checkout/session
None (reCAPTCHA required)

Create Stripe checkout session

Request Body

{
  "boardId": "board123",
  "slotIds": [1, 25, 50],
  "supporter": {
    "name": "Jane Smith",
    "email": "jane@example.com",
    "message": "Go team!",
    "imageUrl": "https://..."
  },
  "coverFees": true
}

Response

{
  "url": "https://checkout.stripe.com/pay/cs_123"
}

Webhooks

Stripe webhook endpoints

POST
/api/stripe/webhook
Stripe signature

Stripe webhook handler

Request Body

Stripe event payload

Response

{
  "received": true
}

Admin

Administrative endpoints (authenticated)

GET
/api/admin/join-requests
Admin required

List pending organization join requests

Response

{
  "requests": [
    {
      "id": "req123",
      "userId": "user456",
      "organizationId": "org789",
      "status": "pending",
      "createdAt": "2025-01-20T10:00:00Z"
    }
  ]
}
POST
/api/admin/join-requests/{id}/approve
Admin required

Approve organization join request

Response

{
  "ok": true,
  "userRole": {
    "userId": "user456",
    "role": "team_admin",
    "orgId": "org789"
  }
}

Code Examples

Sample code to get you started in your preferred language.

Integration Examples

Common API usage patterns for slot reservations and checkout.

// Get board data
const response = await fetch('/api/boards/board123');
const { board } = await response.json();

// Reserve slots
const reservation = await fetch('/api/boards/board123/reserve', {
  method: 'POST',
  headers: { 'Content-Type': 'application/json' },
  body: JSON.stringify({
    slotIds: [1, 25, 50],
    ownerToken: crypto.randomUUID()
  })
});

// Create checkout session
const checkout = await fetch('/api/checkout/session', {
  method: 'POST',
  headers: { 'Content-Type': 'application/json' },
  body: JSON.stringify({
    boardId: 'board123',
    slotIds: [1, 25, 50],
    supporter: {
      name: 'John Doe',
      email: 'john@example.com'
    }
  })
});

Webhooks

Real-time event notifications from Stripe payment processing.

checkout.session.completed

Payment successful, slots marked as sold

{
  "type": "checkout.session.completed",
  "data": {
    "object": {
      "id": "cs_123",
      "metadata": {
        "boardId": "board123",
        "slotNumbersCSV": "1,25,50",
        "ownerToken": "uuid-token"
      }
    }
  }
}

checkout.session.expired

Checkout expired, slots released

{
  "type": "checkout.session.expired",
  "data": {
    "object": {
      "id": "cs_123",
      "metadata": {...}
    }
  }
}

charge.dispute.created

Payment disputed, investigation started

{
  "type": "charge.dispute.created",
  "data": {
    "object": {
      "charge": "ch_123",
      "reason": "fraudulent"
    }
  }
}

Guidelines & Best Practices

Rate Limits

Reserve/Release
30/min per IP
Checkout Creation
10/min per IP
General API
100/min per user
Webhook Delivery
No limit

Security

HTTPS Required
All API calls must use HTTPS
Token Authentication
Use session tokens in Authorization header
Input Validation
All inputs are validated and sanitized
Webhook Signatures
Verify Stripe webhook signatures

Need API Access?

Our API is available for approved integrations. Contact our developer support team to discuss your use case and get API credentials.

Fast Response
Developer requests reviewed within 24 hours
Secure Access
Enterprise-grade security and compliance
Full Support
Dedicated developer support included