work-sessions

Approve or decline a pending move of someone’s hours (origin owner/admin).

Only an owner or admin of the workspace the hours leave decides. Approve: the hours move exactly as a direct move would (every rule re-checked), recorded as moved by the person who asked and approved by the caller. Decline: nothing moves; the person who asked is told.

post/work-sessions/move/requests/{id}/decide

Request

  • Base URL: https://restivity.ai/api/v1
  • URL: https://restivity.ai/api/v1/work-sessions/move/requests/{id}/decide
  • Auth: OAuth 2 (authorization code, authorization URL https://restivity.ai/oauth/authorize, token URL https://restivity.ai/api/oauth/token, scopes: pomodoro:write)

Path parameters

idstring uuid required

The move request (request_id of the 202 answer).

Request body

approveboolean required

true moves the hours; false declines the request (nothing moves).

notestring

Optional: a word for the person who asked.

Response

The decision: moved (with the sessions) or declined.

status'moved' | 'pending' | 'declined' | 'undone' required
code'move_needs_approval'

On 202: the move waits for the owner/admins of the workspace the hours leave.

messagestring
request_idstring uuid nullable required
origin_workspace_idstring uuid required
destination_workspace_idstring uuid required
approver_idsstring[]
session_idsstring[]

Changes

No recorded changes to this operation across all 1 revision of this API.