Referencia de la API
Generada a partir del documento OpenAPI 3.1 en /api/v1/openapi.json. Las rutas de abajo son relativas a https://sportsmgnt.com/api/v1.
Versión 1.0.0 · Descargar el documento OpenAPI · Desarrolladores
REST API of the SportsMgnt demonstration platform built by WeldonPC. All data is sample data for the fictional Kestrel Basin Parks & Recreation District and resets nightly. Responses use the envelope {"data": ..., "meta": {...}}; errors use {"error": {"code", "message", "fields"}}.
Grupos de puntos de acceso
catalog
Public activity catalog (no token needed)
GET /activities
Search activity sessions (same filters as the /activities page)
No necesita token
Parámetros: GET /activities Nombre Dónde Tipo Obligatorio Descripción qquery string No Keyword (title, description or code) categoryquery string No Category slug, e.g. aquatics agequery integer No Participant age gradequery string No School grade K or 1-12 locationquery string No Location code, e.g. L-HPCC near_locationquery string No Location code to measure distance from distancequery integer No Kilometres from near_location: 1, 3, 5 or 10 day[]query array of string (mon, tue, wed, thu, fri, sat, sun) No Days of week (mon..sun); repeat day[] timequery string No morning, afternoon or evening fromquery string No Earliest start time HH:MM toquery string No Latest end time HH:MM languagequery string No en, es or bilingual adaptivequery integer No 1 = adaptive programs only openquery integer No 1 = sessions with open seats only seasonquery string No Season code pagequery integer No Page number per_pagequery integer No Rows per page (max 100)
Respuestas
200 Paginated sessions 429 Too many requests; see Retry-After
Ejemplo de solicitud curl 'https://sportsmgnt.com/api/v1/activities' \
-H 'Accept: application/json'
GET /activities/{code}
One activity (program code like AQ-L2, or a session code) with its sessions
No necesita token
Parámetros: GET /activities/{code} Nombre Dónde Tipo Obligatorio Descripción codepath string Sí
Respuestas
200 Activity 404 Not found 429 Too many requests; see Retry-After
Ejemplo de solicitud curl 'https://sportsmgnt.com/api/v1/activities/AQ-L2' \
-H 'Accept: application/json'
GET /locations
Locations of the fictional district with grid coordinates
No necesita token
Respuestas
200 Locations 429 Too many requests; see Retry-After
Ejemplo de solicitud curl 'https://sportsmgnt.com/api/v1/locations' \
-H 'Accept: application/json'
core
Health and token information
GET /health
Service health
No necesita token
Respuestas
200 OK 429 Too many requests; see Retry-After
Ejemplo de solicitud curl 'https://sportsmgnt.com/api/v1/health' \
-H 'Accept: application/json'
GET /me/token
Describe the calling token
Requiere token
Respuestas
200 The token's user, scopes and expiry 401 Missing, invalid, revoked or expired token 429 Too many requests; see Retry-After
Ejemplo de solicitud curl 'https://sportsmgnt.com/api/v1/me/token' \
-H 'Accept: application/json' \
-H 'Authorization: Bearer SU_TOKEN'
facilities
Facility inventory and availability (public)
GET /facilities
List facilities
Public. Filters match the web catalog.
No necesita token
Parámetros: GET /facilities Nombre Dónde Tipo Obligatorio Descripción typequery string No Facility type locationquery integer No Location id capacityquery integer No Minimum capacity amenityquery string No Amenity key accessiblequery string No Accessibility feature key bookablequery string No 1 = bookable online only qquery string No Search text pagequery integer No Page number per_pagequery integer No Items per page (max 100)
Respuestas
200 OK 429 Too many requests; see Retry-After
Ejemplo de solicitud curl 'https://sportsmgnt.com/api/v1/facilities' \
-H 'Accept: application/json'
GET /facilities/{slug}
One facility
No necesita token
Parámetros: GET /facilities/{slug} Nombre Dónde Tipo Obligatorio Descripción slugpath string Sí
Respuestas
200 OK 404 Unknown facility
Ejemplo de solicitud curl 'https://sportsmgnt.com/api/v1/facilities/riverbend-shelter-1' \
-H 'Accept: application/json'
GET /facilities/{slug}/availability
Free and busy times per day
Agency-local times (meta.timezone). Busy blocks carry a state but never who booked them.
No necesita token
Parámetros: GET /facilities/{slug}/availability Nombre Dónde Tipo Obligatorio Descripción slugpath string Sí fromquery string No First date (YYYY-MM-DD, default today) toquery string No Last date (default from + 6 days; at most 31 days)
Respuestas
200 OK 404 Unknown facility 422 Invalid date range
Ejemplo de solicitud curl 'https://sportsmgnt.com/api/v1/facilities/riverbend-shelter-1/availability' \
-H 'Accept: application/json'
household
The signed-in household (personal access token with household:read)
GET /me/calendar
Calendar items between two dates (agency time; default the next 30 days; scope household:read)
Requiere token
Parámetros: GET /me/calendar Nombre Dónde Tipo Obligatorio Descripción fromquery string (date) No toquery string (date) No
Respuestas
200 Calendar items 422 Invalid range 401 Missing, invalid, revoked or expired token 403 The token lacks a scope, or the user lacks a permission 429 Too many requests; see Retry-After
Ejemplo de solicitud curl 'https://sportsmgnt.com/api/v1/me/calendar' \
-H 'Accept: application/json' \
-H 'Authorization: Bearer SU_TOKEN'
GET /me/cart
The household's open cart with seat-hold expiry times (scope household:read)
Requiere token
Respuestas
200 Cart 401 Missing, invalid, revoked or expired token 403 The token lacks a scope, or the user lacks a permission 429 Too many requests; see Retry-After
Ejemplo de solicitud curl 'https://sportsmgnt.com/api/v1/me/cart' \
-H 'Accept: application/json' \
-H 'Authorization: Bearer SU_TOKEN'
GET /me/enrollments
Enrolments of the household, newest first (scope household:read)
Requiere token
Parámetros: GET /me/enrollments Nombre Dónde Tipo Obligatorio Descripción statusquery string No pagequery integer No per_pagequery integer No
Respuestas
200 Enrolments 401 Missing, invalid, revoked or expired token 403 The token lacks a scope, or the user lacks a permission 429 Too many requests; see Retry-After
Ejemplo de solicitud curl 'https://sportsmgnt.com/api/v1/me/enrollments' \
-H 'Accept: application/json' \
-H 'Authorization: Bearer SU_TOKEN'
GET /me/household
The token user's active household (scope household:read)
Requiere token
Respuestas
200 Household 401 Missing, invalid, revoked or expired token 403 The token lacks a scope, or the user lacks a permission 429 Too many requests; see Retry-After
Ejemplo de solicitud curl 'https://sportsmgnt.com/api/v1/me/household' \
-H 'Accept: application/json' \
-H 'Authorization: Bearer SU_TOKEN'
GET /me/members
Household members (scope household:read; no medical data)
Requiere token
Respuestas
200 Members 401 Missing, invalid, revoked or expired token 403 The token lacks a scope, or the user lacks a permission 429 Too many requests; see Retry-After
Ejemplo de solicitud curl 'https://sportsmgnt.com/api/v1/me/members' \
-H 'Accept: application/json' \
-H 'Authorization: Bearer SU_TOKEN'
reservations
Facility reservation requests (token)
GET /reservations
Your household's reservations
Token scope household:read.
Requiere token
Parámetros: GET /reservations Nombre Dónde Tipo Obligatorio Descripción pagequery integer No Page number per_pagequery integer No Items per page (max 100)
Respuestas
200 OK 401 Missing, invalid, revoked or expired token 403 The token lacks a scope, or the user lacks a permission
Ejemplo de solicitud curl 'https://sportsmgnt.com/api/v1/reservations' \
-H 'Accept: application/json' \
-H 'Authorization: Bearer SU_TOKEN'
POST /reservations
Request a reservation
Token scope reservations:write. Creates a request only: no payment is taken and nothing is confirmed here. The same validation as the web form applies (booking windows, opening hours, capacity, slot locks). Pay, sign and upload paperwork from the reservation page.
Requiere token
Cuerpo de la solicitud
Cuerpo de la solicitud: POST /reservations Propiedad Tipo Obligatorio Descripción facilitystring Sí Facility slug householdstring No H-number; defaults to the token user's active household modestring (once, weekly, dates) No datestring (date) No daysarray of integer No ISO weekdays for mode=weekly untilstring (date) No datesarray of string (date) No startstring Sí Agency-local time, 15-minute steps endstring Sí purposestring (private, nonprofit, school, commercial) No attendeesinteger Sí titlestring No organisationstring No notesstring No on_conflictstring (block, drop) No agreementobject No Optional: sign the rental agreement now
Respuestas
201 Request created 401 Missing, invalid, revoked or expired token 403 The token lacks a scope, or the user lacks a permission 409 A requested time is already taken (program, booking, league game or blackout) 422 Validation failed 429 Too many requests; see Retry-After
Ejemplo de solicitud curl -X POST 'https://sportsmgnt.com/api/v1/reservations' \
-H 'Accept: application/json' \
-H 'Authorization: Bearer SU_TOKEN' \
-H 'Content-Type: application/json' \
-d '{"facility":"string","household":"string","mode":"once","date":"2026-10-12","days":[1],"until":"2026-10-12","dates":["2026-10-12"],"start":"10:00","end":"13:00","purpose":"private","attendees":1,"title":"string","organisation":"string","notes":"string","on_conflict":"block","agreement":{"signer_name":"string","consent":true}}'
GET /reservations/{id}
One reservation
Token scope household:read.
Requiere token
Parámetros: GET /reservations/{id} Nombre Dónde Tipo Obligatorio Descripción idpath string Sí
Respuestas
200 OK 401 Missing, invalid, revoked or expired token 403 The token lacks a scope, or the user lacks a permission 404 Not found or not yours
Ejemplo de solicitud curl 'https://sportsmgnt.com/api/v1/reservations/1' \
-H 'Accept: application/json' \
-H 'Authorization: Bearer SU_TOKEN'
staff
Staff back office: rosters, attendance and reports. Requires a staff token with the matching scope; the token user's role and location scope apply, and an instructor-only user sees only the sessions they teach.
POST /staff/attendance
Record attendance for a meeting
Scope staff:attendance. The token user needs attendance.mark at the meeting's location (instructor-only users: their own sessions).
Requiere token
Cuerpo de la solicitud
Cuerpo de la solicitud: POST /staff/attendance Propiedad Tipo Obligatorio Descripción meeting_idinteger Sí recordsarray of object Sí
Respuestas
200 Saved 401 Missing, invalid, revoked or expired token 403 The token lacks a scope, or the user lacks a permission 404 No such meeting 422 Invalid records 429 Too many requests; see Retry-After
Ejemplo de solicitud curl -X POST 'https://sportsmgnt.com/api/v1/staff/attendance' \
-H 'Accept: application/json' \
-H 'Authorization: Bearer SU_TOKEN' \
-H 'Content-Type: application/json' \
-d '{"meeting_id":1,"records":[{"enrollment_id":1,"status":"present"}]}'
GET /staff/reports/{key}
Run a library report
Scope staff:reports. Rows are limited to the token user's location scope. Keys: enrolment, revenue_cost_center, daily_cash, transmittals, refunds_status, waitlists, facility_utilization, attendance_pct, instructor_hours, demographics, fee_assistance, inventory, donations_fund, passes, balances_aging, audit_summary.
Requiere token
Parámetros: GET /staff/reports/{key} Nombre Dónde Tipo Obligatorio Descripción keypath string Sí fromquery string (date) No toquery string (date) No locationquery integer No seasonquery integer No
Respuestas
200 Report rows (sample data) 401 Missing, invalid, revoked or expired token 403 The token lacks a scope, or the user lacks a permission 404 Unknown report 429 Too many requests; see Retry-After
Ejemplo de solicitud curl 'https://sportsmgnt.com/api/v1/staff/reports/key' \
-H 'Accept: application/json' \
-H 'Authorization: Bearer SU_TOKEN'
GET /staff/rosters/{session}
Roster of a session
Scope staff:rosters. The token user needs rosters.view at the session's location; an instructor-only user must be assigned to the session.
Requiere token
Parámetros: GET /staff/rosters/{session} Nombre Dónde Tipo Obligatorio Descripción sessionpath string Sí Session code (KB-F26-1012) or numeric id
Respuestas
200 Roster 401 Missing, invalid, revoked or expired token 403 The token lacks a scope, or the user lacks a permission 404 No such session 429 Too many requests; see Retry-After
Ejemplo de solicitud curl 'https://sportsmgnt.com/api/v1/staff/rosters/KB-F26-1001' \
-H 'Accept: application/json' \
-H 'Authorization: Bearer SU_TOKEN'
Esquemas
Activity object
Activity Propiedad Tipo Obligatorio Descripción codestring Sí typestring Sí titlestring Sí descriptionstring Sí categorystring Sí agesobject Sí gradesobject No residents_onlyboolean No languagestring No adaptiveboolean No required_waiversarray of string No required_documentsarray of string No accessibility_notesstring No sessionsarray of ActivitySession Sí
ActivitySession object
ActivitySession Propiedad Tipo Obligatorio Descripción codestring Sí program_codestring Sí titlestring Sí typestring (class, camp, overnight_camp, league, child_care, dropin, event) Sí categorystring No seasonstring No locationobject Sí facilitystring | null No start_datestring (date) Sí end_datestring (date) Sí daysarray of string Sí start_timestring Sí end_timestring Sí agesobject No languagestring No adaptiveboolean No capacityinteger Sí seats_leftinteger Sí waitlistedinteger Sí resident_price_centsinteger Sí registrationobject Sí urlstring No
AttendanceRequest object
AttendanceRequest Propiedad Tipo Obligatorio Descripción meeting_idinteger Sí recordsarray of object Sí
AttendanceResult object
AttendanceResult Propiedad Tipo Obligatorio Descripción dataobject No metaMeta No
AvailabilityDay object
AvailabilityDay Propiedad Tipo Obligatorio Descripción datestring (date) Sí openboolean Sí opens_atstring Sí closes_atstring Sí freearray of object Sí busyarray of object Sí
CalendarItem object
CalendarItem Propiedad Tipo Obligatorio Descripción typestring Sí titlestring Sí personstring | null No person_idinteger | null No starts_atstring (date-time) Sí ends_atstring (date-time) Sí locationstring Sí facilitystring | null No notesstring | null No
Cart object
Cart Propiedad Tipo Obligatorio Descripción itemsarray of object Sí total_centsinteger Sí
Enrollment object
Enrollment Propiedad Tipo Obligatorio Descripción idinteger Sí sessionstring Sí titlestring Sí person_idinteger Sí statusstring (pending_review, enrolled, waitlisted, offered, cancelled, transferred, completed) Sí waitlist_positioninteger | null No enrolled_atstring | null (date-time) No offer_expires_atstring | null (date-time) No start_datestring (date) No end_datestring (date) No
Error object
Error Propiedad Tipo Obligatorio Descripción errorobject Sí
Facility object
Facility Propiedad Tipo Obligatorio Descripción slugstring Sí namestring Sí typestring Sí locationobject Sí capacityinteger Sí amenitiesarray of string No accessible_featuresarray of string No bookable_onlineboolean Sí approval_stepsinteger Sí instant_bookingboolean Sí insurance_requiredboolean Sí deposit_centsinteger Sí min_notice_daysinteger Sí max_advance_daysinteger Sí cutoff_daysinteger Sí opens_atstring Sí closes_atstring Sí urlstring Sí
FacilityDetail
Household object
Household Propiedad Tipo Obligatorio Descripción public_idstring Sí namestring Sí kindstring No residencystring (resident, nonresident) Sí zipstring | null No statusstring No income_statusstring No income_verified_untilstring | null (date) No rolestring | null (primary, secondary, ) Sí membersinteger Sí balance_centsinteger Sí credit_centsinteger Sí
Location object
Location Propiedad Tipo Obligatorio Descripción codestring Sí namestring Sí addressstring Sí phonestring | null No x_kmnumber Sí y_kmnumber Sí point_of_saleboolean No hoursobject No
Member object
Member Propiedad Tipo Obligatorio Descripción idinteger Sí first_namestring Sí last_namestring Sí ageinteger | null No relationstring Sí guardian_rolestring Sí school_gradestring | null No has_allergyboolean No
Meta Propiedad Tipo Obligatorio Descripción totalinteger No pageinteger No per_pageinteger No
ReportResult object
ReportResult Propiedad Tipo Obligatorio Descripción dataobject No metaobject No
Reservation object
Reservation Propiedad Tipo Obligatorio Descripción idstring Sí statusstring (draft, submitted, in_review, approved, awaiting_payment, confirmed, denied, cancelled) Sí status_labelstring No facilityobject Sí householdstring Sí purposestring (private, nonprofit, school, commercial) Sí attendeesinteger Sí titlestring | null No current_stepinteger Sí approval_stepsinteger Sí total_centsinteger Sí deposit_centsinteger Sí amount_due_centsinteger Sí insurance_statusstring (not_required, required, submitted, approved, rejected) Sí checkpointsobject Sí datesarray of object Sí urlstring Sí
ReservationRequest object
ReservationRequest Propiedad Tipo Obligatorio Descripción facilitystring Sí Facility slug householdstring No H-number; defaults to the token user's active household modestring (once, weekly, dates) No datestring (date) No daysarray of integer No ISO weekdays for mode=weekly untilstring (date) No datesarray of string (date) No startstring Sí Agency-local time, 15-minute steps endstring Sí purposestring (private, nonprofit, school, commercial) No attendeesinteger Sí titlestring No organisationstring No notesstring No on_conflictstring (block, drop) No agreementobject No Optional: sign the rental agreement now
Roster object
Roster Propiedad Tipo Obligatorio Descripción dataobject No metaMeta No
RosterParticipant object
RosterParticipant Propiedad Tipo Obligatorio Descripción enrollment_idinteger Sí person_idinteger Sí first_namestring Sí last_namestring Sí ageinteger | null No householdstring No allergyboolean Sí allergy_notestring | null No Only for users with medical.view at the session's location; each read is audited. guardian_phonestring | null No emergency_contactsarray of object No authorized_pickupsarray of string No checkin_codestring Sí Code on the participant's QR pass, for check-in.