curl -X POST "https://api.fitsociety.io/public/v1/workout/clients/{clientId}/plans/freestyle-history/workout/{sessionId}" \
-H "Authorization: Bearer <access_token>" \
-H "Idempotency-Key: <stable_request_key>" \
-H "Content-Type: application/json" \
-d '{}'const options = {
method: 'POST',
headers: {
'Idempotency-Key': '<idempotency-key>',
Authorization: 'Bearer <token>',
'Content-Type': 'application/json'
},
body: JSON.stringify({clientId: '67f1234567890abcdef9999'})
};
fetch('https://api.fitsociety.io/public/v1/workout/clients/{clientId}/plans/freestyle-history/workout/{sessionId}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.fitsociety.io/public/v1/workout/clients/{clientId}/plans/freestyle-history/workout/{sessionId}"
payload = { "clientId": "67f1234567890abcdef9999" }
headers = {
"Idempotency-Key": "<idempotency-key>",
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text){
"data": {
"workout": {
"_id": "67f1234567890abcdef1234",
"sessionId": "67f1234567890abcdef1234",
"name": "Freestyle Workout 2",
"date": "2026-04-12T10:00:00.000Z",
"durationMinutes": 50,
"totalVolume": 287,
"totalReps": 181,
"totalTimeSeconds": 0,
"totalDistanceMeters": 0,
"rating": 4,
"emojiRating": 4,
"emoji": "💪",
"exerciseCount": 9,
"exercises": [
{
"type": "exercise",
"planExerciseId": "67f1234567890abcdef1234",
"exerciseId": "67f1234567890abcdef1234",
"name": "Dumbbell Bench Press",
"description": "Example description",
"thumbnail": "https://cdn.example.com/exercises/bench.jpg",
"primaryMuscle": "chest",
"secondaryMuscles": [
"string"
],
"equipment": [
"string"
],
"groupId": "",
"order": 0,
"isFavourite": false,
"isPersonalRecord": true,
"prVerified": true,
"prRank": 1,
"targets": {
"type": "string",
"sets": 1,
"reps": "string",
"rest": 1,
"rpe": 1,
"rmPercentage": 1,
"tempo": "string",
"notes": "string"
},
"previousBestSet": {
"reps": 1,
"weight": 1,
"timeSeconds": 1,
"distanceMeters": 1,
"rpe": 1,
"setNumber": 1
},
"performanceId": "67f1234567890abcdef1234",
"isCompleted": true,
"notes": "",
"clientNotes": "Felt strong today.",
"clientRestSeconds": 90,
"sets": [
{
"setNumber": 1,
"setType": "N",
"previous": {
"reps": 1,
"weight": 1,
"timeSeconds": 1,
"distanceMeters": 1,
"rpe": 1
},
"reps": 15,
"weight": 20,
"timeSeconds": 1,
"distanceMeters": 1,
"restSeconds": 60,
"rpe": 1,
"completed": true,
"isPersonalRecord": false,
"prVerified": false,
"prRank": 1,
"repsPlaceholderCoach": 10,
"weightPlaceholderCoach": 40,
"timeSecondsPlaceholderCoach": null,
"distanceMetersPlaceholderCoach": null,
"rpePlaceholderCoach": 7,
"restSecondsPlaceholderCoach": 90,
"repsPlaceholder": 10,
"weightPlaceholder": 40,
"timeSecondsPlaceholder": null,
"distanceMetersPlaceholder": null,
"rpePlaceholder": 7,
"restSecondsPlaceholder": 90,
"repsActual": 30,
"weightActual": 42,
"timeSecondsActual": null,
"distanceMetersActual": null,
"rpeActual": 8,
"restSecondsActual": 90
}
],
"exerciseCount": 2,
"rounds": 3,
"data": [
{
"id": "67f1234567890abcdef1234",
"name": "Barbell Bench Press",
"primaryMuscle": "Chest",
"secondaryMuscles": [
"Chest"
],
"primaryJoint": "Shoulder",
"equipment": [
"Dumbbells"
],
"difficulty": "Intermediate",
"intensity": "Above Average",
"visibility": "Company",
"tags": [
"string"
],
"thumbnail": "https://cdn.example.com/exercises/bench-thumb.jpg"
}
]
}
]
}
},
"meta": {
"requestId": "4f849d7d-f4f1-45cc-b4b7-3984a3d17f83",
"rateLimit": {
"limit": 10,
"remaining": 9,
"resetSeconds": 1
},
"idempotency": {
"replayed": false
}
}
}Single freestyle workout — freestyle History detail
Detail for ONE completed freestyle workout — the SAME object shape as a single element of workouts[] in the freestyle History feed tab (POST /app/v1/workout/plans/client/freestyle-history). Returns { workout } with its grouped exercises[] (standalone + superset blocks), the ‘Previous’ column, and per-set + exercise-level PR flags (targets is null for freestyle). The ‘Freestyle Workout N’ number is the session’s position among all the client’s completed freestyle sessions (oldest = 1), identical to the feed. A coach passes clientId in the body; a client resolves from token.
Requires the workout_progress:read scope. This operation maps to /app/v1/workout/plans/client/freestyle-history/workout/:sessionId and retains its Workout V2 permission, feature-flag, and resource-scope checks.
The clientId path parameter identifies the client represented by the request context.
curl -X POST "https://api.fitsociety.io/public/v1/workout/clients/{clientId}/plans/freestyle-history/workout/{sessionId}" \
-H "Authorization: Bearer <access_token>" \
-H "Idempotency-Key: <stable_request_key>" \
-H "Content-Type: application/json" \
-d '{}'const options = {
method: 'POST',
headers: {
'Idempotency-Key': '<idempotency-key>',
Authorization: 'Bearer <token>',
'Content-Type': 'application/json'
},
body: JSON.stringify({clientId: '67f1234567890abcdef9999'})
};
fetch('https://api.fitsociety.io/public/v1/workout/clients/{clientId}/plans/freestyle-history/workout/{sessionId}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.fitsociety.io/public/v1/workout/clients/{clientId}/plans/freestyle-history/workout/{sessionId}"
payload = { "clientId": "67f1234567890abcdef9999" }
headers = {
"Idempotency-Key": "<idempotency-key>",
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text){
"data": {
"workout": {
"_id": "67f1234567890abcdef1234",
"sessionId": "67f1234567890abcdef1234",
"name": "Freestyle Workout 2",
"date": "2026-04-12T10:00:00.000Z",
"durationMinutes": 50,
"totalVolume": 287,
"totalReps": 181,
"totalTimeSeconds": 0,
"totalDistanceMeters": 0,
"rating": 4,
"emojiRating": 4,
"emoji": "💪",
"exerciseCount": 9,
"exercises": [
{
"type": "exercise",
"planExerciseId": "67f1234567890abcdef1234",
"exerciseId": "67f1234567890abcdef1234",
"name": "Dumbbell Bench Press",
"description": "Example description",
"thumbnail": "https://cdn.example.com/exercises/bench.jpg",
"primaryMuscle": "chest",
"secondaryMuscles": [
"string"
],
"equipment": [
"string"
],
"groupId": "",
"order": 0,
"isFavourite": false,
"isPersonalRecord": true,
"prVerified": true,
"prRank": 1,
"targets": {
"type": "string",
"sets": 1,
"reps": "string",
"rest": 1,
"rpe": 1,
"rmPercentage": 1,
"tempo": "string",
"notes": "string"
},
"previousBestSet": {
"reps": 1,
"weight": 1,
"timeSeconds": 1,
"distanceMeters": 1,
"rpe": 1,
"setNumber": 1
},
"performanceId": "67f1234567890abcdef1234",
"isCompleted": true,
"notes": "",
"clientNotes": "Felt strong today.",
"clientRestSeconds": 90,
"sets": [
{
"setNumber": 1,
"setType": "N",
"previous": {
"reps": 1,
"weight": 1,
"timeSeconds": 1,
"distanceMeters": 1,
"rpe": 1
},
"reps": 15,
"weight": 20,
"timeSeconds": 1,
"distanceMeters": 1,
"restSeconds": 60,
"rpe": 1,
"completed": true,
"isPersonalRecord": false,
"prVerified": false,
"prRank": 1,
"repsPlaceholderCoach": 10,
"weightPlaceholderCoach": 40,
"timeSecondsPlaceholderCoach": null,
"distanceMetersPlaceholderCoach": null,
"rpePlaceholderCoach": 7,
"restSecondsPlaceholderCoach": 90,
"repsPlaceholder": 10,
"weightPlaceholder": 40,
"timeSecondsPlaceholder": null,
"distanceMetersPlaceholder": null,
"rpePlaceholder": 7,
"restSecondsPlaceholder": 90,
"repsActual": 30,
"weightActual": 42,
"timeSecondsActual": null,
"distanceMetersActual": null,
"rpeActual": 8,
"restSecondsActual": 90
}
],
"exerciseCount": 2,
"rounds": 3,
"data": [
{
"id": "67f1234567890abcdef1234",
"name": "Barbell Bench Press",
"primaryMuscle": "Chest",
"secondaryMuscles": [
"Chest"
],
"primaryJoint": "Shoulder",
"equipment": [
"Dumbbells"
],
"difficulty": "Intermediate",
"intensity": "Above Average",
"visibility": "Company",
"tags": [
"string"
],
"thumbnail": "https://cdn.example.com/exercises/bench-thumb.jpg"
}
]
}
]
}
},
"meta": {
"requestId": "4f849d7d-f4f1-45cc-b4b7-3984a3d17f83",
"rateLimit": {
"limit": 10,
"remaining": 9,
"resetSeconds": 1
},
"idempotency": {
"replayed": false
}
}
}Authorizations
Public API access token issued by /public/v1/oauth/token. Example: Authorization: Bearer fspt_.... Each resource request rechecks the token company's current provider access. Disabling access blocks existing tokens with 403 auth.provider_unavailable.
Headers
Required for Public API write requests. Reusing the same key with the same method, path, and body replays the stored successful response; reusing it with a different request returns 409 idempotency.conflict.
1 - 200"booking-create-20260714-001"
Path Parameters
Completed freestyle WorkoutSessionInstance id.
"67f1234567890abcdef1234"
Client in the company bound to the Public API token.
^[a-fA-F0-9]{24}$Body
Required when the caller is a coach; inferred from token when the caller is a client.
"67f1234567890abcdef1234"