Exercises
Function-calling namespace: exercises
- Base URL:
https://api.aivida.in - Engine endpoint:
POST /api - Auth: Stack token middleware enabled in
optionalmode. - Send token in header:
x-stack-access-token: <access_token>(orAuthorization: Bearer <access_token>). - In
optionalmode: no token is allowed; invalid token is rejected with401.
create
Source: backend/endpoints/exercises/create
Input Fields
| Field | Type | Required |
|---|---|---|
name | string | Yes |
category | string | No |
body_part | string | No |
equipment | string | No |
difficulty | string | No |
description | string | No |
steps | []string | Yes |
tips | []string | No |
image_url | string | No |
video_url | string | No |
Example Request
curl -X POST https://api.aivida.in/api \
-H "Content-Type: application/json" \
-H "x-stack-access-token: <access_token_optional>" \
-d '{
"namespace": "exercises",
"apiName": "create",
"data": {
"name": "value",
"steps": []
}
}'Example Response
{ "status": "ok", "data": {} }delete
Source: backend/endpoints/exercises/delete
Input Fields
| Field | Type | Required |
|---|---|---|
id | string | Yes |
Example Request
curl -X POST https://api.aivida.in/api \
-H "Content-Type: application/json" \
-H "x-stack-access-token: <access_token_optional>" \
-d '{
"namespace": "exercises",
"apiName": "delete",
"data": {
"id": "id_123"
}
}'Example Response
{ "status": "ok", "data": {} }get
Source: backend/endpoints/exercises/get
Input Fields
| Field | Type | Required |
|---|---|---|
id | string | Yes |
Example Request
curl -X POST https://api.aivida.in/api \
-H "Content-Type: application/json" \
-H "x-stack-access-token: <access_token_optional>" \
-d '{
"namespace": "exercises",
"apiName": "get",
"data": {
"id": "id_123"
}
}'Example Response
{ "status": "ok", "data": {} }list
Source: backend/endpoints/exercises/list
Input Fields
| Field | Type | Required |
|---|---|---|
page | int | No |
page_size | int | No |
Example Request
curl -X POST https://api.aivida.in/api \
-H "Content-Type: application/json" \
-H "x-stack-access-token: <access_token_optional>" \
-d '{
"namespace": "exercises",
"apiName": "list",
"data": {
"page": 1,
"page_size": 1
}
}'Example Response
{ "status": "ok", "data": {} }search
Source: backend/endpoints/exercises/search
Input Fields
| Field | Type | Required |
|---|---|---|
query | string | No |
category | string | No |
body_part | string | No |
equipment | string | No |
difficulty | string | No |
Example Request
curl -X POST https://api.aivida.in/api \
-H "Content-Type: application/json" \
-H "x-stack-access-token: <access_token_optional>" \
-d '{
"namespace": "exercises",
"apiName": "search",
"data": {
"query": "value",
"category": "value",
"body_part": "value",
"equipment": "value",
"difficulty": "value"
}
}'Example Response
{ "status": "ok", "data": {} }update
Source: backend/endpoints/exercises/update
Input Fields
| Field | Type | Required |
|---|---|---|
id | string | Yes |
name | *string | No |
category | *string | No |
body_part | *string | No |
equipment | *string | No |
difficulty | *string | No |
description | *string | No |
steps | *[]string | No |
tips | *[]string | No |
image_url | *string | No |
video_url | *string | No |
Example Request
curl -X POST https://api.aivida.in/api \
-H "Content-Type: application/json" \
-H "x-stack-access-token: <access_token_optional>" \
-d '{
"namespace": "exercises",
"apiName": "update",
"data": {
"id": "id_123"
}
}'Example Response
{ "status": "ok", "data": {} }