Skip to main content

Reorder Session Fields (v1)

Method + Path

POST /v1/workspace/:workspaceId/sessions/fields/reorder

Actual backend path: /v1/workspace/:workspaceId/sessions/fields/reorder

Description

Reorder session fields by phase. This updates the display order of fields within a specific phase.

Authentication

Required - JWT token in Authorization header

Required Permissions:

  • sessions.update

Headers

HeaderTypeRequiredDescription
AuthorizationstringYesBearer token: Bearer <token>
Content-TypestringYesapplication/json

Path Parameters

ParameterTypeRequiredDescription
workspaceIdstringYesWorkspace identifier

Request Body

{
"phase": "pre",
"fields": [
{
"fieldId": "507f1f77bcf86cd799439011",
"order": 1
},
{
"fieldId": "507f1f77bcf86cd799439012",
"order": 2
}
]
}

Body Parameters

ParameterTypeRequiredDescription
phasestringYesPhase to reorder. Valid values: pre, during, post
fieldsarrayYesArray of field order objects (minimum 1)
fields[].fieldIdstringYesField identifier
fields[].ordernumberYesNew order position (integer)

Response (200)

{
"fields": [
{
"id": "507f1f77bcf86cd799439011",
"key": "pre-session-notes",
"label": "Pre-Session Notes",
"phase": "pre",
"order": 1
},
{
"id": "507f1f77bcf86cd799439012",
"key": "pre-session-checklist",
"label": "Pre-Session Checklist",
"phase": "pre",
"order": 2
}
]
}

Common Errors

  • 400 Bad Request: Invalid request body or less than one field provided
  • 401 Unauthorized: Missing or invalid authentication token
  • 403 Forbidden: Insufficient permissions (requires sessions.update)
  • 404 Not Found: Workspace or field not found
  • 422 Unprocessable Entity: Validation errors
  • 500 Internal Server Error: Server error