Venue Manager API
Run the day-to-day work of a venue from your own software: bookings, payments, lockers, rentals, memberships, games, classes, students, fees and attendance. The same operations are available to AI apps as MCP tools. The API never deletes records and never changes how a product is set up; do that in Venue Manager.
Base URL https://www.sporfy.com/vm/v1
Authentication
Create a key in Venue Manager under Settings › Developers › API keys. A key is an App ID and an App Secret; send both on every request, over HTTPS, from your server only. The secret is shown once and stored hashed. A key can have Off, Read or Read & write access per product, an expiry and a list of allowed IP addresses.
curl -X GET "https://www.sporfy.com/vm/v1/spaces" \ -H "X-App-Id: YOUR_APP_ID" \ -H "X-App-Secret: YOUR_APP_SECRET"
Plans and rate limits
API and MCP access is included from the Professional plan, product by product (Slots or Classes). Without it, keys and servers cannot be created or changed and every call answers 402. Nothing is deleted; upgrade and everything works again. Limits are per organisation, shared by every key and AI app, and can be raised with an add-on.
| Plan | Requests a minute | Requests a day | Calls at once |
|---|---|---|---|
| Standard | Not included | ||
| Professional | 60 | 5,000 | 5 |
| Premium | 120 | 15,000 | 10 |
| Enterprise | 300+ | 50,000+ | 25+ |
Every answer carries X-RateLimit-Limit, X-RateLimit-Remaining and X-RateLimit-Reset. Past a limit the answer is 429 with Retry-After in seconds; the day resets at midnight UTC.
Errors
{
"error": {
"code": "plan_required",
"message": "API and MCP access needs Professional or above."
},
"requestId": "9f1c2ab04d7e4c5e8a31b6d0c2f47e11"
}| Status | Code | Meaning |
|---|---|---|
| 401 | invalid_credentials, key_revoked, key_expired | The key or secret is wrong, revoked or past its expiry. |
| 402 | plan_required | The product is not on Professional or above. |
| 403 | ip_not_allowed, https_required | The key may not be used from this address, or the request was not over https. |
| 404 | unknown_tool, tool_not_allowed | No such endpoint for this key, or no such record in your organisation. |
| 409 | already_marked, … | The change conflicts with the current state. Nothing was changed. |
| 422 | invalid_arguments | An argument is missing or wrong. The details name the field. |
| 429 | rate_limited, daily_limit_reached, too_many_concurrent_calls | A rate limit was reached. Wait for Retry-After. |
Security
- A key belongs to one organisation and can never reach another organisation's data.
- Keys and AI-app tokens work only on the endpoints in this reference. Sent anywhere else on Sporfy they are refused.
- Use https only. Plain http is refused in production, and answers are never cached.
- The allowed-IP list checks the address our edge saw, not an
X-Forwarded-Forheader you send. - Rotate a key at any time; the old secret stops working at once. Revoke it to stop it entirely.
Connect an AI app
Create an MCP server in Settings › Developers › MCP servers, pick its tools and paste its address (https://www.sporfy.com/vm/mcp/<token>) into Claude, ChatGPT or any app that supports MCP connectors. Each person signs in and approves with OAuth 2.1 and PKCE, and the app then acts as that person: only the server's tools, only what their role allows, only while the plan includes it. Owners can see and revoke every connected app, limit who may connect by role, or regenerate the address to sign everyone out.
Classes
Attendance
List a class's attendance for a day
List the attendance marked for a class on one day.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
class_id | string | Yes | Id of the class, from classes.list. |
Query parameters
| Name | Type | Required | Description |
|---|---|---|---|
date | string | Yes | Day, YYYY-MM-DD. |
The same endpoint is offered to AI apps as the tool classes.attendance.
curl -X GET "https://www.sporfy.com/vm/v1/classes/<class_id>/attendance?date=2026-11-02" \ -H "X-App-Id: YOUR_APP_ID" \ -H "X-App-Secret: YOUR_APP_SECRET"
HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: 9f1c2ab04d7e4c5e8a31b6d0c2f47e11
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 59
X-RateLimit-Reset: 60
{ …a JSON object with this endpoint's result… }Correct an attendance mark
Change an existing mark between present and absent. A session-pack student's sessions used are adjusted to match.
Changes data. The key needs Read & write access on the product.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
attendance_id | string | Yes | Id of the attendance mark, from classes.attendance. |
Body (JSON)
| Name | Type | Required | Description |
|---|---|---|---|
present | boolean | Yes | The corrected value. |
The same endpoint is offered to AI apps as the tool classes.change_attendance.
curl -X PUT "https://www.sporfy.com/vm/v1/attendance/<attendance_id>" \
-H "X-App-Id: YOUR_APP_ID" \
-H "X-App-Secret: YOUR_APP_SECRET" \
-H "Content-Type: application/json" \
-d '{
"present": false
}'HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: 9f1c2ab04d7e4c5e8a31b6d0c2f47e11
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 59
X-RateLimit-Reset: 60
{ …a JSON object with this endpoint's result… }Mark attendance
Mark students present or absent for a class on a day (and session). Nothing is written if any student is not in the class or already has a mark for that day and session; correct an existing mark with classes.change_attendance. A present mark uses one session for session-pack students.
Changes data. The key needs Read & write access on the product.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
class_id | string | Yes | Id of the class, from classes.list. |
Body (JSON)
| Name | Type | Required | Description |
|---|---|---|---|
date | string | Yes | Day, YYYY-MM-DD. |
session_id | string | No | Id of the session, from classes.sessions. Required for session-based spaces. |
marks | object[] | Yes | One entry per student. |
The same endpoint is offered to AI apps as the tool classes.mark_attendance.
curl -X POST "https://www.sporfy.com/vm/v1/classes/<class_id>/attendance" \
-H "X-App-Id: YOUR_APP_ID" \
-H "X-App-Secret: YOUR_APP_SECRET" \
-H "Content-Type: application/json" \
-d '{
"date": "2026-11-02",
"marks": [
{
"student_id": "<student_id>",
"present": false
}
]
}'HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: 9f1c2ab04d7e4c5e8a31b6d0c2f47e11
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 59
X-RateLimit-Reset: 60
{ …a JSON object with this endpoint's result… }Classes
List batches of a class
List the batches of a class. A student is enrolled into one batch.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
class_id | string | Yes | Id of the class, from classes.list. |
The same endpoint is offered to AI apps as the tool classes.batches.
curl -X GET "https://www.sporfy.com/vm/v1/classes/<class_id>/batches" \ -H "X-App-Id: YOUR_APP_ID" \ -H "X-App-Secret: YOUR_APP_SECRET"
HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: 9f1c2ab04d7e4c5e8a31b6d0c2f47e11
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 59
X-RateLimit-Reset: 60
{ …a JSON object with this endpoint's result… }Get a class
Get one class with its fee plans, enrolment count and batches.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
class_id | string | Yes | Id of the class, from classes.list. |
The same endpoint is offered to AI apps as the tool classes.get.
curl -X GET "https://www.sporfy.com/vm/v1/classes/<class_id>" \ -H "X-App-Id: YOUR_APP_ID" \ -H "X-App-Secret: YOUR_APP_SECRET"
HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: 9f1c2ab04d7e4c5e8a31b6d0c2f47e11
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 59
X-RateLimit-Reset: 60
{ …a JSON object with this endpoint's result… }List classes
List the organisation's classes with their status, how many students are enrolled and the fee plans each offers.
Query parameters
| Name | Type | Required | Description |
|---|---|---|---|
space_id | string | No | Only the classes run from this space, from spaces.list. |
status | string | No | Only classes with this status, for example active. |
skip | integer | No | Classes to skip, for paging. Default: 0. |
limit | integer | No | Classes to return. Default: 50. |
The same endpoint is offered to AI apps as the tool classes.list.
curl -X GET "https://www.sporfy.com/vm/v1/classes" \ -H "X-App-Id: YOUR_APP_ID" \ -H "X-App-Secret: YOUR_APP_SECRET"
HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: 9f1c2ab04d7e4c5e8a31b6d0c2f47e11
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 59
X-RateLimit-Reset: 60
{ …a JSON object with this endpoint's result… }List a class's sessions on a day
List the sessions a class holds on one day, with their times, batch, instructors and status. Use a session's id when marking attendance for session-based classes.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
class_id | string | Yes | Id of the class, from classes.list. |
Query parameters
| Name | Type | Required | Description |
|---|---|---|---|
date | string | Yes | Day to list, YYYY-MM-DD. |
The same endpoint is offered to AI apps as the tool classes.sessions.
curl -X GET "https://www.sporfy.com/vm/v1/classes/<class_id>/sessions?date=2026-11-02" \ -H "X-App-Id: YOUR_APP_ID" \ -H "X-App-Secret: YOUR_APP_SECRET"
HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: 9f1c2ab04d7e4c5e8a31b6d0c2f47e11
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 59
X-RateLimit-Reset: 60
{ …a JSON object with this endpoint's result… }Edit a class's description and overview
Change the words on an existing class: its display name, description, overview and terms and conditions. Only the fields you give are changed; give the whole new text for each (the old text is replaced, so read it first with classes.get to add to it). Fees, timings, batches, capacity and status cannot be changed here.
Changes data. The key needs Read & write access on the product.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
class_id | string | Yes | Id of the class, from classes.list. |
Body (JSON)
| Name | Type | Required | Description |
|---|---|---|---|
display_name | string | No | The name shown to customers on the class page. |
description | string | No | Short description shown on the class page and in listings. Plain text. |
overview | string | No | The longer 'about this class' text. Plain text. |
terms_and_conditions | string | No | Terms customers accept when joining. Plain text. |
The same endpoint is offered to AI apps as the tool classes.update_details.
curl -X PATCH "https://www.sporfy.com/vm/v1/classes/<class_id>/details" \ -H "X-App-Id: YOUR_APP_ID" \ -H "X-App-Secret: YOUR_APP_SECRET"
HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: 9f1c2ab04d7e4c5e8a31b6d0c2f47e11
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 59
X-RateLimit-Reset: 60
{ …a JSON object with this endpoint's result… }Fees
Collect a student's fee
Collect one period of a student's class fee, paid now by a payment source or raised to be paid later. The amount comes from the student's fee plan on the class's price list, with tax; it cannot be set by the caller. Once paid, the student's next renewal date moves forward.
Changes data. The key needs Read & write access on the product.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
student_id | string | Yes | Id of the student, from classes.students. |
Body (JSON)
| Name | Type | Required | Description |
|---|---|---|---|
renewal_date | string | Yes | The period being paid, as the student's current nextRenewalDate from classes.student, YYYY-MM-DD. Refused if the student has moved on, so a repeated call never bills the next period. |
payment_source | string | No | How the money was received, as named in the organisation's payment sources, for example Cash or UPI. Leave out with pay_later. |
pay_later | boolean | No | Raise the fee order without payment; collect it later with orders.settle. Default: false. |
received_on | string | No | Day the money was received, YYYY-MM-DD. Defaults to now. |
send_invoice | boolean | No | Send the invoice to the student on WhatsApp and email. Default: false. |
The same endpoint is offered to AI apps as the tool classes.collect_fee.
curl -X POST "https://www.sporfy.com/vm/v1/students/<student_id>/fees" \
-H "X-App-Id: YOUR_APP_ID" \
-H "X-App-Secret: YOUR_APP_SECRET" \
-H "Content-Type: application/json" \
-d '{
"renewal_date": "2026-11-02"
}'HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: 9f1c2ab04d7e4c5e8a31b6d0c2f47e11
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 59
X-RateLimit-Reset: 60
{ …a JSON object with this endpoint's result… }Students
Enrol a student
Enrol a person into a class and batch with a fee plan. Give an existing customer's customer_id (from customers.find), or a new person's name and mobile number (an existing customer with that number is reused). For a child, give the guardian (name, mobile, relation such as father): the guardian is created or reused, linked to the child and is the one billed. If the mobile number already belongs to a customer with a different name, nothing is written until the user confirms and you repeat with confirm true. Fails if they are already in the class or the organisation's student limit is reached. The first fee is collected with classes.collect_fee.
Changes data. The key needs Read & write access on the product.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
class_id | string | Yes | Id of the class to join, from classes.list. |
Body (JSON)
| Name | Type | Required | Description |
|---|---|---|---|
customer_id | string | No | Id of an existing customer, from customers.find. Give this, or the details of a new person. |
name | string | No | Name of a new person, for example Sham. |
phone | string | No | Their mobile number. Optional for a child who has a guardian. |
country_code | string | No | Country code of the mobile number, without +. Default: "91". |
email | string | No | |
guardian | object | No | For a child: the parent or guardian, who is billed and messaged. |
confirm | boolean | No | Only after the server reports that the mobile number or email already belongs to a customer with a different name: send the same call again with confirm true once the user says it is the same person. Default: false. |
batch_id | string | Yes | Id of the batch to join, from classes.batches. |
price_id | string | No | Id of the fee plan, from classes.get prices. It sets the fee and renewal date. |
The same endpoint is offered to AI apps as the tool classes.enroll.
curl -X POST "https://www.sporfy.com/vm/v1/classes/<class_id>/students" \
-H "X-App-Id: YOUR_APP_ID" \
-H "X-App-Secret: YOUR_APP_SECRET" \
-H "Content-Type: application/json" \
-d '{
"batch_id": "<batch_id>"
}'HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: 9f1c2ab04d7e4c5e8a31b6d0c2f47e11
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 59
X-RateLimit-Reset: 60
{ …a JSON object with this endpoint's result… }Change a student's status
Change a student's status, with a reason and effective date, and record it in their history. A past student is not billed; their fee plan is kept so they can rejoin.
Changes data. The key needs Read & write access on the product.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
student_id | string | Yes | Id of the student, from classes.students or classes.enroll. |
Body (JSON)
| Name | Type | Required | Description |
|---|---|---|---|
status | string | Yes | New status: active, inactive, past, suspended or blocked. |
reason | string | No | Reason, from the console's list for the status, for example 'Completed Course' for past. |
effective_date | string | No | Day the change takes effect, YYYY-MM-DD. Defaults to today. |
The same endpoint is offered to AI apps as the tool classes.set_student_status.
curl -X PUT "https://www.sporfy.com/vm/v1/students/<student_id>/status" \
-H "X-App-Id: YOUR_APP_ID" \
-H "X-App-Secret: YOUR_APP_SECRET" \
-H "Content-Type: application/json" \
-d '{
"status": "<status>"
}'HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: 9f1c2ab04d7e4c5e8a31b6d0c2f47e11
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 59
X-RateLimit-Reset: 60
{ …a JSON object with this endpoint's result… }Get a student
Get one student with their fee plan, next renewal date and remaining sessions.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
student_id | string | Yes | Id of the student, from classes.students or classes.enroll. |
The same endpoint is offered to AI apps as the tool classes.student.
curl -X GET "https://www.sporfy.com/vm/v1/students/<student_id>" \ -H "X-App-Id: YOUR_APP_ID" \ -H "X-App-Secret: YOUR_APP_SECRET"
HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: 9f1c2ab04d7e4c5e8a31b6d0c2f47e11
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 59
X-RateLimit-Reset: 60
{ …a JSON object with this endpoint's result… }List students of a class
List the students in a class with their status, batch, fee plan and next renewal date.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
class_id | string | Yes | Id of the class, from classes.list. |
Query parameters
| Name | Type | Required | Description |
|---|---|---|---|
status | string | No | Only students with this status: active, inactive, past, suspended or blocked. |
skip | integer | No | Students to skip, for paging. Default: 0. |
limit | integer | No | Students to return. Default: 100. |
The same endpoint is offered to AI apps as the tool classes.students.
curl -X GET "https://www.sporfy.com/vm/v1/classes/<class_id>/students" \ -H "X-App-Id: YOUR_APP_ID" \ -H "X-App-Secret: YOUR_APP_SECRET"
HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: 9f1c2ab04d7e4c5e8a31b6d0c2f47e11
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 59
X-RateLimit-Reset: 60
{ …a JSON object with this endpoint's result… }Customers
Customers
Find a customer
Find the organisation's existing customers by name, mobile number or email. Use the returned id as customer_id when booking, enrolling or charging, so nobody is entered twice. If nobody matches, give the new person's details to that tool instead and they are created; for a child, add a guardian.
Query parameters
| Name | Type | Required | Description |
|---|---|---|---|
query | string | Yes | Part of a name, a mobile number or an email address. |
limit | integer | No | Default: 10. |
The same endpoint is offered to AI apps as the tool customers.find.
curl -X GET "https://www.sporfy.com/vm/v1/customers?query=%3Cquery%3E" \ -H "X-App-Id: YOUR_APP_ID" \ -H "X-App-Secret: YOUR_APP_SECRET"
HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: 9f1c2ab04d7e4c5e8a31b6d0c2f47e11
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 59
X-RateLimit-Reset: 60
{ …a JSON object with this endpoint's result… }Slots
Games
Add a walk-in player
Add a player who has no account to a game. Fails if the game is full or the mobile number is already on it. Payment is not taken here.
Changes data. The key needs Read & write access on the product.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
game_id | string | Yes | Id of the game, from games.list or games.create. |
Body (JSON)
| Name | Type | Required | Description |
|---|---|---|---|
name | string | Yes | The walk-in's name. |
mobile | string | No | Their mobile number. |
email | string | No | Their email address. |
seats | integer | No | Seats they take. Default: 1. |
The same endpoint is offered to AI apps as the tool games.add_walk_in.
curl -X POST "https://www.sporfy.com/vm/v1/games/<game_id>/walk-ins" \
-H "X-App-Id: YOUR_APP_ID" \
-H "X-App-Secret: YOUR_APP_SECRET" \
-H "Content-Type: application/json" \
-d '{
"name": "<name>"
}'HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: 9f1c2ab04d7e4c5e8a31b6d0c2f47e11
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 59
X-RateLimit-Reset: 60
{ …a JSON object with this endpoint's result… }Cancel a game
Cancel a game and free the courts it held. Refused while players are on it, so nobody who has joined or paid is dropped without being removed first.
Changes data. The key needs Read & write access on the product.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
game_id | string | Yes | Id of the game, from games.list or games.create. |
The same endpoint is offered to AI apps as the tool games.cancel.
curl -X DELETE "https://www.sporfy.com/vm/v1/games/<game_id>" \ -H "X-App-Id: YOUR_APP_ID" \ -H "X-App-Secret: YOUR_APP_SECRET"
HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: 9f1c2ab04d7e4c5e8a31b6d0c2f47e11
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 59
X-RateLimit-Reset: 60
{ …a JSON object with this endpoint's result… }Complete a game
Close a game that has been played so its players are recorded as having played. Safe to repeat.
Changes data. The key needs Read & write access on the product.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
game_id | string | Yes | Id of the game, from games.list or games.create. |
The same endpoint is offered to AI apps as the tool games.complete.
curl -X POST "https://www.sporfy.com/vm/v1/games/<game_id>/complete" \ -H "X-App-Id: YOUR_APP_ID" \ -H "X-App-Secret: YOUR_APP_SECRET"
HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: 9f1c2ab04d7e4c5e8a31b6d0c2f47e11
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 59
X-RateLimit-Reset: 60
{ …a JSON object with this endpoint's result… }Create a game
Create a game hosted by the organisation and block the chosen fields for its window. Fails with slot_unavailable, and creates nothing, if any of the fields is already taken during that time.
Changes data. The key needs Read & write access on the product.
Body (JSON)
| Name | Type | Required | Description |
|---|---|---|---|
space_id | string | Yes | Id of the space hosting the game, from spaces.list. |
listing_id | string | Yes | Id of the sport the game is for. It must be one of the organisation's own sports. |
name | string | Yes | Name of the game. |
date | string | Yes | Day of the game, YYYY-MM-DD, on the venue's calendar. |
start_time | string | Yes | Start on the venue's clock, 24-hour HH:MM. |
end_time | string | Yes | End on the venue's clock, 24-hour HH:MM. |
field_ids | string[] | Yes | Ids of the fields (courts) the game holds, from fields.list. Each is blocked for the window. |
game_type | string | No | casual, competitive, match, practice or tournament. A match always has two sides. Default: "casual". |
participation_type | string | No | individual or team. Default: "individual". |
max_participants | integer | No | Seats for individual games. |
team_count | integer | No | Number of teams for team games. |
max_participants_per_team | integer | No | Players per team. |
cost_per_participant | number | No | Price per player. Setting a price turns on payment. |
privacy | string | No | PUBLIC or PRIVATE. Default: "PUBLIC". |
description | string | No | What players should know. |
The same endpoint is offered to AI apps as the tool games.create.
curl -X POST "https://www.sporfy.com/vm/v1/games" \
-H "X-App-Id: YOUR_APP_ID" \
-H "X-App-Secret: YOUR_APP_SECRET" \
-H "Content-Type: application/json" \
-d '{
"space_id": "<space_id>",
"listing_id": "<listing_id>",
"name": "<name>",
"date": "2026-11-02",
"start_time": "18:00",
"end_time": "18:00",
"field_ids": [
"<field_ids>"
]
}'HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: 9f1c2ab04d7e4c5e8a31b6d0c2f47e11
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 59
X-RateLimit-Reset: 60
{ …a JSON object with this endpoint's result… }Get a game
Get one game with its schedule, price, courts held and the count of players, requests and walk-ins.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
game_id | string | Yes | Id of the game, from games.list or games.create. |
The same endpoint is offered to AI apps as the tool games.get.
curl -X GET "https://www.sporfy.com/vm/v1/games/<game_id>" \ -H "X-App-Id: YOUR_APP_ID" \ -H "X-App-Secret: YOUR_APP_SECRET"
HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: 9f1c2ab04d7e4c5e8a31b6d0c2f47e11
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 59
X-RateLimit-Reset: 60
{ …a JSON object with this endpoint's result… }List games
List the games a space hosts: upcoming, ongoing or past, with how many are playing.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
space_id | string | Yes | Id of the space, from spaces.list. |
Query parameters
| Name | Type | Required | Description |
|---|---|---|---|
status | string | No | upcoming, ongoing or past. Default: "upcoming". |
search | string | No | Only games whose name starts with this text. |
page | integer | No | Page number, starting at 0. Default: 0. |
limit | integer | No | Games per page. Default: 20. |
The same endpoint is offered to AI apps as the tool games.list.
curl -X GET "https://www.sporfy.com/vm/v1/spaces/<space_id>/games" \ -H "X-App-Id: YOUR_APP_ID" \ -H "X-App-Secret: YOUR_APP_SECRET"
HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: 9f1c2ab04d7e4c5e8a31b6d0c2f47e11
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 59
X-RateLimit-Reset: 60
{ …a JSON object with this endpoint's result… }List a game's players
List the people on a game with the given status, including walk-ins when listing those playing, with their contact details and registration answers.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
game_id | string | Yes | Id of the game, from games.list or games.create. |
Query parameters
| Name | Type | Required | Description |
|---|---|---|---|
status | string | No | participating, requested, invited or retired. Default: "participating". |
The same endpoint is offered to AI apps as the tool games.participants.
curl -X GET "https://www.sporfy.com/vm/v1/games/<game_id>/participants" \ -H "X-App-Id: YOUR_APP_ID" \ -H "X-App-Secret: YOUR_APP_SECRET"
HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: 9f1c2ab04d7e4c5e8a31b6d0c2f47e11
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 59
X-RateLimit-Reset: 60
{ …a JSON object with this endpoint's result… }Remove a walk-in player
Take a walk-in off a game.
Changes data. The key needs Read & write access on the product.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
game_id | string | Yes | Id of the game, from games.list or games.create. |
walk_in_id | string | Yes | Id of the walk-in, from games.participants. |
The same endpoint is offered to AI apps as the tool games.remove_walk_in.
curl -X DELETE "https://www.sporfy.com/vm/v1/games/<game_id>/walk-ins/<walk_in_id>" \ -H "X-App-Id: YOUR_APP_ID" \ -H "X-App-Secret: YOUR_APP_SECRET"
HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: 9f1c2ab04d7e4c5e8a31b6d0c2f47e11
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 59
X-RateLimit-Reset: 60
{ …a JSON object with this endpoint's result… }Mark attendance
Record after the game whether a player or walk-in played or did not turn up.
Changes data. The key needs Read & write access on the product.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
game_id | string | Yes | Id of the game, from games.list or games.create. |
participant_id | string | Yes | Id of a player or walk-in, from games.participants. |
Body (JSON)
| Name | Type | Required | Description |
|---|---|---|---|
turned_up | boolean | Yes | True if they played, false if they did not turn up. |
The same endpoint is offered to AI apps as the tool games.set_attendance.
curl -X PUT "https://www.sporfy.com/vm/v1/games/<game_id>/attendance/<participant_id>" \
-H "X-App-Id: YOUR_APP_ID" \
-H "X-App-Secret: YOUR_APP_SECRET" \
-H "Content-Type: application/json" \
-d '{
"turned_up": false
}'HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: 9f1c2ab04d7e4c5e8a31b6d0c2f47e11
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 59
X-RateLimit-Reset: 60
{ …a JSON object with this endpoint's result… }Mark a game full
Close a game to new players, or open it again.
Changes data. The key needs Read & write access on the product.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
game_id | string | Yes | Id of the game, from games.list or games.create. |
Body (JSON)
| Name | Type | Required | Description |
|---|---|---|---|
is_full | boolean | Yes | True to stop new players joining, false to open the game again. |
The same endpoint is offered to AI apps as the tool games.set_full.
curl -X PUT "https://www.sporfy.com/vm/v1/games/<game_id>/full" \
-H "X-App-Id: YOUR_APP_ID" \
-H "X-App-Secret: YOUR_APP_SECRET" \
-H "Content-Type: application/json" \
-d '{
"is_full": false
}'HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: 9f1c2ab04d7e4c5e8a31b6d0c2f47e11
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 59
X-RateLimit-Reset: 60
{ …a JSON object with this endpoint's result… }Approve or remove a player
Approve a player who asked to join, or remove a player from the game. Any refund for a paid place is not made here.
Changes data. The key needs Read & write access on the product.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
game_id | string | Yes | Id of the game, from games.list or games.create. |
participant_id | string | Yes | Id of the player, from games.participants. |
Body (JSON)
| Name | Type | Required | Description |
|---|---|---|---|
approve | boolean | Yes | True to let the player in, false to remove them from the game. |
The same endpoint is offered to AI apps as the tool games.set_participant_status.
curl -X PUT "https://www.sporfy.com/vm/v1/games/<game_id>/participants/<participant_id>" \
-H "X-App-Id: YOUR_APP_ID" \
-H "X-App-Secret: YOUR_APP_SECRET" \
-H "Content-Type: application/json" \
-d '{
"approve": false
}'HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: 9f1c2ab04d7e4c5e8a31b6d0c2f47e11
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 59
X-RateLimit-Reset: 60
{ …a JSON object with this endpoint's result… }Lockers
Assign a locker
Give a locker to a customer for a period. Fails if the locker is blocked or already held during any of those days. The booking is recorded as unpaid, with the amount due taken from the block's price tier; use lockers.collect_payment to record the payment.
Changes data. The key needs Read & write access on the product.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
locker_id | string | Yes | Id of the locker, from lockers.list or lockers.available. |
Body (JSON)
| Name | Type | Required | Description |
|---|---|---|---|
customer | object | Yes | |
confirm | boolean | No | Only after the server reports that the mobile number belongs to a customer with a different name: repeat with confirm true once the user says it is the same person. Default: false. |
valid_from | string | Yes | First day of the booking, YYYY-MM-DD. |
valid_to | string | Yes | Last day of the booking, YYYY-MM-DD. |
price_name | string | No | Name of the block's price tier to charge, from lockers.list. Optional when the block has one tier or the locker is given free. |
The same endpoint is offered to AI apps as the tool lockers.assign.
curl -X POST "https://www.sporfy.com/vm/v1/lockers/<locker_id>/assign" \
-H "X-App-Id: YOUR_APP_ID" \
-H "X-App-Secret: YOUR_APP_SECRET" \
-H "Content-Type: application/json" \
-d '{
"customer": {},
"valid_from": "<valid_from>",
"valid_to": "<valid_to>"
}'HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: 9f1c2ab04d7e4c5e8a31b6d0c2f47e11
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 59
X-RateLimit-Reset: 60
{ …a JSON object with this endpoint's result… }Find free lockers
List the lockers in a space that are free for every day from the first day to the last day, leaving out lockers that are blocked or held by someone during that period.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
space_id | string | Yes | Id of the space, from spaces.list. |
Query parameters
| Name | Type | Required | Description |
|---|---|---|---|
valid_from | string | Yes | First day wanted, YYYY-MM-DD. |
valid_to | string | Yes | Last day wanted, YYYY-MM-DD. |
block_id | string | No | Only the lockers in this locker block. |
The same endpoint is offered to AI apps as the tool lockers.available.
curl -X GET "https://www.sporfy.com/vm/v1/spaces/<space_id>/lockers/available?valid_from=%3Cvalid_from%3E&valid_to=%3Cvalid_to%3E" \ -H "X-App-Id: YOUR_APP_ID" \ -H "X-App-Secret: YOUR_APP_SECRET"
HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: 9f1c2ab04d7e4c5e8a31b6d0c2f47e11
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 59
X-RateLimit-Reset: 60
{ …a JSON object with this endpoint's result… }Block a locker
Take a free locker out of use, for example for repair. Fails if someone is holding it.
Changes data. The key needs Read & write access on the product.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
locker_id | string | Yes | Id of the locker. |
The same endpoint is offered to AI apps as the tool lockers.block.
curl -X POST "https://www.sporfy.com/vm/v1/lockers/<locker_id>/block" \ -H "X-App-Id: YOUR_APP_ID" \ -H "X-App-Secret: YOUR_APP_SECRET"
HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: 9f1c2ab04d7e4c5e8a31b6d0c2f47e11
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 59
X-RateLimit-Reset: 60
{ …a JSON object with this endpoint's result… }Record payment for a locker
Record that the holder has paid for a locker, in full, by a payment source such as Cash or UPI. The amount is the block's price tier chosen when the locker was assigned or renewed, plus tax; it cannot be set by the caller. Creates the order, transaction and invoice. Fails if the locker is already paid or has no price.
Changes data. The key needs Read & write access on the product.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
locker_id | string | Yes | Id of a held locker with an amount due, from lockers.assign or lockers.renew. |
Body (JSON)
| Name | Type | Required | Description |
|---|---|---|---|
payment_source | string | Yes | How the money was received, as named in the organisation's payment sources, for example Cash or UPI. |
received_on | string | No | Day the money was received, YYYY-MM-DD. Defaults to now. |
send_invoice | boolean | No | Send the invoice to the customer on WhatsApp and email. Default: false. |
The same endpoint is offered to AI apps as the tool lockers.collect_payment.
curl -X POST "https://www.sporfy.com/vm/v1/lockers/<locker_id>/payment" \
-H "X-App-Id: YOUR_APP_ID" \
-H "X-App-Secret: YOUR_APP_SECRET" \
-H "Content-Type: application/json" \
-d '{
"payment_source": "<payment_source>"
}'HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: 9f1c2ab04d7e4c5e8a31b6d0c2f47e11
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 59
X-RateLimit-Reset: 60
{ …a JSON object with this endpoint's result… }List locker holders
List the customers who currently hold a locker in a space, with the period held and what they owe.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
space_id | string | Yes | Id of the space, from spaces.list. |
The same endpoint is offered to AI apps as the tool lockers.holders.
curl -X GET "https://www.sporfy.com/vm/v1/spaces/<space_id>/lockers/holders" \ -H "X-App-Id: YOUR_APP_ID" \ -H "X-App-Secret: YOUR_APP_SECRET"
HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: 9f1c2ab04d7e4c5e8a31b6d0c2f47e11
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 59
X-RateLimit-Reset: 60
{ …a JSON object with this endpoint's result… }List lockers
List a space's locker blocks and every locker in them, with the holder, the period held, the payment status and the price tiers each block offers.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
space_id | string | Yes | Id of the space, from spaces.list. |
Query parameters
| Name | Type | Required | Description |
|---|---|---|---|
block_id | string | No | Only the lockers in this locker block. |
status | string | No | Only lockers with this status: available, booked or blocked. |
The same endpoint is offered to AI apps as the tool lockers.list.
curl -X GET "https://www.sporfy.com/vm/v1/spaces/<space_id>/lockers" \ -H "X-App-Id: YOUR_APP_ID" \ -H "X-App-Secret: YOUR_APP_SECRET"
HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: 9f1c2ab04d7e4c5e8a31b6d0c2f47e11
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 59
X-RateLimit-Reset: 60
{ …a JSON object with this endpoint's result… }Release a locker
Take a locker back from its holder so it is free again. Refused when the booking has been paid, so a payment record is never lost.
Changes data. The key needs Read & write access on the product.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
locker_id | string | Yes | Id of the locker. |
The same endpoint is offered to AI apps as the tool lockers.release.
curl -X POST "https://www.sporfy.com/vm/v1/lockers/<locker_id>/release" \ -H "X-App-Id: YOUR_APP_ID" \ -H "X-App-Secret: YOUR_APP_SECRET"
HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: 9f1c2ab04d7e4c5e8a31b6d0c2f47e11
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 59
X-RateLimit-Reset: 60
{ …a JSON object with this endpoint's result… }Renew a locker
Extend a held locker to a later last day. Fails if the locker is not held, or if someone else has it after the current booking ends. The extension is charged at the block's price tier and left unpaid until lockers.collect_payment.
Changes data. The key needs Read & write access on the product.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
locker_id | string | Yes | Id of a locker that is held, from lockers.list. |
Body (JSON)
| Name | Type | Required | Description |
|---|---|---|---|
valid_to | string | Yes | The new last day of the booking, YYYY-MM-DD. Must be after the current last day. |
price_name | string | No | Price tier to charge for the extra period. Optional when the block has one tier. When given or implied, the locker becomes unpaid for that amount. |
The same endpoint is offered to AI apps as the tool lockers.renew.
curl -X POST "https://www.sporfy.com/vm/v1/lockers/<locker_id>/renew" \
-H "X-App-Id: YOUR_APP_ID" \
-H "X-App-Secret: YOUR_APP_SECRET" \
-H "Content-Type: application/json" \
-d '{
"valid_to": "<valid_to>"
}'HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: 9f1c2ab04d7e4c5e8a31b6d0c2f47e11
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 59
X-RateLimit-Reset: 60
{ …a JSON object with this endpoint's result… }Unblock a locker
Put a blocked locker back into use. Does nothing to a locker that is not blocked.
Changes data. The key needs Read & write access on the product.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
locker_id | string | Yes | Id of the locker. |
The same endpoint is offered to AI apps as the tool lockers.unblock.
curl -X POST "https://www.sporfy.com/vm/v1/lockers/<locker_id>/unblock" \ -H "X-App-Id: YOUR_APP_ID" \ -H "X-App-Secret: YOUR_APP_SECRET"
HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: 9f1c2ab04d7e4c5e8a31b6d0c2f47e11
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 59
X-RateLimit-Reset: 60
{ …a JSON object with this endpoint's result… }Slot memberships
Add a member
Add a person to a slot membership. Give an existing customer's customer_id (from customers.find), or a new person's name and mobile number; for a child give the guardian (name, mobile, relation such as father), who is created or reused and linked. If the mobile number already belongs to a customer with a different name, nothing is written until the user confirms it is the same person and you repeat the call with confirm true. The person has no plan until you sell one with memberships.sell_plan. Fails if they are already a member of this membership, or the organisation's member limit is reached.
Changes data. The key needs Read & write access on the product.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
membership_id | string | Yes | Id of the membership to join, from memberships.list. |
Body (JSON)
| Name | Type | Required | Description |
|---|---|---|---|
customer_id | string | No | Id of an existing customer, from customers.find. Give this, or the details of a new person. |
name | string | No | Name of a new person, for example Sham. |
phone | string | No | Their mobile number. Optional for a child who has a guardian. |
country_code | string | No | Country code of the mobile number, without +. Default: "91". |
email | string | No | |
guardian | object | No | For a child: the parent or guardian, who is billed and messaged. |
confirm | boolean | No | Only after the server reports that the mobile number or email already belongs to a customer with a different name: send the same call again with confirm true once the user says it is the same person. Default: false. |
The same endpoint is offered to AI apps as the tool memberships.add_member.
curl -X POST "https://www.sporfy.com/vm/v1/memberships/<membership_id>/members" \ -H "X-App-Id: YOUR_APP_ID" \ -H "X-App-Secret: YOUR_APP_SECRET"
HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: 9f1c2ab04d7e4c5e8a31b6d0c2f47e11
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 59
X-RateLimit-Reset: 60
{ …a JSON object with this endpoint's result… }List memberships
List the slot memberships a space runs, with the plans each one sells (name, price, validity, hours) and how many members are active.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
space_id | string | Yes | Id of the space, from spaces.list. |
The same endpoint is offered to AI apps as the tool memberships.list.
curl -X GET "https://www.sporfy.com/vm/v1/spaces/<space_id>/memberships" \ -H "X-App-Id: YOUR_APP_ID" \ -H "X-App-Secret: YOUR_APP_SECRET"
HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: 9f1c2ab04d7e4c5e8a31b6d0c2f47e11
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 59
X-RateLimit-Reset: 60
{ …a JSON object with this endpoint's result… }Get a member
Get one slot member with every plan they have bought, which is current and how much of it is used.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
member_id | string | Yes | Id of the member, from memberships.members or memberships.add_member. |
The same endpoint is offered to AI apps as the tool memberships.member.
curl -X GET "https://www.sporfy.com/vm/v1/members/<member_id>" \ -H "X-App-Id: YOUR_APP_ID" \ -H "X-App-Secret: YOUR_APP_SECRET"
HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: 9f1c2ab04d7e4c5e8a31b6d0c2f47e11
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 59
X-RateLimit-Reset: 60
{ …a JSON object with this endpoint's result… }List members of a membership
List the members of a slot membership with their status and plans.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
membership_id | string | Yes | Id of the membership, from memberships.list. |
Query parameters
| Name | Type | Required | Description |
|---|---|---|---|
status | string | No | Only members with this status: active, inactive or past. |
skip | integer | No | Members to skip, for paging. Default: 0. |
limit | integer | No | Members to return. Default: 50. |
The same endpoint is offered to AI apps as the tool memberships.members.
curl -X GET "https://www.sporfy.com/vm/v1/memberships/<membership_id>/members" \ -H "X-App-Id: YOUR_APP_ID" \ -H "X-App-Secret: YOUR_APP_SECRET"
HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: 9f1c2ab04d7e4c5e8a31b6d0c2f47e11
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 59
X-RateLimit-Reset: 60
{ …a JSON object with this endpoint's result… }Sell a plan to a member
Sell a membership plan to a member, paid now by a payment source or recorded to be paid later. The price is the plan's listed price plus tax and cannot be set by the caller. Creates the order and invoice and attaches the plan to the member; a plan bought while another still has hours left waits in the queue.
Changes data. The key needs Read & write access on the product.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
member_id | string | Yes | Id of the member, from memberships.members or memberships.add_member. |
Body (JSON)
| Name | Type | Required | Description |
|---|---|---|---|
plan | string | Yes | Name or price_id of the plan to sell, from memberships.list. |
payment_source | string | No | How the money was received, as named in the organisation's payment sources, for example Cash or UPI. Leave out with pay_later. |
pay_later | boolean | No | Record the plan as bought but not yet paid; collect it later with orders.settle. Default: false. |
start_date | string | No | Day the plan starts, YYYY-MM-DD. Defaults to today. |
received_on | string | No | Day the money was received, YYYY-MM-DD. Defaults to now. |
send_invoice | boolean | No | Send the invoice to the member on WhatsApp and email. Default: false. |
The same endpoint is offered to AI apps as the tool memberships.sell_plan.
curl -X POST "https://www.sporfy.com/vm/v1/members/<member_id>/plans" \
-H "X-App-Id: YOUR_APP_ID" \
-H "X-App-Secret: YOUR_APP_SECRET" \
-H "Content-Type: application/json" \
-d '{
"plan": "<plan>"
}'HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: 9f1c2ab04d7e4c5e8a31b6d0c2f47e11
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 59
X-RateLimit-Reset: 60
{ …a JSON object with this endpoint's result… }Change a member's status
Mark a member active, inactive or past. Nothing is deleted; their plans and payment history stay.
Changes data. The key needs Read & write access on the product.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
member_id | string | Yes | Id of the member. |
Body (JSON)
| Name | Type | Required | Description |
|---|---|---|---|
status | string | Yes | New status: active, inactive or past. |
The same endpoint is offered to AI apps as the tool memberships.set_member_status.
curl -X PUT "https://www.sporfy.com/vm/v1/members/<member_id>/status" \
-H "X-App-Id: YOUR_APP_ID" \
-H "X-App-Secret: YOUR_APP_SECRET" \
-H "Content-Type: application/json" \
-d '{
"status": "<status>"
}'HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: 9f1c2ab04d7e4c5e8a31b6d0c2f47e11
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 59
X-RateLimit-Reset: 60
{ …a JSON object with this endpoint's result… }Edit a membership's description and overview
Change the words on an existing slot membership: its description and overview, the same 'About' text the portal edits. Only what you give is changed; give the whole new text (read it first with memberships.list to add to it). Plans, prices, timings and rules cannot be changed here.
Changes data. The key needs Read & write access on the product.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
membership_id | string | Yes | Id of the membership, from memberships.list. |
Body (JSON)
| Name | Type | Required | Description |
|---|---|---|---|
description | string | No | Short description shown on the membership page. Plain text. |
overview | string | No | The longer 'about this membership' text. Plain text. |
The same endpoint is offered to AI apps as the tool memberships.update_details.
curl -X PATCH "https://www.sporfy.com/vm/v1/memberships/<membership_id>/details" \ -H "X-App-Id: YOUR_APP_ID" \ -H "X-App-Secret: YOUR_APP_SECRET"
HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: 9f1c2ab04d7e4c5e8a31b6d0c2f47e11
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 59
X-RateLimit-Reset: 60
{ …a JSON object with this endpoint's result… }Orders and payments
Get a payment link for an order
Get the link a customer can open to pay an unpaid order online. Asking again for the same order returns the same link. Paid orders and other organisations' orders are refused.
Changes data. The key needs Read & write access on the product.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
order_id | string | Yes | Id of an unpaid order, from orders.pending or the order a booking, locker or plan raised. |
The same endpoint is offered to AI apps as the tool orders.payment_link.
curl -X POST "https://www.sporfy.com/vm/v1/orders/<order_id>/payment-link" \ -H "X-App-Id: YOUR_APP_ID" \ -H "X-App-Secret: YOUR_APP_SECRET"
HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: 9f1c2ab04d7e4c5e8a31b6d0c2f47e11
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 59
X-RateLimit-Reset: 60
{ …a JSON object with this endpoint's result… }Unpaid orders
Orders raised and not yet paid, optionally for one customer by mobile number. Use it to see what a customer owes, then collect with orders.settle or send orders.payment_link.
Query parameters
| Name | Type | Required | Description |
|---|---|---|---|
phone | string | No | Customer's mobile number, digits only, to list what they owe. |
limit | integer | No | Most recent first. Default: 20. |
The same endpoint is offered to AI apps as the tool orders.pending.
curl -X GET "https://www.sporfy.com/vm/v1/orders/pending" \ -H "X-App-Id: YOUR_APP_ID" \ -H "X-App-Secret: YOUR_APP_SECRET"
HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: 9f1c2ab04d7e4c5e8a31b6d0c2f47e11
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 59
X-RateLimit-Reset: 60
{ …a JSON object with this endpoint's result… }Collect payment for open orders
Record that the customer has paid the outstanding amount on one or more open orders, in one payment received by a payment source such as Cash or UPI. Each order is invoiced as if paid alone. Orders that are not open for collection, or belong to another organisation, are refused.
Changes data. The key needs Read & write access on the product.
Body (JSON)
| Name | Type | Required | Description |
|---|---|---|---|
order_ids | any[] | Yes | Ids of open orders to collect together, for example the order rentals.return raised. |
payment_source | string | Yes | How the money was received, as named in the organisation's payment sources. |
The same endpoint is offered to AI apps as the tool orders.settle.
curl -X POST "https://www.sporfy.com/vm/v1/orders/settle" \
-H "X-App-Id: YOUR_APP_ID" \
-H "X-App-Secret: YOUR_APP_SECRET" \
-H "Content-Type: application/json" \
-d '{
"order_ids": [
"<order_ids>"
],
"payment_source": "<payment_source>"
}'HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: 9f1c2ab04d7e4c5e8a31b6d0c2f47e11
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 59
X-RateLimit-Reset: 60
{ …a JSON object with this endpoint's result… }Rentals
Book or hand out rentals
Book rental products for a customer: handed over now, or booked for a time you give (date, start_time, end_time). Fails with out_of_stock if the shop does not have that many free over that time. Nothing is charged yet: the rentals are priced from the time they are out when they are returned (rentals.return).
Changes data. The key needs Read & write access on the product.
Body (JSON)
| Name | Type | Required | Description |
|---|---|---|---|
date | string | No | Day the rentals are needed, YYYY-MM-DD, to book ahead. Leave out for right now. |
start_time | string | No | Start on the venue's clock, 24-hour HH:MM. Needed with date. |
end_time | string | No | End on the venue's clock, 24-hour HH:MM, after start_time. Needed with date. |
space_id | string | Yes | Space the rentals are handed out in. |
customer | object | Yes | |
confirm | boolean | No | Only after the server reports that the mobile number belongs to a customer with a different name: repeat with confirm true once the user says it is the same person. Default: false. |
slot_member_id | string | No | Id of the customer's slot membership, when they are a member. |
rentals | object[] | Yes |
The same endpoint is offered to AI apps as the tool rentals.assign.
curl -X POST "https://www.sporfy.com/vm/v1/rentals/assign" \
-H "X-App-Id: YOUR_APP_ID" \
-H "X-App-Secret: YOUR_APP_SECRET" \
-H "Content-Type: application/json" \
-d '{
"space_id": "<space_id>",
"customer": {},
"rentals": [
{
"rental_id": "<rental_id>"
}
]
}'HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: 9f1c2ab04d7e4c5e8a31b6d0c2f47e11
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 59
X-RateLimit-Reset: 60
{ …a JSON object with this endpoint's result… }Rental stock available now
List the rental products of a space that have stock left, with the quantity still free (total stock minus what is out or booked over the same time). Right now by default; give date, start_time and end_time to check a time you want to book.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
space_id | string | Yes | Id of the space (from spaces.list). |
Query parameters
| Name | Type | Required | Description |
|---|---|---|---|
date | string | No | Day the rentals are needed, YYYY-MM-DD, to book ahead. Leave out for right now. |
start_time | string | No | Start on the venue's clock, 24-hour HH:MM. Needed with date. |
end_time | string | No | End on the venue's clock, 24-hour HH:MM, after start_time. Needed with date. |
The same endpoint is offered to AI apps as the tool rentals.available.
curl -X GET "https://www.sporfy.com/vm/v1/spaces/<space_id>/rentals/available" \ -H "X-App-Id: YOUR_APP_ID" \ -H "X-App-Secret: YOUR_APP_SECRET"
HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: 9f1c2ab04d7e4c5e8a31b6d0c2f47e11
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 59
X-RateLimit-Reset: 60
{ …a JSON object with this endpoint's result… }List rental products
List the rental products of a space with their total stock and price tiers.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
space_id | string | Yes | Id of the space (from spaces.list). |
The same endpoint is offered to AI apps as the tool rentals.list.
curl -X GET "https://www.sporfy.com/vm/v1/spaces/<space_id>/rentals" \ -H "X-App-Id: YOUR_APP_ID" \ -H "X-App-Secret: YOUR_APP_SECRET"
HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: 9f1c2ab04d7e4c5e8a31b6d0c2f47e11
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 59
X-RateLimit-Reset: 60
{ …a JSON object with this endpoint's result… }Rentals currently out
List who currently has rentals out in a space (handed out in the last 48 hours and not yet returned).
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
space_id | string | Yes | Id of the space (from spaces.list). |
The same endpoint is offered to AI apps as the tool rentals.open.
curl -X GET "https://www.sporfy.com/vm/v1/spaces/<space_id>/rentals/open" \ -H "X-App-Id: YOUR_APP_ID" \ -H "X-App-Secret: YOUR_APP_SECRET"
HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: 9f1c2ab04d7e4c5e8a31b6d0c2f47e11
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 59
X-RateLimit-Reset: 60
{ …a JSON object with this endpoint's result… }Return rentals and bill
Take back everything a customer had out in one hand-out. The rentals are priced from the time they were out and one pending order is raised. Collect it with orders.settle. A usage can be returned only once.
Changes data. The key needs Read & write access on the product.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
usage_id | string | Yes | Id of the open rental usage (from rentals.open or rentals.assign). |
The same endpoint is offered to AI apps as the tool rentals.return.
curl -X POST "https://www.sporfy.com/vm/v1/rentals/usage/<usage_id>/return" \ -H "X-App-Id: YOUR_APP_ID" \ -H "X-App-Secret: YOUR_APP_SECRET"
HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: 9f1c2ab04d7e4c5e8a31b6d0c2f47e11
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 59
X-RateLimit-Reset: 60
{ …a JSON object with this endpoint's result… }Bookings
Block a time
Take a window out of sale on a field, for example for maintenance or a private event. Fails with slot_unavailable if anything already occupies that time. Undo with slots.unblock.
Changes data. The key needs Read & write access on the product.
Body (JSON)
| Name | Type | Required | Description |
|---|---|---|---|
field_id | string | Yes | Id of the field to book. Get it from fields.list. |
date | string | Yes | Day of the slot as YYYY-MM-DD, on the venue's calendar. |
start_time | string | Yes | Start on the venue's clock, 24-hour HH:MM. |
end_time | string | Yes | End on the venue's clock, 24-hour HH:MM. Must be after start_time. |
time_range_config_id | string | No | Id of the field's time range this slot follows (from fields.list). |
reason | string | No | Why the time is blocked (shown to your staff). |
The same endpoint is offered to AI apps as the tool slots.block.
curl -X POST "https://www.sporfy.com/vm/v1/slots/block" \
-H "X-App-Id: YOUR_APP_ID" \
-H "X-App-Secret: YOUR_APP_SECRET" \
-H "Content-Type: application/json" \
-d '{
"field_id": "<field_id>",
"date": "2026-11-02",
"start_time": "18:00",
"end_time": "18:00"
}'HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: 9f1c2ab04d7e4c5e8a31b6d0c2f47e11
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 59
X-RateLimit-Reset: 60
{ …a JSON object with this endpoint's result… }Book a slot
Book a window on a field for a customer, the way the console's Book slot does without taking payment: the slot is recorded as booked and unpaid. Fails with slot_unavailable if the time is taken. Needs an amount, or a time_range_config_id whose price can be used.
Changes data. The key needs Read & write access on the product.
Body (JSON)
| Name | Type | Required | Description |
|---|---|---|---|
field_id | string | Yes | Id of the field to book. Get it from fields.list. |
date | string | Yes | Day of the slot as YYYY-MM-DD, on the venue's calendar. |
start_time | string | Yes | Start on the venue's clock, 24-hour HH:MM. |
end_time | string | Yes | End on the venue's clock, 24-hour HH:MM. Must be after start_time. |
time_range_config_id | string | No | Id of the field's time range this slot follows (from fields.list). |
customer | object | Yes | |
confirm | boolean | No | Only after the server reports that the mobile number belongs to a customer with a different name: repeat with confirm true once the user says it is the same person. Default: false. |
amount | number | No | Price for the window. Defaults to the time range's own price. |
The same endpoint is offered to AI apps as the tool slots.book.
curl -X POST "https://www.sporfy.com/vm/v1/slots/book" \
-H "X-App-Id: YOUR_APP_ID" \
-H "X-App-Secret: YOUR_APP_SECRET" \
-H "Content-Type: application/json" \
-d '{
"field_id": "<field_id>",
"date": "2026-11-02",
"start_time": "18:00",
"end_time": "18:00",
"customer": {}
}'HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: 9f1c2ab04d7e4c5e8a31b6d0c2f47e11
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 59
X-RateLimit-Reset: 60
{ …a JSON object with this endpoint's result… }Cancel a slot
Cancel a booking so the time is free again. The slot stays on record as cancelled.
Changes data. The key needs Read & write access on the product.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
slot_id | string | Yes | Id of the slot. |
The same endpoint is offered to AI apps as the tool slots.cancel.
curl -X POST "https://www.sporfy.com/vm/v1/slots/<slot_id>/cancel" \ -H "X-App-Id: YOUR_APP_ID" \ -H "X-App-Secret: YOUR_APP_SECRET"
HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: 9f1c2ab04d7e4c5e8a31b6d0c2f47e11
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 59
X-RateLimit-Reset: 60
{ …a JSON object with this endpoint's result… }Record payment for a slot
Record that the customer has paid for a slot, in full, by a payment source such as Cash or UPI. The price comes from the field's time range plus tax; it cannot be set by the caller. Creates the order, transaction and invoice and links them to the slot. Fails if the slot is already paid.
Changes data. The key needs Read & write access on the product.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
slot_id | string | Yes | Id of a booked or blocked slot that has a customer, from slots.book or slots.block. |
Body (JSON)
| Name | Type | Required | Description |
|---|---|---|---|
payment_source | string | Yes | How the money was received, as named in the organisation's payment sources, for example Cash or UPI. |
received_on | string | No | Day the money was received, YYYY-MM-DD. Defaults to now. |
send_invoice | boolean | No | Send the invoice to the customer on WhatsApp and email. Default: false. |
The same endpoint is offered to AI apps as the tool slots.collect_payment.
curl -X POST "https://www.sporfy.com/vm/v1/slots/<slot_id>/payment" \
-H "X-App-Id: YOUR_APP_ID" \
-H "X-App-Secret: YOUR_APP_SECRET" \
-H "Content-Type: application/json" \
-d '{
"payment_source": "<payment_source>"
}'HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: 9f1c2ab04d7e4c5e8a31b6d0c2f47e11
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 59
X-RateLimit-Reset: 60
{ …a JSON object with this endpoint's result… }Extend a slot
Add minutes after a booking's end, priced from the field's time range and added to the slot's unpaid order. Fails with slot_unavailable if the extra time runs into another booking. Use check_only to see the price first.
Changes data. The key needs Read & write access on the product.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
slot_id | string | Yes | Id of the booked slot to extend. |
Body (JSON)
| Name | Type | Required | Description |
|---|---|---|---|
extra_minutes | integer | Yes | Minutes to add after the slot's current end. |
check_only | boolean | No | True to get the price and availability of the extension without changing anything. Default: false. |
discount_percent | number | No | Percentage discount on the extension. |
discount_note | string | No | Reason shown on the order for the discount. |
The same endpoint is offered to AI apps as the tool slots.extend.
curl -X POST "https://www.sporfy.com/vm/v1/slots/<slot_id>/extend" \
-H "X-App-Id: YOUR_APP_ID" \
-H "X-App-Secret: YOUR_APP_SECRET" \
-H "Content-Type: application/json" \
-d '{
"extra_minutes": 1
}'HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: 9f1c2ab04d7e4c5e8a31b6d0c2f47e11
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 59
X-RateLimit-Reset: 60
{ …a JSON object with this endpoint's result… }Get a slot
Fetch one slot with its customer, status, price and payment details.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
slot_id | string | Yes | Id of the slot. |
The same endpoint is offered to AI apps as the tool slots.get.
curl -X GET "https://www.sporfy.com/vm/v1/slots/<slot_id>" \ -H "X-App-Id: YOUR_APP_ID" \ -H "X-App-Secret: YOUR_APP_SECRET"
HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: 9f1c2ab04d7e4c5e8a31b6d0c2f47e11
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 59
X-RateLimit-Reset: 60
{ …a JSON object with this endpoint's result… }Hold slots
Reserve windows for a short time while a customer decides or pays. If any window is taken nothing is held. Release with slots.release_hold, or the hold frees itself when the minutes run out.
Changes data. The key needs Read & write access on the product.
Body (JSON)
| Name | Type | Required | Description |
|---|---|---|---|
windows | object[] | Yes | The windows to hold together. All or none are held. |
minutes | integer | No | How long the hold lasts before it frees itself. Default: 7. |
The same endpoint is offered to AI apps as the tool slots.hold.
curl -X POST "https://www.sporfy.com/vm/v1/slots/hold" \
-H "X-App-Id: YOUR_APP_ID" \
-H "X-App-Secret: YOUR_APP_SECRET" \
-H "Content-Type: application/json" \
-d '{
"windows": [
{
"field_id": "<field_id>",
"date": "2026-11-02",
"start_time": "18:00",
"end_time": "18:00"
}
]
}'HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: 9f1c2ab04d7e4c5e8a31b6d0c2f47e11
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 59
X-RateLimit-Reset: 60
{ …a JSON object with this endpoint's result… }List slots of a day
List the booked, blocked and held slots of a space on one day, optionally for one field. Free time is whatever the field's time ranges leave over; expired checkout holds are not listed.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
space_id | string | Yes | Id of the space (from spaces.list). |
Query parameters
| Name | Type | Required | Description |
|---|---|---|---|
date | string | Yes | Day as YYYY-MM-DD. |
field_id | string | No | Only this field's slots. |
The same endpoint is offered to AI apps as the tool slots.list.
curl -X GET "https://www.sporfy.com/vm/v1/spaces/<space_id>/slots?date=2026-11-02" \ -H "X-App-Id: YOUR_APP_ID" \ -H "X-App-Secret: YOUR_APP_SECRET"
HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: 9f1c2ab04d7e4c5e8a31b6d0c2f47e11
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 59
X-RateLimit-Reset: 60
{ …a JSON object with this endpoint's result… }Release a hold
Give held windows back before they expire. Slots that were meanwhile paid for are left untouched.
Changes data. The key needs Read & write access on the product.
Body (JSON)
| Name | Type | Required | Description |
|---|---|---|---|
hold_token | string | Yes | The hold_token slots.hold returned. |
slot_ids | string[] | Yes | The slots to release. |
The same endpoint is offered to AI apps as the tool slots.release_hold.
curl -X POST "https://www.sporfy.com/vm/v1/slots/hold/release" \
-H "X-App-Id: YOUR_APP_ID" \
-H "X-App-Secret: YOUR_APP_SECRET" \
-H "Content-Type: application/json" \
-d '{
"hold_token": "<hold_token>",
"slot_ids": [
"<slot_ids>"
]
}'HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: 9f1c2ab04d7e4c5e8a31b6d0c2f47e11
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 59
X-RateLimit-Reset: 60
{ …a JSON object with this endpoint's result… }Reschedule a slot
Move a booking to another time on the same field. Fails with slot_unavailable if the new time is taken. When the time range changes, the slot's price follows the new range.
Changes data. The key needs Read & write access on the product.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
slot_id | string | Yes | Id of the slot to move. |
Body (JSON)
| Name | Type | Required | Description |
|---|---|---|---|
date | string | Yes | New day, YYYY-MM-DD. |
start_time | string | Yes | New start, 24-hour HH:MM. |
end_time | string | Yes | New end, 24-hour HH:MM. |
time_range_config_id | string | No | The time range the new window follows, when it changes price. |
The same endpoint is offered to AI apps as the tool slots.reschedule.
curl -X POST "https://www.sporfy.com/vm/v1/slots/<slot_id>/reschedule" \
-H "X-App-Id: YOUR_APP_ID" \
-H "X-App-Secret: YOUR_APP_SECRET" \
-H "Content-Type: application/json" \
-d '{
"date": "2026-11-02",
"start_time": "18:00",
"end_time": "18:00"
}'HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: 9f1c2ab04d7e4c5e8a31b6d0c2f47e11
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 59
X-RateLimit-Reset: 60
{ …a JSON object with this endpoint's result… }Unblock a time
Remove a block made with slots.block so the time can be booked again. Only blocked slots can be unblocked; a booking is cancelled with slots.cancel.
Changes data. The key needs Read & write access on the product.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
slot_id | string | Yes | Id of the slot. |
The same endpoint is offered to AI apps as the tool slots.unblock.
curl -X DELETE "https://www.sporfy.com/vm/v1/slots/<slot_id>/block" \ -H "X-App-Id: YOUR_APP_ID" \ -H "X-App-Secret: YOUR_APP_SECRET"
HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: 9f1c2ab04d7e4c5e8a31b6d0c2f47e11
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 59
X-RateLimit-Reset: 60
{ …a JSON object with this endpoint's result… }Venues and courts
List fields of a space
List the bookable fields (courts, turfs, rooms) of one space, with their time ranges and prices. A time range's id is what slots.book and slots.block take as time_range_config_id.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
space_id | string | Yes | Id of the space (venue). Get it from spaces.list. |
The same endpoint is offered to AI apps as the tool fields.list.
curl -X GET "https://www.sporfy.com/vm/v1/spaces/<space_id>/fields" \ -H "X-App-Id: YOUR_APP_ID" \ -H "X-App-Secret: YOUR_APP_SECRET"
HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: 9f1c2ab04d7e4c5e8a31b6d0c2f47e11
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 59
X-RateLimit-Reset: 60
{ …a JSON object with this endpoint's result… }Edit a field's description and overview
Change the words on an existing bookable field: its display name, description, overview and terms and conditions. Only the fields you give are changed; give the whole new text for each (read it first with fields.list to add to it). Prices, time ranges, capacity and availability cannot be changed here.
Changes data. The key needs Read & write access on the product.
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
field_id | string | Yes | Id of the bookable field (court, turf, room), from fields.list. |
Body (JSON)
| Name | Type | Required | Description |
|---|---|---|---|
display_name | string | No | The name shown to customers. |
description | string | No | Short description shown on the booking page. Plain text. |
overview | string | No | The longer 'about this field' text. Plain text. |
terms_and_conditions | string | No | Terms customers accept when booking. Plain text. |
The same endpoint is offered to AI apps as the tool fields.update_details.
curl -X PATCH "https://www.sporfy.com/vm/v1/fields/<field_id>/details" \ -H "X-App-Id: YOUR_APP_ID" \ -H "X-App-Secret: YOUR_APP_SECRET"
HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: 9f1c2ab04d7e4c5e8a31b6d0c2f47e11
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 59
X-RateLimit-Reset: 60
{ …a JSON object with this endpoint's result… }List spaces
List every space (venue) of the organisation. Use the returned ids with the other slot tools.
No arguments.
The same endpoint is offered to AI apps as the tool spaces.list.
curl -X GET "https://www.sporfy.com/vm/v1/spaces" \ -H "X-App-Id: YOUR_APP_ID" \ -H "X-App-Secret: YOUR_APP_SECRET"
HTTP/1.1 200 OK
Content-Type: application/json
X-Request-Id: 9f1c2ab04d7e4c5e8a31b6d0c2f47e11
X-RateLimit-Limit: 60
X-RateLimit-Remaining: 59
X-RateLimit-Reset: 60
{ …a JSON object with this endpoint's result… }