{"openapi":"3.1.0","info":{"title":"Planbase API","description":"<b>Welcome to the Planbase API documentation! Here, you'll find authentication steps and details on supported endpoints and methods.The Planbase API, based on REST principles, features resource-focused URLs, form-encoded payloads, JSON responses, and standard HTTP codes, authentication, and verbs.</b>","version":"1.0.0"},"paths":{"/api/v1/clients":{"get":{"tags":["Clients"],"summary":"Get Clients","operationId":"get_clients_api_v1_clients_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"include_activity_types","in":"query","required":false,"schema":{"anyOf":[{"type":"boolean"},{"type":"null"}],"description":"Whether to eager load activity types","default":false,"title":"Include Activity Types"},"description":"Whether to eager load activity types"},{"name":"include_client_assignments","in":"query","required":false,"schema":{"anyOf":[{"type":"boolean"},{"type":"null"}],"description":"Whether to eager load client assignments","default":false,"title":"Include Client Assignments"},"description":"Whether to eager load client assignments"},{"name":"include_license_types","in":"query","required":false,"schema":{"anyOf":[{"type":"boolean"},{"type":"null"}],"description":"Whether to eager load license types which require credentialing for this client","default":false,"title":"Include License Types"},"description":"Whether to eager load license types which require credentialing for this client"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Clients"],"summary":"Add Client","operationId":"add_client_api_v1_clients_post","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ClientNew"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Client"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/clients/assignments":{"get":{"tags":["Clients"],"summary":"Get Client Assignments","operationId":"get_client_assignments_api_v1_clients_assignments_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/ClientAssignmentAPI"},"type":"array","title":"Response Get Client Assignments Api V1 Clients Assignments Get"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/v1/clients/{id}":{"put":{"tags":["Clients"],"summary":"Update Client","operationId":"update_client_api_v1_clients__id__put","security":[{"HTTPBearer":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer","description":"The ID of the client to update","title":"Id"},"description":"The ID of the client to update"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ClientOptional"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Client"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Clients"],"summary":"Delete Client","operationId":"delete_client_api_v1_clients__id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer","description":"The ID of the client to delete","title":"Id"},"description":"The ID of the client to delete"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/clock/in":{"post":{"tags":["Clocking"],"summary":"Clock In","description":"Clock in to a shift. Creates a new shift if shift_id is not provided.\nOnly allowed when the user has at least one applicable clock_in_out rule,\nand (when a shift is required) within the rule's trigger window.","operationId":"clock_in_api_v1_clock_in_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ClockInRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ClockActionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/v1/clock/out":{"post":{"tags":["Clocking"],"summary":"Clock Out","description":"Clock out of a shift. Also clocks out of any active activity.","operationId":"clock_out_api_v1_clock_out_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ClockOutRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ClockActionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/v1/clock/activity/in":{"post":{"tags":["Clocking"],"summary":"Activity Clock In","description":"Clock in to an activity within a shift. Automatically clocks out of any active activity.","operationId":"activity_clock_in_api_v1_clock_activity_in_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ActivityClockInRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ClockActionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/v1/clock/activity/swap":{"post":{"tags":["Clocking"],"summary":"Activity Swap","description":"Swap the activity type on the active activity without resetting the timer.","operationId":"activity_swap_api_v1_clock_activity_swap_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ActivitySwapRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ClockActionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/v1/clock/activity/out":{"post":{"tags":["Clocking"],"summary":"Activity Clock Out","description":"Clock out of the current activity.","operationId":"activity_clock_out_api_v1_clock_activity_out_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ActivityClockOutRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ClockActionResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/v1/clock/status":{"get":{"tags":["Clocking"],"summary":"Clock Status","description":"Returns the current user's clocking state for the extension popup:\nwhether they have clock rules, their current clocked-in shift (with actions),\navailable shifts to clock into, and org activity types.","operationId":"clock_status_api_v1_clock_status_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Clock Status Api V1 Clock Status Get"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/v1/custom_options/get_upload_url":{"get":{"tags":["Custom Options"],"summary":"Get Upload Url","operationId":"get_upload_url_api_v1_custom_options_get_upload_url_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"filename","in":"query","required":true,"schema":{"type":"string","title":"Filename"}},{"name":"file_path","in":"query","required":true,"schema":{"type":"string","title":"File Path"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/custom_options/get_read_url":{"get":{"tags":["Custom Options"],"summary":"Get Read Url","operationId":"get_read_url_api_v1_custom_options_get_read_url_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"filename","in":"query","required":true,"schema":{"type":"string","title":"Filename"}},{"name":"file_path","in":"query","required":true,"schema":{"type":"string","title":"File Path"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/health":{"get":{"tags":["Health"],"summary":"Get Minimal Health Response","operationId":"get_minimal_health_response_api_v1_health_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/MinimalHealthResponse"}}}}}}},"/api/v1/health/admin":{"get":{"tags":["Health"],"summary":"Get Detailed Health Response","operationId":"get_detailed_health_response_api_v1_health_admin_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HealthResponse"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/v1/forecasts/upload_tickets":{"post":{"tags":["Forecasting"],"summary":"Upload Tickets","operationId":"upload_tickets_api_v1_forecasts_upload_tickets_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UploadTickets"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/v1/forecasts":{"get":{"tags":["Forecasting"],"summary":"Get Datastreams","description":"Retrieve all datastreams within the current user's organization.","operationId":"get_datastreams_api_v1_forecasts_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/ForecastResponse"},"type":"array","title":"Response Get Datastreams Api V1 Forecasts Get"}}}}},"security":[{"HTTPBearer":[]}]},"post":{"tags":["Forecasting"],"summary":"Trigger Forecasts","description":"Trigger the forecast generation process for a specific datastream or a new datastream defined by the payload. Set train_model = False if you only want to upload data","operationId":"trigger_forecasts_api_v1_forecasts_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ForecastPayload"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/v1/forecasts/{datastream_name}":{"delete":{"tags":["Forecasting"],"summary":"Delete Single Datastream By Name","description":"Remove a specific datastream by its name from the organization.","operationId":"delete_single_datastream_by_name_api_v1_forecasts__datastream_name__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"datastream_name","in":"path","required":true,"schema":{"type":"string","description":"Your name or ID of the datastream to delete","title":"Datastream Name"},"description":"Your name or ID of the datastream to delete"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/forecasts/predictions":{"get":{"tags":["Forecasting"],"summary":"Get Forecasts Method","description":"Retrieve forecast data for a specific datastream within the given time range.","operationId":"get_forecasts_method_api_v1_forecasts_predictions_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"datastream_name","in":"query","required":true,"schema":{"type":"string","title":"Datastream Name"}},{"name":"timestamp_from","in":"query","required":false,"schema":{"type":"integer","default":1795221424.520044,"title":"Timestamp From"}},{"name":"timestamp_to","in":"query","required":false,"schema":{"type":"integer","default":1796431024.5200443,"title":"Timestamp To"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/forecasts/actuals":{"get":{"tags":["Forecasting"],"summary":"Get Actuals Method","description":"Retrieve actual data for a specific datastream within the given time range.","operationId":"get_actuals_method_api_v1_forecasts_actuals_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"datastream_name","in":"query","required":true,"schema":{"type":"string","title":"Datastream Name"}},{"name":"timestamp_from","in":"query","required":false,"schema":{"type":"integer","default":1794011824.5216517,"title":"Timestamp From"}},{"name":"timestamp_to","in":"query","required":false,"schema":{"type":"integer","default":1795221424.5216522,"title":"Timestamp To"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/forecasts/actual_ticket_counts":{"post":{"tags":["Forecasting"],"summary":"Get Actual Ticket Counts Endpoint","description":"Get actual ticket counts for specified integrations and time range","operationId":"get_actual_ticket_counts_endpoint_api_v1_forecasts_actual_ticket_counts_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ActualTicketCountsRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/TicketCountPoint"},"type":"array","title":"Response Get Actual Ticket Counts Endpoint Api V1 Forecasts Actual Ticket Counts Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/v1/forecasts/predicted_ticket_counts":{"post":{"tags":["Forecasting"],"summary":"Get Predicted Ticket Counts Endpoint","description":"Generate predicted ticket counts using global models. Training data is automatically set to 2 years prior to prediction start date.","operationId":"get_predicted_ticket_counts_endpoint_api_v1_forecasts_predicted_ticket_counts_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PredictedTicketCountsRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/TicketCountPoint"},"type":"array","title":"Response Get Predicted Ticket Counts Endpoint Api V1 Forecasts Predicted Ticket Counts Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/v1/people/get_current_user":{"get":{"tags":["People"],"summary":"Get Current User Route","description":"Retrieve the current user who is logged in with the API auth token.","operationId":"get_current_user_route_api_v1_people_get_current_user_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"include","in":"query","required":false,"schema":{"type":"string","description":"Which objects should be included in the response as comma-separated list of objects. API supports 'status', 'unavailability_allowances', 'unavailability_balances'","title":"Include"},"description":"Which objects should be included in the response as comma-separated list of objects. API supports 'status', 'unavailability_allowances', 'unavailability_balances'"},{"name":"eager","in":"query","required":false,"schema":{"type":"boolean","description":"Whether to eager load the person. Will be deprecated in v2 in favour of include.","default":false,"title":"Eager"},"description":"Whether to eager load the person. Will be deprecated in v2 in favour of include."}],"responses":{"200":{"description":"Returns the current user's details.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CurrentUserResponse"},"example":{"id":1,"first_name":"John","last_name":"Doe","email":"john.doe@example.com","cell":"1234567890","notifications_text":true,"notifications_email":true,"enable_login":true,"employee_id":"123456","timezone":"US/Central","start_date":"2022-01-01T00:00:00+00:00","employment_classification":"CONTRACT","regular_work_hours":{"0":[{"start":"08:30","end":"18:15"}],"1":[{"start":"08:30","end":"18:15"}],"2":[{"start":"08:30","end":"18:15"}],"3":[{"start":"08:30","end":"18:15"}],"4":[{"start":"08:30","end":"17:15"}]},"submits_availability":true,"submits_unavailability":true,"access_level_name":"admin","archived":false}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/people":{"get":{"tags":["People"],"summary":"Get People","description":"Retrieve all people within the current user's organization.","operationId":"get_people_api_v1_people_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"include","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Object detail to be included with each person (e.g. 'teams, roles, licenses, payor_enrollments, eligible_time_off_types')","title":"Include"},"description":"Object detail to be included with each person (e.g. 'teams, roles, licenses, payor_enrollments, eligible_time_off_types')"},{"name":"include_archived","in":"query","required":false,"schema":{"anyOf":[{"type":"boolean"},{"type":"null"}],"description":"Include archived people in the response","default":false,"title":"Include Archived"},"description":"Include archived people in the response"},{"name":"include_non_archived","in":"query","required":false,"schema":{"anyOf":[{"type":"boolean"},{"type":"null"}],"description":"Include non-archived people in the response","default":true,"title":"Include Non Archived"},"description":"Include non-archived people in the response"},{"name":"person_ids","in":"query","required":false,"schema":{"anyOf":[{"type":"array","items":{"type":"integer"}},{"type":"null"}],"description":"Filter people by person ids (e.g. [4, 6, 7, 8])","title":"Person Ids"},"description":"Filter people by person ids (e.g. [4, 6, 7, 8])"},{"name":"team_ids","in":"query","required":false,"schema":{"anyOf":[{"type":"array","items":{"type":"integer"}},{"type":"null"}],"description":"Filter people by team ids (e.g. [4, 6, 7, 8])","title":"Team Ids"},"description":"Filter people by team ids (e.g. [4, 6, 7, 8])"},{"name":"role_ids","in":"query","required":false,"schema":{"anyOf":[{"type":"array","items":{"type":"integer"}},{"type":"null"}],"description":"Filter people by role ids (e.g. [4, 6, 7, 8])","title":"Role Ids"},"description":"Filter people by role ids (e.g. [4, 6, 7, 8])"},{"name":"client_ids","in":"query","required":false,"schema":{"anyOf":[{"type":"array","items":{"type":"integer"}},{"type":"null"}],"description":"Filter people by client ids (e.g. [4, 6, 7, 8])","title":"Client Ids"},"description":"Filter people by client ids (e.g. [4, 6, 7, 8])"},{"name":"license_type_ids","in":"query","required":false,"schema":{"anyOf":[{"type":"array","items":{"type":"integer"}},{"type":"null"}],"description":"Filter people by license type ids (e.g. [4, 6, 7, 8])","title":"License Type Ids"},"description":"Filter people by license type ids (e.g. [4, 6, 7, 8])"},{"name":"skill_type_ids","in":"query","required":false,"schema":{"anyOf":[{"type":"array","items":{"type":"integer"}},{"type":"null"}],"description":"Filter people by skill type ids (e.g. [4, 6, 7, 8])","title":"Skill Type Ids"},"description":"Filter people by skill type ids (e.g. [4, 6, 7, 8])"},{"name":"payor_ids","in":"query","required":false,"schema":{"anyOf":[{"type":"array","items":{"type":"integer"}},{"type":"null"}],"description":"Filter people by payor ids (e.g. [4, 6, 7, 8])","title":"Payor Ids"},"description":"Filter people by payor ids (e.g. [4, 6, 7, 8])"},{"name":"activity_type_ids","in":"query","required":false,"schema":{"anyOf":[{"type":"array","items":{"type":"integer"}},{"type":"null"}],"description":"Filter people by activity type ids (e.g. [4, 6, 7, 8])","title":"Activity Type Ids"},"description":"Filter people by activity type ids (e.g. [4, 6, 7, 8])"},{"name":"shift_type_ids","in":"query","required":false,"schema":{"anyOf":[{"type":"array","items":{"type":"integer"}},{"type":"null"}],"description":"Filter people by shift type ids (e.g. [4, 6, 7, 8])","title":"Shift Type Ids"},"description":"Filter people by shift type ids (e.g. [4, 6, 7, 8])"},{"name":"datastream_ids","in":"query","required":false,"schema":{"anyOf":[{"type":"array","items":{"type":"integer"}},{"type":"null"}],"description":"Filter people by datastream ids (e.g. [4, 6, 7, 8])","title":"Datastream Ids"},"description":"Filter people by datastream ids (e.g. [4, 6, 7, 8])"},{"name":"pay_cycle_ids","in":"query","required":false,"schema":{"anyOf":[{"type":"array","items":{"type":"integer"}},{"type":"null"}],"description":"Filter people by pay cycle ids (e.g. [4, 6, 7, 8])","title":"Pay Cycle Ids"},"description":"Filter people by pay cycle ids (e.g. [4, 6, 7, 8])"},{"name":"custom_field_filters","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter people by custom field filters (JSON object, e.g. {\"12345\":[1,2]})","title":"Custom Field Filters"},"description":"Filter people by custom field filters (JSON object, e.g. {\"12345\":[1,2]})"},{"name":"custom_object_reference_filters","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter people by custom object reference filters (JSON object, e.g. {\"27\":{\"12345\":[1,2]}})","title":"Custom Object Reference Filters"},"description":"Filter people by custom object reference filters (JSON object, e.g. {\"27\":{\"12345\":[1,2]}})"},{"name":"filter_type","in":"query","required":false,"schema":{"anyOf":[{"$ref":"#/components/schemas/FilterType"},{"type":"null"}],"description":"Filter type to use ('AND' or 'OR')","default":"OR","title":"Filter Type"},"description":"Filter type to use ('AND' or 'OR')"},{"name":"filter_start","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"description":"Start date to be used when applying relevant filters (e.g. license types, client assignments, payor enrollments, pay cycles)","title":"Filter Start"},"description":"Start date to be used when applying relevant filters (e.g. license types, client assignments, payor enrollments, pay cycles)"},{"name":"filter_end","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"description":"End date to be used when applying relevant filters (e.g. license types, client assignments, payor enrollments, pay cycles)","title":"Filter End"},"description":"End date to be used when applying relevant filters (e.g. license types, client assignments, payor enrollments, pay cycles)"},{"name":"fields","in":"query","required":false,"schema":{"anyOf":[{"type":"array","items":{"type":"string"}},{"type":"null"}],"description":"Specify which fields should be returned (e.g. [\"id\", \"first_name\", \"last_name\"])","title":"Fields"},"description":"Specify which fields should be returned (e.g. [\"id\", \"first_name\", \"last_name\"])"},{"name":"include_past_assignments","in":"query","required":false,"schema":{"anyOf":[{"type":"boolean"},{"type":"null"}],"description":"Whether to look at past team and roleassignments when filtering","default":false,"title":"Include Past Assignments"},"description":"Whether to look at past team and roleassignments when filtering"},{"name":"use_custom_field_ids","in":"query","required":false,"schema":{"anyOf":[{"type":"boolean"},{"type":"null"}],"description":"Use custom field IDs as keys instead of names","default":false,"title":"Use Custom Field Ids"},"description":"Use custom field IDs as keys instead of names"}],"responses":{"200":{"description":"Returns the current user's details.","content":{"application/json":{"schema":{},"example":[{"id":69,"first_name":"Tom","last_name":"Holland","email":"tom@email.com","notifications_text":true,"notifications_email":true,"enable_login":false,"employee_id":"715320","regular_work_hours":{"0":[{"start":"08:00","end":"17:00"}],"2":[{"start":"08:00","end":"17:00"}],"3":[{"start":"08:00","end":"17:00"}],"5":[{"start":"08:00","end":"17:00"}],"6":[{"start":"08:00","end":"17:00"}]},"min_daily_hours":8,"max_daily_hours":12,"exempt":false,"rate_type":"HOURLY","min_weekly_hours":10,"max_weekly_hours":40,"min_monthly_hours":45,"max_monthly_hours":100,"access_level_name":"admin","archived":false,"access_level":{"id":1,"name":"admin","archived":false},"unavailability_allowances":{}},{"id":112,"first_name":"Xiaoling","last_name":"Zhang","email":"xiaoling.zhang@example.com","notifications_text":true,"notifications_email":true,"enable_login":false,"employee_id":"12","regular_work_hours":{"0":[{"start":"09:30","end":"21:30"}],"1":[{"start":"09:30","end":"21:30"}],"2":[{"start":"09:30","end":"21:30"}],"3":[{"start":"09:30","end":"21:30"}],"4":[{"start":"09:30","end":"21:30"}],"5":[{"start":"09:30","end":"21:30"}],"6":[{"start":"09:30","end":"21:30"}]},"exempt":false,"rate_type":"HOURLY","min_daily_hours":8,"max_daily_hours":12,"min_weekly_hours":10,"max_weekly_hours":40,"min_monthly_hours":45,"max_monthly_hours":100,"access_level_name":"admin","archived":false,"access_level":{"id":1,"name":"admin","archived":false},"unavailability_allowances":{}}]}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["People"],"summary":"Add Person","description":"Create a new person with the given details.","operationId":"add_person_api_v1_people_post","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PersonNew"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PersonRead"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/people/directory":{"get":{"tags":["People"],"summary":"Get People Directory","operationId":"get_people_directory_api_v1_people_directory_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/DirectoryPerson"},"type":"array","title":"Response Get People Directory Api V1 People Directory Get"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/v1/people/fix_audit_errors":{"post":{"tags":["People"],"summary":"Fix Audit Errors","operationId":"fix_audit_errors_api_v1_people_fix_audit_errors_post","requestBody":{"content":{"application/json":{"schema":{"items":{},"type":"array","title":"Errors"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/v1/people/send_invite_email":{"post":{"tags":["People"],"summary":"Send Invite Email","operationId":"send_invite_email_api_v1_people_send_invite_email_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SendInviteEmailAPI"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/v1/people/{id}":{"put":{"tags":["People"],"summary":"Update Person","description":"Update an existing person with the specified ID and details.","operationId":"update_person_api_v1_people__id__put","security":[{"HTTPBearer":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer","description":"The ID of the person to update","title":"Id"},"description":"The ID of the person to update"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PersonUpdateAPI"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PersonRead"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["People"],"summary":"Delete Person","description":"Delete a person with the specified ID.","operationId":"delete_person_api_v1_people__id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer","description":"The ID of the person to delete","title":"Id"},"description":"The ID of the person to delete"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/roles":{"get":{"tags":["Roles"],"summary":"Get Roles","description":"Retrieve all roles within the current user's organization.","operationId":"get_roles_api_v1_roles_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"include_archived","in":"query","required":false,"schema":{"anyOf":[{"type":"boolean"},{"type":"null"}],"description":"Include archived roles in the response","default":false,"title":"Include Archived"},"description":"Include archived roles in the response"},{"name":"eager","in":"query","required":false,"schema":{"anyOf":[{"type":"boolean"},{"type":"null"}],"description":"Whether to eager load all joins","default":true,"title":"Eager"},"description":"Whether to eager load all joins"},{"name":"fields","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Fields to be included in the response","title":"Fields"},"description":"Fields to be included in the response"},{"name":"include","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Which eager loads to include","title":"Include"},"description":"Which eager loads to include"}],"responses":{"200":{"description":"Returns a list of roles.","content":{"application/json":{"schema":{},"example":[{"id":5,"name":"Support Engineer","color":"#7ed321"},{"id":2,"name":"Software Engineer","color":"#ff2e48"},{"id":77,"name":"Marketing Manager","color":"#3ef73e"}]}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Roles"],"summary":"Add Role","description":"Create a new role with the given details.","operationId":"add_role_api_v1_roles_post","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RoleNew"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RoleRead"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/roles/{id}":{"put":{"tags":["Roles"],"summary":"Update Role","description":"Update an existing role with the specified ID and details.","operationId":"update_role_api_v1_roles__id__put","security":[{"HTTPBearer":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer","description":"The ID of the person to retrieve","title":"Id"},"description":"The ID of the person to retrieve"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RoleNew"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RoleRead"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Roles"],"summary":"Delete Role","description":"Delete a role with the specified ID.","operationId":"delete_role_api_v1_roles__id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer","description":"The ID of the role to delete","title":"Id"},"description":"The ID of the role to delete"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/recurrences/all":{"get":{"tags":["Recurrences"],"summary":"Get All Recurrences","operationId":"get_all_recurrences_api_v1_recurrences_all_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"include_archived","in":"query","required":false,"schema":{"type":"boolean","description":"Include archived recurrences","default":false,"title":"Include Archived"},"description":"Include archived recurrences"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/RecurrenceOutAPI"},"title":"Response Get All Recurrences Api V1 Recurrences All Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/recurrences/person/{person_id}":{"get":{"tags":["Recurrences"],"summary":"Get Recurrences By Range","operationId":"get_recurrences_by_range_api_v1_recurrences_person__person_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"person_id","in":"path","required":true,"schema":{"type":"integer","description":"The ID of the person to get recurrences for","title":"Person Id"},"description":"The ID of the person to get recurrences for"},{"name":"freq","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter by recurrence frequency e.g. MONTHLY","title":"Freq"},"description":"Filter by recurrence frequency e.g. MONTHLY"},{"name":"shift_only","in":"query","required":false,"schema":{"anyOf":[{"type":"boolean"},{"type":"null"}],"description":"When True, exclude activity-based recurrences","title":"Shift Only"},"description":"When True, exclude activity-based recurrences"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/RecurrenceOutAPI"},"title":"Response Get Recurrences By Range Api V1 Recurrences Person  Person Id  Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/recurrences":{"post":{"tags":["Recurrences"],"summary":"Create Recurrence","operationId":"create_recurrence_api_v1_recurrences_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"shift_id","in":"query","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"description":"Optional shift to delete before creating the recurrence","title":"Shift Id"},"description":"Optional shift to delete before creating the recurrence"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RecurrenceNew"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/recurrences/{id}":{"put":{"tags":["Recurrences"],"summary":"Update Recurrence","operationId":"update_recurrence_api_v1_recurrences__id__put","security":[{"HTTPBearer":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer","description":"The ID of the recurrence to lock","title":"Id"},"description":"The ID of the recurrence to lock"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RecurrenceOptional"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RecurrenceOutAPI"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Recurrences"],"summary":"Delete Recurrence","operationId":"delete_recurrence_api_v1_recurrences__id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer","description":"The ID of the recurrence to lock","title":"Id"},"description":"The ID of the recurrence to lock"},{"name":"start","in":"query","required":true,"schema":{"type":"string","format":"date-time","description":"The start date of the recurrence to delete","title":"Start"},"description":"The start date of the recurrence to delete"}],"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["Recurrences"],"summary":"Get Recurrences","operationId":"get_recurrences_api_v1_recurrences__id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer","description":"The ID of the recurrence to get","title":"Id"},"description":"The ID of the recurrence to get"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RecurrenceOutAPI"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/recurrences/{id}/split":{"put":{"tags":["Recurrences"],"summary":"Split Recurrence","operationId":"split_recurrence_api_v1_recurrences__id__split_put","security":[{"HTTPBearer":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer","description":"The ID of the recurrence to lock","title":"Id"},"description":"The ID of the recurrence to lock"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RecurrenceOptional"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RecurrenceOutAPI"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/recurrences/{id}/history":{"get":{"tags":["Recurrences"],"summary":"Get Recurrence History","operationId":"get_recurrence_history_api_v1_recurrences__id__history_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer","description":"The ID of the recurrence to get the history for","title":"Id"},"description":"The ID of the recurrence to get the history for"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/RecurrenceOutAPI"},"title":"Response Get Recurrence History Api V1 Recurrences  Id  History Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/rulesets":{"get":{"tags":["Rulesets"],"summary":"Get Rules","description":"Lists rulesets for the org, optionally including each ruleset's applicable_person_ids.","operationId":"get_rules_api_v1_rulesets_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"include_applicable_person_ids","in":"query","required":false,"schema":{"type":"boolean","description":"Include list of person IDs associated with each ruleset","default":false,"title":"Include Applicable Person Ids"},"description":"Include list of person IDs associated with each ruleset"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/RulesetOut"},"title":"Response Get Rules Api V1 Rulesets Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Rulesets"],"summary":"Add Ruleset","operationId":"add_ruleset_api_v1_rulesets_post","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RulesetNew"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/rulesets/{id}":{"put":{"tags":["Rulesets"],"summary":"Update Pay Rule","operationId":"update_pay_rule_api_v1_rulesets__id__put","security":[{"HTTPBearer":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer","description":"The ID of the ruleset to update","title":"Id"},"description":"The ID of the ruleset to update"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RulesetNew"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Rulesets"],"summary":"Delete Ruleset","operationId":"delete_ruleset_api_v1_rulesets__id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer","description":"The ID of the ruleset to delete","title":"Id"},"description":"The ID of the ruleset to delete"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/teams":{"get":{"tags":["Teams"],"summary":"Get Teams","description":"Retrieve all teams within the current user's organization.","operationId":"get_teams_api_v1_teams_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"include_archived","in":"query","required":false,"schema":{"anyOf":[{"type":"boolean"},{"type":"null"}],"description":"Include archived teams in the response","default":false,"title":"Include Archived"},"description":"Include archived teams in the response"},{"name":"eager","in":"query","required":false,"schema":{"anyOf":[{"type":"boolean"},{"type":"null"}],"description":"Whether to eager load joins","default":true,"title":"Eager"},"description":"Whether to eager load joins"},{"name":"fields","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Fields to be included in the response","title":"Fields"},"description":"Fields to be included in the response"},{"name":"include","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Which eager loads to include, e.g. people,roles(id)","title":"Include"},"description":"Which eager loads to include, e.g. people,roles(id)"}],"responses":{"200":{"description":"Returns a list of teams.","content":{"application/json":{"schema":{},"example":[{"id":57,"name":"Finance and Operations","color":"#eb79ad"},{"id":58,"name":"Customer Support","color":"#4caf50"},{"id":22,"name":"Sales & Marketing","address":"167 N Green St, Chicago, IL 60607, USA","color":"#f40ff4"},{"id":59,"name":"Admin","color":"#b276b2"}]}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Teams"],"summary":"Add Team","description":"Create a new team with the given details.","operationId":"add_team_api_v1_teams_post","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TeamNew"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TeamRead"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/teams/{id}":{"put":{"tags":["Teams"],"summary":"Update Team","description":"Update an existing team with the specified ID and details.","operationId":"update_team_api_v1_teams__id__put","security":[{"HTTPBearer":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer","description":"The ID of the team to update","title":"Id"},"description":"The ID of the team to update"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TeamNew"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TeamRead"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Teams"],"summary":"Delete Team","description":"Delete a team with the specified ID.","operationId":"delete_team_api_v1_teams__id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer","description":"The ID of the team to delete","title":"Id"},"description":"The ID of the team to delete"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/availabilities":{"get":{"tags":["Availabilities"],"summary":"Get Availabilities By Date Range","description":"Retrieve all availabilities within the specified date range.","operationId":"get_availabilities_by_date_range_api_v1_availabilities_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"start","in":"query","required":true,"schema":{"type":"string","format":"date-time","description":"Return all availability from this datetime e.g 2024-05-09T08:00:00. Can't request more than 1 week at a time.","title":"Start"},"description":"Return all availability from this datetime e.g 2024-05-09T08:00:00. Can't request more than 1 week at a time."},{"name":"end","in":"query","required":true,"schema":{"type":"string","format":"date-time","description":"Return all availability up until this datetime e.g 2024-05-09T08:00:00. Can't request more than 1 week at a time.","title":"End"},"description":"Return all availability up until this datetime e.g 2024-05-09T08:00:00. Can't request more than 1 week at a time."},{"name":"person_ids","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter availabilities by person ids (e.g. '4,6,7,8')","title":"Person Ids"},"description":"Filter availabilities by person ids (e.g. '4,6,7,8')"}],"responses":{"200":{"description":"Returns a list of availabilities.","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/AvailabilityRead"},"title":"Response Get Availabilities By Date Range Api V1 Availabilities Get"},"example":[{"id":202,"start":"2024-05-10T11:00:00+00:00","end":"2024-05-11T03:00:00+00:00","person_id":3,"time_created":"2024-05-01T03:43:41.853731+00:00","time_updated":"2024-05-01T03:43:41.853731+00:00"},{"id":201,"start":"2024-05-11T08:00:00+00:00","end":"2024-05-11T21:00:00+00:00","person_id":3,"time_created":"2024-05-01T03:43:41.849104+00:00","time_updated":"2024-05-01T03:43:41.849104+00:00"},{"id":246,"start":"2024-05-12T13:00:00+00:00","end":"2024-05-13T01:00:00+00:00","person_id":1,"time_created":"2024-05-13T21:10:06.653463+00:00","time_updated":"2024-05-13T21:10:06.653463+00:00"}]}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Availabilities"],"summary":"Add Availability","description":"Create a new availability with the given details.","operationId":"add_availability_api_v1_availabilities_post","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AvailabilityNew"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AvailabilityRead"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/availabilities/validation":{"post":{"tags":["Availabilities"],"summary":"Validate Availability Submission","operationId":"validate_availability_submission_api_v1_availabilities_validation_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AvailabilityValidationRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RequestValidationResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/v1/availabilities/{id}":{"put":{"tags":["Availabilities"],"summary":"Update Availability","description":"Update an existing availability with the specified ID and details.","operationId":"update_availability_api_v1_availabilities__id__put","security":[{"HTTPBearer":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer","description":"The ID of the availability to update","title":"Id"},"description":"The ID of the availability to update"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AvailabilityNew"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AvailabilityRead"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Availabilities"],"summary":"Delete Availability","description":"Delete an availability with the specified ID.","operationId":"delete_availability_api_v1_availabilities__id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer","description":"The ID of the availability to delete","title":"Id"},"description":"The ID of the availability to delete"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/requests":{"get":{"tags":["Requests"],"summary":"Get Requests","operationId":"get_requests_api_v1_requests_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"start","in":"query","required":true,"schema":{"type":"string","format":"date-time","description":"Return requests overlapping from this datetime (UTC)","title":"Start"},"description":"Return requests overlapping from this datetime (UTC)"},{"name":"end","in":"query","required":true,"schema":{"type":"string","format":"date-time","description":"Return requests overlapping until this datetime (UTC)","title":"End"},"description":"Return requests overlapping until this datetime (UTC)"},{"name":"exclude_unpublished","in":"query","required":false,"schema":{"type":"boolean","description":"Whether or not requests should take published shifts/activities into account","default":true,"title":"Exclude Unpublished"},"description":"Whether or not requests should take published shifts/activities into account"},{"name":"person_ids","in":"query","required":false,"schema":{"anyOf":[{"type":"array","items":{"type":"integer"}},{"type":"null"}],"description":"Filter by person ids","title":"Person Ids"},"description":"Filter by person ids"},{"name":"statuses","in":"query","required":false,"schema":{"anyOf":[{"type":"array","items":{"type":"string"}},{"type":"null"}],"description":"Status types to return. Supported by open shift responses and unavailability requests (include 'approved' to also return settled unavailabilities, or 'denied' to also return denied schedule and time-off requests)","default":["pending"],"title":"Statuses"},"description":"Status types to return. Supported by open shift responses and unavailability requests (include 'approved' to also return settled unavailabilities, or 'denied' to also return denied schedule and time-off requests)"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/RequestItem"},"title":"Response Get Requests Api V1 Requests Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Requests"],"summary":"Create Request Endpoint","description":"Create one or more requests. See RequestIn for each item. Items for the same person in the same work week are submitted together and returned 1:1 with the input. Returns 422 if that row already has a pending request of the same type; decide or cancel it instead. Pass validate_only=true to check without writing.","operationId":"create_request_endpoint_api_v1_requests_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"validate_only","in":"query","required":false,"schema":{"type":"boolean","description":"Run create checks without persisting","default":false,"title":"Validate Only"},"description":"Run create checks without persisting"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RequestsIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RequestsOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/requests/decide":{"post":{"tags":["Requests"],"summary":"Decide Request Endpoint","description":"Approve or deny pending requests. See RequestDecisionIn for each item. Returns 422 if there is no pending request of that type. An invalid item fails the whole batch before anything is written. Withdraw via POST /cancel. Pass validate_only=true to check without writing.","operationId":"decide_request_endpoint_api_v1_requests_decide_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"validate_only","in":"query","required":false,"schema":{"type":"boolean","description":"Run decide checks without persisting","default":false,"title":"Validate Only"},"description":"Run decide checks without persisting"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RequestDecisionsIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RequestsOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/requests/cancel":{"post":{"tags":["Requests"],"summary":"Cancel Request Endpoint","description":"Withdraw pending requests. See RequestCancelIn for each item. This withdraws the request only, not the underlying shift or time off. To cancel an already-approved shift or unavailability, create a cancel_shift or cancel_time_off request instead. Returns 422 if there is no pending request of that type. Pass validate_only=true to check without writing.","operationId":"cancel_request_endpoint_api_v1_requests_cancel_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"validate_only","in":"query","required":false,"schema":{"type":"boolean","description":"Run cancel checks without persisting","default":false,"title":"Validate Only"},"description":"Run cancel checks without persisting"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RequestCancelsIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RequestsOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/requests/validate":{"post":{"tags":["Requests"],"summary":"Validate Request","description":"Check shifts or unavailabilities between start and end.\n\nAlways runs the unavailability checks, including balance_details. Omitting\nunavailabilities validates with no time off. Schedule checks run as well when\nshifts are sent and an enabled ruleset that applies to this person includes\nself_scheduling.","operationId":"validate_request_api_v1_requests_validate_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ValidationIn"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TimeOffRequestValidationResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/v1/shifts/vacant":{"get":{"tags":["Shifts"],"summary":"Get Vacant Shifts","description":"Retrieve shifts for the current user's organization.","operationId":"get_vacant_shifts_api_v1_shifts_vacant_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"start","in":"query","required":true,"schema":{"type":"string","format":"date-time","description":"Return shifts from this date eg. 2024-05-09T08:00:00. Can't request more than 1 week at a time.","title":"Start"},"description":"Return shifts from this date eg. 2024-05-09T08:00:00. Can't request more than 1 week at a time."},{"name":"end","in":"query","required":true,"schema":{"type":"string","format":"date-time","description":"Return shifts up until this date e.g 2024-05-09T08:00:00. Can't request more than 1 week at a time.","title":"End"},"description":"Return shifts up until this date e.g 2024-05-09T08:00:00. Can't request more than 1 week at a time."},{"name":"shift_ids","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter vacant shifts by shift ids (e.g. '4,6,7,8')","title":"Shift Ids"},"description":"Filter vacant shifts by shift ids (e.g. '4,6,7,8')"},{"name":"eligible_for","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter to shifts these people could claim (e.g. '4,6,7,8'), instead of all vacant shifts. Checking people other than yourself is subject to the same read_shifts permission scoping as the rest of this endpoint. Defaults to no filtering, so existing callers are unaffected.","title":"Eligible For"},"description":"Filter to shifts these people could claim (e.g. '4,6,7,8'), instead of all vacant shifts. Checking people other than yourself is subject to the same read_shifts permission scoping as the rest of this endpoint. Defaults to no filtering, so existing callers are unaffected."},{"name":"include","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Object detail to include with each shift (e.g. 'clients,license_types,activities,eligible_people(id,first_name)'). Each resource can optionally take a parenthesized, comma-separated sub-field list; omitting it includes every field of that object. ","title":"Include"},"description":"Object detail to include with each shift (e.g. 'clients,license_types,activities,eligible_people(id,first_name)'). Each resource can optionally take a parenthesized, comma-separated sub-field list; omitting it includes every field of that object. "},{"name":"select_fields","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Fields to include in the response (e.g. 'id,start,end,team_id'). Defaults to every field.","title":"Select Fields"},"description":"Fields to include in the response (e.g. 'id,start,end,team_id'). Defaults to every field."}],"responses":{"200":{"description":"Returns a list of shifts.","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/ShiftOpportunity"},"title":"Response Get Vacant Shifts Api V1 Shifts Vacant Get"},"example":[{"id":40040,"start":"2024-05-12T14:30:00+00:00","end":"2024-05-13T02:30:00+00:00","team_id":1,"role_id":2,"person_id":73,"needs_publishing_calendar":false,"needs_publishing_slack":false,"is_publishing_calendar":false,"is_publishing_slack":false,"needs_publishing_email":false,"needs_publishing_sms":false,"is_publishing_email":false,"is_publishing_sms":false,"auto_approve_changes":false,"allow_alternative_times":false},{"id":40047,"start":"2024-05-12T12:30:00+00:00","end":"2024-05-13T01:00:00+00:00","team_id":1,"role_id":5,"person_id":75,"needs_publishing_calendar":false,"needs_publishing_slack":false,"is_publishing_calendar":false,"is_publishing_slack":false,"needs_publishing_email":false,"needs_publishing_sms":false,"is_publishing_email":false,"is_publishing_sms":false,"auto_approve_changes":false,"allow_alternative_times":false},{"id":43121,"start":"2024-05-13T13:00:00+00:00","end":"2024-05-13T22:00:00+00:00","team_id":1,"role_id":5,"person_id":3,"needs_publishing_calendar":false,"needs_publishing_slack":false,"is_publishing_calendar":false,"is_publishing_slack":false,"needs_publishing_email":false,"needs_publishing_sms":false,"is_publishing_email":false,"is_publishing_sms":false,"auto_approve_changes":false,"allow_alternative_times":false}]}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/shifts":{"get":{"tags":["Shifts"],"summary":"Get Shifts","description":"Retrieve shifts for the current user's organization.","operationId":"get_shifts_api_v1_shifts_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"start","in":"query","required":true,"schema":{"type":"string","format":"date-time","description":"Return shifts from this date eg. 2024-05-09T08:00:00. Can't request more than 1 week at a time.","title":"Start"},"description":"Return shifts from this date eg. 2024-05-09T08:00:00. Can't request more than 1 week at a time."},{"name":"end","in":"query","required":true,"schema":{"type":"string","format":"date-time","description":"Return shifts up until this date e.g 2024-05-09T08:00:00. Can't request more than 1 week at a time.","title":"End"},"description":"Return shifts up until this date e.g 2024-05-09T08:00:00. Can't request more than 1 week at a time."},{"name":"person_ids","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter shifts by person ids (e.g. '4,6,7,8')","title":"Person Ids"},"description":"Filter shifts by person ids (e.g. '4,6,7,8')"},{"name":"emails","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter shifts by e-mail addresses (e.g. 'simon@helloworld.com,susan@hello-world.com').","title":"Emails"},"description":"Filter shifts by e-mail addresses (e.g. 'simon@helloworld.com,susan@hello-world.com')."},{"name":"include","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Object detail to be included with each shift (e.g. 'activities,teams,roles,people,license_types,timecards')","title":"Include"},"description":"Object detail to be included with each shift (e.g. 'activities,teams,roles,people,license_types,timecards')"},{"name":"exclude_unpublished","in":"query","required":false,"schema":{"anyOf":[{"type":"boolean"},{"type":"null"}],"description":"Whether to exclude unpublished shifts","default":false,"title":"Exclude Unpublished"},"description":"Whether to exclude unpublished shifts"},{"name":"select_fields","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Fields to be included in the response","title":"Select Fields"},"description":"Fields to be included in the response"}],"responses":{"200":{"description":"Returns a list of shifts.","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/DynamicShiftOut"},"title":"Response Get Shifts Api V1 Shifts Get"},"example":[{"id":40040,"start":"2024-05-12T14:30:00+00:00","end":"2024-05-13T02:30:00+00:00","team_id":1,"role_id":2,"person_id":73,"needs_publishing_calendar":false,"needs_publishing_slack":false,"is_publishing_calendar":false,"is_publishing_slack":false,"needs_publishing_email":false,"needs_publishing_sms":false,"is_publishing_email":false,"is_publishing_sms":false,"auto_approve_changes":false,"allow_alternative_times":false},{"id":40047,"start":"2024-05-12T12:30:00+00:00","end":"2024-05-13T01:00:00+00:00","team_id":1,"role_id":5,"person_id":75,"needs_publishing_calendar":false,"needs_publishing_slack":false,"is_publishing_calendar":false,"is_publishing_slack":false,"needs_publishing_email":false,"needs_publishing_sms":false,"is_publishing_email":false,"is_publishing_sms":false,"auto_approve_changes":false,"allow_alternative_times":false},{"id":43121,"start":"2024-05-13T13:00:00+00:00","end":"2024-05-13T22:00:00+00:00","team_id":1,"role_id":5,"person_id":3,"needs_publishing_calendar":false,"needs_publishing_slack":false,"is_publishing_calendar":false,"is_publishing_slack":false,"needs_publishing_email":false,"needs_publishing_sms":false,"is_publishing_email":false,"is_publishing_sms":false,"auto_approve_changes":false,"allow_alternative_times":false}]}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Shifts"],"summary":"Add Shift","description":"Create a new shift with the given details.","operationId":"add_shift_api_v1_shifts_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"suppress_notifications","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Suppress Notifications"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ShiftNew"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ShiftRead"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/shifts/requestable":{"get":{"tags":["Shifts"],"summary":"Get Requestable Shifts","description":"Trade-able slots one person could request against - one row per (candidate shift, valid slot start) pair, each the same duration as end - start, not whole shifts. start/end is the window being offered/released; candidate shifts are searched for in a window centered on it (1 week each side, never reaching into the past), computed server-side rather than passed by the caller. eligible_for must be someone the caller's read_shifts permission includes, the same filter the people list uses. The person must also be allowed to trade by the same trade_eligibility ruleset as a release_shift trade. Excludes their own shifts and anything overlapping their published shifts or approved time off.","operationId":"get_requestable_shifts_api_v1_shifts_requestable_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"eligible_for","in":"query","required":true,"schema":{"type":"integer","description":"Person who'd be requesting this shift in a trade.","title":"Eligible For"},"description":"Person who'd be requesting this shift in a trade."},{"name":"start","in":"query","required":true,"schema":{"type":"string","format":"date-time","description":"Start of the window being offered/released. Candidate shifts are searched for in a window around this, computed server-side.","title":"Start"},"description":"Start of the window being offered/released. Candidate shifts are searched for in a window around this, computed server-side."},{"name":"end","in":"query","required":true,"schema":{"type":"string","format":"date-time","description":"End of the window being offered/released. end - start is the exact duration every returned slot matches.","title":"End"},"description":"End of the window being offered/released. end - start is the exact duration every returned slot matches."},{"name":"person_ids","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter shifts by person ids (e.g. '4,6,7,8')","title":"Person Ids"},"description":"Filter shifts by person ids (e.g. '4,6,7,8')"},{"name":"team_ids","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Only shifts on one of these teams (e.g. '4,6') - a trade-in must match the released shift's team.","title":"Team Ids"},"description":"Only shifts on one of these teams (e.g. '4,6') - a trade-in must match the released shift's team."},{"name":"role_ids","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Only shifts on one of these roles (e.g. '4,6') - a trade-in must match the released shift's role.","title":"Role Ids"},"description":"Only shifts on one of these roles (e.g. '4,6') - a trade-in must match the released shift's role."}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/RequestableTradeSlot"},"title":"Response Get Requestable Shifts Api V1 Shifts Requestable Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/shifts/actions":{"get":{"tags":["Shifts"],"summary":"Get Actions","operationId":"get_actions_api_v1_shifts_actions_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"start","in":"query","required":true,"schema":{"type":"string","format":"date-time","description":"Return actions from this date eg. 2024-05-09T08:00:00. Can't request more than 1 week at a time.","title":"Start"},"description":"Return actions from this date eg. 2024-05-09T08:00:00. Can't request more than 1 week at a time."},{"name":"end","in":"query","required":true,"schema":{"type":"string","format":"date-time","description":"Return actions up until this date e.g 2024-05-09T08:00:00. Can't request more than 1 week at a time.","title":"End"},"description":"Return actions up until this date e.g 2024-05-09T08:00:00. Can't request more than 1 week at a time."},{"name":"action_types","in":"query","required":false,"schema":{"anyOf":[{"type":"array","items":{"type":"string"}},{"type":"null"}],"description":"Filter actions by action types (e.g. [\"clock_in\", \"clock_out\"])","title":"Action Types"},"description":"Filter actions by action types (e.g. [\"clock_in\", \"clock_out\"])"},{"name":"person_ids","in":"query","required":false,"schema":{"anyOf":[{"type":"array","items":{"type":"integer"}},{"type":"null"}],"description":"Filter actions by person ids (e.g. [4, 6, 7, 8])","title":"Person Ids"},"description":"Filter actions by person ids (e.g. [4, 6, 7, 8])"},{"name":"include_activity_type","in":"query","required":false,"schema":{"type":"boolean","description":"Include the activity type in the response","default":false,"title":"Include Activity Type"},"description":"Include the activity type in the response"},{"name":"include_shift","in":"query","required":false,"schema":{"type":"boolean","description":"Include the shift in the response","default":false,"title":"Include Shift"},"description":"Include the shift in the response"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/Action"},"title":"Response Get Actions Api V1 Shifts Actions Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/shifts/{id}":{"get":{"tags":["Shifts"],"summary":"Get Shift By Id","description":"Get a single shift by ID","operationId":"get_shift_by_id_api_v1_shifts__id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer","description":"The ID of the shift to retrieve","title":"Id"},"description":"The ID of the shift to retrieve"},{"name":"include","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Object detail to be included with the shift (e.g. 'activities,teams,roles,people,license_types')","title":"Include"},"description":"Object detail to be included with the shift (e.g. 'activities,teams,roles,people,license_types')"},{"name":"exclude_unpublished","in":"query","required":false,"schema":{"anyOf":[{"type":"boolean"},{"type":"null"}],"description":"Whether to exclude unpublished shifts","default":false,"title":"Exclude Unpublished"},"description":"Whether to exclude unpublished shifts"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ShiftOutExternalAPI"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"put":{"tags":["Shifts"],"summary":"Update Shift","description":"Update an existing shift with the specified ID and details.","operationId":"update_shift_api_v1_shifts__id__put","security":[{"HTTPBearer":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer","description":"The ID of the shift to update","title":"Id"},"description":"The ID of the shift to update"},{"name":"suppress_notifications","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Suppress Notifications"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ShiftNew"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ShiftRead"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Shifts"],"summary":"Delete Shift","description":"Delete a shift with the specified ID.","operationId":"delete_shift_api_v1_shifts__id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer","description":"The ID of the shift to delete","title":"Id"},"description":"The ID of the shift to delete"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"boolean","title":"Response Delete Shift Api V1 Shifts  Id  Delete"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/shifts/publish":{"post":{"tags":["Shifts"],"summary":"Publish Shifts","operationId":"publish_shifts_api_v1_shifts_publish_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Body_publish_shifts_api_v1_shifts_publish_post"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/DynamicShiftOut"},"type":"array","title":"Response Publish Shifts Api V1 Shifts Publish Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/v1/shifts/unpublish/{id}":{"put":{"tags":["Shifts"],"summary":"Unpublish Shift","description":"Update an existing shift with the specified ID and details.","operationId":"unpublish_shift_api_v1_shifts_unpublish__id__put","security":[{"HTTPBearer":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer","description":"The ID of the shift to update","title":"Id"},"description":"The ID of the shift to update"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ShiftRead"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/shifts/create_actions":{"post":{"tags":["Shifts"],"summary":"Create Action Batch","operationId":"create_action_batch_api_v1_shifts_create_actions_post","requestBody":{"content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/ActionNew"},"type":"array","title":"Actions In"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/Action"},"type":"array","title":"Response Create Action Batch Api V1 Shifts Create Actions Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/v1/shifts/delete_actions":{"post":{"tags":["Shifts"],"summary":"Delete Action Batch","operationId":"delete_action_batch_api_v1_shifts_delete_actions_post","requestBody":{"content":{"application/json":{"schema":{"items":{"type":"integer"},"type":"array","title":"Action Ids"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/Action"},"type":"array","title":"Response Delete Action Batch Api V1 Shifts Delete Actions Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/v1/shifts/update_actions":{"post":{"tags":["Shifts"],"summary":"Update Action Batch","operationId":"update_action_batch_api_v1_shifts_update_actions_post","requestBody":{"content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/ActionOptional"},"type":"array","title":"Actions In"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/Action"},"type":"array","title":"Response Update Action Batch Api V1 Shifts Update Actions Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/v1/activity_types":{"get":{"tags":["Activity Types"],"summary":"Get Activity Types","description":"Retrieve all activity types within the organization.","operationId":"get_activity_types_api_v1_activity_types_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"include","in":"query","required":false,"schema":{"type":"string","description":"Which fields to include in the response","title":"Include"},"description":"Which fields to include in the response"},{"name":"eager","in":"query","required":false,"schema":{"anyOf":[{"type":"boolean"},{"type":"null"}],"description":"Whether to eager load joins","default":false,"title":"Eager"},"description":"Whether to eager load joins"}],"responses":{"200":{"description":"Returns a list of activity types.","content":{"application/json":{"schema":{},"example":[{"id":7,"name":"Break","tag":"outOfOffice","color":"#fffa2f","parameters":{"length":10,"occurs":0.667777,"offset":0.5,"allowed_times":[]}},{"id":6,"name":"Bug Smash","tag":"focusTime","color":"#ff1c9d","parameters":{"allowed_times":[]}}]}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Activity Types"],"summary":"Add Activity Type","description":"Add a new activity type to the current user's organization. This may include attributes such as unique name, and associated roles or departments.","operationId":"add_activity_type_api_v1_activity_types_post","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ActivityTypeNew"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ActivityTypeRead"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/activity_types/{id}":{"get":{"tags":["Activity Types"],"summary":"Get Activity Type By Id","description":"Retrieve a specific activity type by its ID within the organization.","operationId":"get_activity_type_by_id_api_v1_activity_types__id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer","description":"The ID of the activity type to retrieve","title":"Id"},"description":"The ID of the activity type to retrieve"},{"name":"include","in":"query","required":false,"schema":{"type":"string","description":"Which fields to include in the response","title":"Include"},"description":"Which fields to include in the response"},{"name":"eager","in":"query","required":false,"schema":{"anyOf":[{"type":"boolean"},{"type":"null"}],"description":"Whether to eager load joins","default":false,"title":"Eager"},"description":"Whether to eager load joins"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ActivityTypeOutAPI"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"put":{"tags":["Activity Types"],"summary":"Update Activity Type","description":"Update an existing activity type in the current user's organization, allowing modification of its attributes.","operationId":"update_activity_type_api_v1_activity_types__id__put","security":[{"HTTPBearer":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer","description":"The ID of the activity type to update","title":"Id"},"description":"The ID of the activity type to update"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ActivityTypeNew"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ActivityTypeRead"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Activity Types"],"summary":"Delete Activity Type","description":"Remove a specific activity type by its ID from the organization.","operationId":"delete_activity_type_api_v1_activity_types__id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer","description":"The ID of the activity type to delete","title":"Id"},"description":"The ID of the activity type to delete"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/shift_types":{"get":{"tags":["Shift Types"],"summary":"Get Shift Types","description":"Retrieve all shift types within the organization.","operationId":"get_shift_types_api_v1_shift_types_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"include","in":"query","required":false,"schema":{"type":"string","description":"Which fields to include in the response","title":"Include"},"description":"Which fields to include in the response"}],"responses":{"200":{"description":"Returns a list of shift types.","content":{"application/json":{"schema":{},"example":[{"id":2,"name":"2x HOURS","color":"#ff2fa4"}]}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Shift Types"],"summary":"Add Shift Type","description":"Add a new shift type to the current user's organization. This may include attributes such as unique name, and associated roles or departments.","operationId":"add_shift_type_api_v1_shift_types_post","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ShiftTypeNew"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ShiftTypeRead"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/shift_types/{id}":{"put":{"tags":["Shift Types"],"summary":"Update Shift Type","description":"Update an existing shift type in the current user's organization, allowing modification of its attributes.","operationId":"update_shift_type_api_v1_shift_types__id__put","security":[{"HTTPBearer":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer","description":"The ID of the shift type to update","title":"Id"},"description":"The ID of the shift type to update"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ShiftTypeNew"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ShiftTypeRead"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Shift Types"],"summary":"Delete Shift Type","description":"Remove a specific shift type by its ID from the organization.","operationId":"delete_shift_type_api_v1_shift_types__id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer","description":"The ID of the shift type to delete","title":"Id"},"description":"The ID of the shift type to delete"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/activities":{"get":{"tags":["Activities"],"summary":"Get Activities By Date Range","operationId":"get_activities_by_date_range_api_v1_activities_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"start","in":"query","required":true,"schema":{"type":"string","format":"date-time","description":"Return all activities from this date e.g. 2024-05-09T08:00:00. Can't request more than 1 week at a time.","title":"Start"},"description":"Return all activities from this date e.g. 2024-05-09T08:00:00. Can't request more than 1 week at a time."},{"name":"end","in":"query","required":true,"schema":{"type":"string","format":"date-time","description":"Return all activities up until this date e.g. 2024-05-09T08:00:00. Can't request more than 1 week at a time.","title":"End"},"description":"Return all activities up until this date e.g. 2024-05-09T08:00:00. Can't request more than 1 week at a time."}],"responses":{"200":{"description":"Returns a list of activities.","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/DynamicActivityOut"},"title":"Response Get Activities By Date Range Api V1 Activities Get"},"example":[{"start":"2024-05-12T13:00:00+00:00","end":"2024-05-12T14:00:00+00:00","notes":"chart review","activity_type_id":7,"shift_ids":[],"archived":false,"id":43412},{"start":"2024-05-12T13:00:00+00:00","end":"2024-05-12T14:00:00+00:00","notes":"chart review","activity_type_id":7,"shift_ids":[],"archived":false,"id":43413},{"start":"2024-05-13T15:00:00+00:00","end":"2024-05-13T15:10:00+00:00","notes":"chart review","activity_type_id":7,"shift_ids":[43121],"archived":false,"id":43796}]}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Activities"],"summary":"Add Activity","description":"Add a new activity to the current user's organization. The activity should be an instance of an existing activity type and it may include attributes such as unique name, date, and associated roles or departments.","operationId":"add_activity_api_v1_activities_post","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ActivityNew"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ActivityRead"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/activities/{id}":{"put":{"tags":["Activities"],"summary":"Update Activity","description":"Update an existing activity in the current user's organization, allowing modification of its attributes. The activity should remain an instance of its original activity type.","operationId":"update_activity_api_v1_activities__id__put","security":[{"HTTPBearer":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer","description":"The ID of the activity to update","title":"Id"},"description":"The ID of the activity to update"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ActivityNew"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ActivityRead"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Activities"],"summary":"Delete Activity","description":"Remove a specific activity by its ID from the organization.","operationId":"delete_activity_api_v1_activities__id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer","description":"The ID of the activity to delete","title":"Id"},"description":"The ID of the activity to delete"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/slots/availability":{"get":{"tags":["Slots"],"summary":"Get Availability","operationId":"get_availability_api_v1_slots_availability_get","parameters":[{"name":"organisation_id","in":"query","required":true,"schema":{"type":"integer","description":"Organisation to book with","title":"Organisation Id"},"description":"Organisation to book with"},{"name":"start","in":"query","required":true,"schema":{"type":"string","format":"date-time","description":"Return slots from this date.","title":"Start"},"description":"Return slots from this date."},{"name":"end","in":"query","required":true,"schema":{"type":"string","format":"date-time","description":"Return slots up to this date.","title":"End"},"description":"Return slots up to this date."},{"name":"provider_ids","in":"query","required":false,"schema":{"anyOf":[{"type":"array","items":{"type":"integer"}},{"type":"null"}],"description":"Provider person IDs to filter on","title":"Provider Ids"},"description":"Provider person IDs to filter on"},{"name":"appointment_type_id","in":"query","required":true,"schema":{"type":"integer","description":"Appointment type to find availability for","title":"Appointment Type Id"},"description":"Appointment type to find availability for"},{"name":"patient_state","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Patient's state, used when the appointment type requires patient-state licensure","title":"Patient State"},"description":"Patient's state, used when the appointment type requires patient-state licensure"},{"name":"patient_payor_id","in":"query","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"description":"Patient's payor, used when the appointment type requires provider payor enrollment","title":"Patient Payor Id"},"description":"Patient's payor, used when the appointment type requires provider payor enrollment"},{"name":"birth_date","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"description":"Patient's date of birth, used when the appointment type has age-based match criteria","title":"Birth Date"},"description":"Patient's date of birth, used when the appointment type has age-based match criteria"},{"name":"language","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Patient's language, used when the appointment type has language-based match criteria","title":"Language"},"description":"Patient's language, used when the appointment type has language-based match criteria"},{"name":"payor_name","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Patient's payor, by name, used when the appointment type requires provider payor enrollment","title":"Payor Name"},"description":"Patient's payor, by name, used when the appointment type requires provider payor enrollment"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/slots/availability/admin":{"get":{"tags":["Slots"],"summary":"Get Availability Admin","operationId":"get_availability_admin_api_v1_slots_availability_admin_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"start","in":"query","required":true,"schema":{"type":"string","format":"date-time","description":"Return slots from this date.","title":"Start"},"description":"Return slots from this date."},{"name":"end","in":"query","required":true,"schema":{"type":"string","format":"date-time","description":"Return slots up to this date.","title":"End"},"description":"Return slots up to this date."},{"name":"provider_ids","in":"query","required":false,"schema":{"anyOf":[{"type":"array","items":{"type":"integer"}},{"type":"null"}],"description":"Provider person IDs to filter on","title":"Provider Ids"},"description":"Provider person IDs to filter on"},{"name":"appointment_type_id","in":"query","required":true,"schema":{"type":"integer","description":"Appointment type to find availability for","title":"Appointment Type Id"},"description":"Appointment type to find availability for"},{"name":"patient_state","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Patient's state, used when the appointment type requires patient-state licensure","title":"Patient State"},"description":"Patient's state, used when the appointment type requires patient-state licensure"},{"name":"patient_payor_id","in":"query","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"description":"Patient's payor, used when the appointment type requires provider payor enrollment","title":"Patient Payor Id"},"description":"Patient's payor, used when the appointment type requires provider payor enrollment"},{"name":"patient_id","in":"query","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"description":"Patient being booked; their enrolled payors are used when the appointment type requires payor enrollment","title":"Patient Id"},"description":"Patient being booked; their enrolled payors are used when the appointment type requires payor enrollment"},{"name":"admin_mode","in":"query","required":false,"schema":{"type":"boolean","description":"If true, return availability for the admin view instead of the patient view","default":false,"title":"Admin Mode"},"description":"If true, return availability for the admin view instead of the patient view"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/slots/info":{"get":{"tags":["Slots"],"summary":"Get Slots Info","operationId":"get_slots_info_api_v1_slots_info_get","parameters":[{"name":"organisation_id","in":"query","required":true,"schema":{"type":"integer","description":"Organisation to book with","title":"Organisation Id"},"description":"Organisation to book with"},{"name":"patient_id","in":"query","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"description":"If provided, return this patient's booking-relevant data","title":"Patient Id"},"description":"If provided, return this patient's booking-relevant data"},{"name":"appointment_type_id","in":"query","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"description":"If provided, return this appointment type's labels","title":"Appointment Type Id"},"description":"If provided, return this appointment type's labels"},{"name":"provider_ids","in":"query","required":false,"schema":{"anyOf":[{"type":"array","items":{"type":"integer"}},{"type":"null"}],"description":"If provided, return these providers' names","title":"Provider Ids"},"description":"If provided, return these providers' names"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/slots/public/{activity_id}":{"get":{"tags":["Slots"],"summary":"Get Public Slot","description":"Rebooking links are public URLs shared with a patient that allow them to\nrebook their appointment. They point at /patient/reschedule and only carry\nthe clinic, appointment, and patient ids. The patient is not logged in, so\nthis route looks the appointment up and returns the current visit:\nappointment type id and name, length, start, time updated, organisation\ntimezone, and provider ids. The page uses the type and providers to find a\nnew time and book a replacement, then cancels this appointment.\n\nReturns 404 unless that patient is on the appointment. Archived\nappointments are already excluded by the lookup, so a successful response\nhas cancelled set to false. is_past is true when the visit has already\nended, and the page then refuses changes.","operationId":"get_public_slot_api_v1_slots_public__activity_id__get","parameters":[{"name":"activity_id","in":"path","required":true,"schema":{"type":"integer","description":"The ID of the appointment to retrieve","title":"Activity Id"},"description":"The ID of the appointment to retrieve"},{"name":"organisation_id","in":"query","required":true,"schema":{"type":"integer","description":"Organisation the appointment belongs to","title":"Organisation Id"},"description":"Organisation the appointment belongs to"},{"name":"patient_id","in":"query","required":true,"schema":{"type":"integer","description":"Patient viewing the appointment; must be on the appointment","title":"Patient Id"},"description":"Patient viewing the appointment; must be on the appointment"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Slots"],"summary":"Delete Public Slot","operationId":"delete_public_slot_api_v1_slots_public__activity_id__delete","parameters":[{"name":"activity_id","in":"path","required":true,"schema":{"type":"integer","description":"The ID of the appointment to cancel","title":"Activity Id"},"description":"The ID of the appointment to cancel"},{"name":"organisation_id","in":"query","required":true,"schema":{"type":"integer","description":"Organisation the appointment belongs to","title":"Organisation Id"},"description":"Organisation the appointment belongs to"},{"name":"patient_id","in":"query","required":true,"schema":{"type":"integer","description":"Patient cancelling; must be on the appointment","title":"Patient Id"},"description":"Patient cancelling; must be on the appointment"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/slots":{"get":{"tags":["Slots"],"summary":"Get Appointments By Date","operationId":"get_appointments_by_date_api_v1_slots_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"start","in":"query","required":true,"schema":{"type":"string","format":"date-time","description":"Window start","title":"Start"},"description":"Window start"},{"name":"end","in":"query","required":true,"schema":{"type":"string","format":"date-time","description":"Window end","title":"End"},"description":"Window end"},{"name":"person_ids","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Comma-separated person ids","title":"Person Ids"},"description":"Comma-separated person ids"},{"name":"include","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Related objects to include, e.g. 'patients(id),providers(id),payor(name)'","title":"Include"},"description":"Related objects to include, e.g. 'patients(id),providers(id),payor(name)'"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/DynamicAppointmentOut"},"title":"Response Get Appointments By Date Api V1 Slots Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Slots"],"summary":"Add Slot","operationId":"add_slot_api_v1_slots_post","parameters":[{"name":"organisation_id","in":"query","required":true,"schema":{"type":"integer","description":"Organisation to book with","title":"Organisation Id"},"description":"Organisation to book with"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppointmentNew"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/slots/{id}":{"get":{"tags":["Slots"],"summary":"Get Slot By Id","operationId":"get_slot_by_id_api_v1_slots__id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer","description":"The ID of the slot to retrieve","title":"Id"},"description":"The ID of the slot to retrieve"},{"name":"include","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Related objects to include, e.g. 'patients(id),providers(id),payor(name)'","title":"Include"},"description":"Related objects to include, e.g. 'patients(id),providers(id),payor(name)'"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DynamicAppointmentOut"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Slots"],"summary":"Delete Slot","operationId":"delete_slot_api_v1_slots__id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer","description":"The ID of the slot to delete","title":"Id"},"description":"The ID of the slot to delete"},{"name":"patient_id","in":"query","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"description":"If the appointment has other patients, remove only this patient instead of deleting it","title":"Patient Id"},"description":"If the appointment has other patients, remove only this patient instead of deleting it"},{"name":"force","in":"query","required":false,"schema":{"type":"boolean","description":"If true, delete the whole appointment even when other patients are on it","default":false,"title":"Force"},"description":"If true, delete the whole appointment even when other patients are on it"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/slots/validate":{"post":{"tags":["Slots"],"summary":"Validate Slot","operationId":"validate_slot_api_v1_slots_validate_post","parameters":[{"name":"organisation_id","in":"query","required":true,"schema":{"type":"integer","description":"Organisation to book with","title":"Organisation Id"},"description":"Organisation to book with"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppointmentNew"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/slots/admin":{"post":{"tags":["Slots"],"summary":"Add Slot Admin","operationId":"add_slot_admin_api_v1_slots_admin_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"admin_mode","in":"query","required":false,"schema":{"type":"boolean","description":"If true, validate the booking against the admin view instead of the patient view","default":false,"title":"Admin Mode"},"description":"If true, validate the booking against the admin view instead of the patient view"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AppointmentNew"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/devices":{"get":{"tags":["Devices"],"summary":"Get Devices","operationId":"get_devices_api_v1_devices_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}},"security":[{"HTTPBearer":[]}]},"post":{"tags":["Devices"],"summary":"Add Device","operationId":"add_device_api_v1_devices_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DeviceNew"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/v1/pay_rules":{"get":{"tags":["Pay Rules"],"summary":"Get Pay Rules","description":"Retrieve all pay rules within the organization.","operationId":"get_pay_rules_api_v1_pay_rules_get","responses":{"200":{"description":"Returns a list of pay rules.","content":{"application/json":{"schema":{},"example":[{"id":2,"name":"2x HOURS","hourly_value":"20"}]}}}},"security":[{"HTTPBearer":[]}]},"post":{"tags":["Pay Rules"],"summary":"Add Pay Rule","description":"Add a new pay rule to the current user's organization. This may include attributes such as unique name, and associated roles or departments.","operationId":"add_pay_rule_api_v1_pay_rules_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PayRuleNew"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PayRuleRead"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/v1/pay_rules/{id}":{"put":{"tags":["Pay Rules"],"summary":"Update Pay Rule","description":"Update an existing pay rule in the current user's organization, allowing modification of its attributes.","operationId":"update_pay_rule_api_v1_pay_rules__id__put","security":[{"HTTPBearer":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer","description":"The ID of the shift type to update","title":"Id"},"description":"The ID of the shift type to update"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PayRuleNew"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PayRuleRead"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Pay Rules"],"summary":"Delete Pay Rule","description":"Remove a specific pay rule by its ID from the organization.","operationId":"delete_pay_rule_api_v1_pay_rules__id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer","description":"The ID of the shift type to delete","title":"Id"},"description":"The ID of the shift type to delete"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/payments":{"get":{"tags":["Payments"],"summary":"Get Payments","operationId":"get_payments_api_v1_payments_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"person_ids","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Comma separated list of person ids to filter by","title":"Person Ids"},"description":"Comma separated list of person ids to filter by"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/license_types":{"get":{"tags":["License Types"],"summary":"Get License Types","description":"Retrieve all license types within the current user's organization.","operationId":"get_license_types_api_v1_license_types_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"include_roles","in":"query","required":false,"schema":{"anyOf":[{"type":"boolean"},{"type":"null"}],"description":"Whether to include roles","default":false,"title":"Include Roles"},"description":"Whether to include roles"},{"name":"include_licenses","in":"query","required":false,"schema":{"anyOf":[{"type":"boolean"},{"type":"null"}],"description":"Whether to include licenses","default":false,"title":"Include Licenses"},"description":"Whether to include licenses"},{"name":"eager","in":"query","required":false,"schema":{"anyOf":[{"type":"boolean"},{"type":"null"}],"description":"Whether to eager load joins","default":true,"title":"Eager"},"description":"Whether to eager load joins"}],"responses":{"200":{"description":"Returns a list of license types.","content":{"application/json":{"schema":{},"example":[{"id":357,"name":"Python","is_qualification":false},{"id":358,"name":"React.js","is_qualification":false},{"id":359,"name":"CPA","is_qualification":false}]}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["License Types"],"summary":"Add License Type","description":"Add a new license and skill type to the current user's organization with a unique name, maximum hours per week, and associated role IDs.","operationId":"add_license_type_api_v1_license_types_post","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LicenseTypeNew"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LicenseTypeRead"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/license_types/licenses":{"get":{"tags":["License Types"],"summary":"Get Licenses","operationId":"get_licenses_api_v1_license_types_licenses_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/LicenseAPI"},"type":"array","title":"Response Get Licenses Api V1 License Types Licenses Get"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/v1/license_types/{id}":{"put":{"tags":["License Types"],"summary":"Update License Type","description":"Update an existing license and skill type in the current user's organization.","operationId":"update_license_type_api_v1_license_types__id__put","security":[{"HTTPBearer":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer","description":"The ID of the license type to update","title":"Id"},"description":"The ID of the license type to update"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LicenseTypeNew"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LicenseTypeRead"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["License Types"],"summary":"Delete License Type","description":"Remove a specific license and skill type by its ID from the organization.","operationId":"delete_license_type_api_v1_license_types__id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer","description":"The ID of the license type to delete","title":"Id"},"description":"The ID of the license type to delete"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LicenseTypeRead"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/integrations/webhook/purpose-med/healthie/appointments":{"post":{"tags":["Integration Webhook"],"summary":"Purpose Med Pull Healthie Appointments","operationId":"purpose_med_pull_healthie_appointments_api_v1_integrations_webhook_purpose_med_healthie_appointments_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HealthieWebhookPayload"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/integrations/webhook/openloop/healthie/appointments":{"post":{"tags":["Integration Webhook"],"summary":"Open Loop Pull Healthie Appointments","operationId":"open_loop_pull_healthie_appointments_api_v1_integrations_webhook_openloop_healthie_appointments_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HealthieWebhookPayload"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/prompts":{"get":{"tags":["Prompts"],"summary":"Get Prompts","operationId":"get_prompts_api_v1_prompts_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/Prompt"},"type":"array","title":"Response Get Prompts Api V1 Prompts Get"}}}}},"security":[{"HTTPBearer":[]}]},"post":{"tags":["Prompts"],"summary":"Create Prompt","operationId":"create_prompt_api_v1_prompts_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PromptNew"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Prompt"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/v1/prompts/{id}":{"put":{"tags":["Prompts"],"summary":"Update Prompt","operationId":"update_prompt_api_v1_prompts__id__put","security":[{"HTTPBearer":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer","title":"Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PromptOptional"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Prompt"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Prompts"],"summary":"Delete Prompt","operationId":"delete_prompt_api_v1_prompts__id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer","title":"Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Prompt"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/unavailabilities":{"get":{"tags":["Unavailabilities"],"summary":"Get Unavailabilities By Date Range","operationId":"get_unavailabilities_by_date_range_api_v1_unavailabilities_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"start","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"description":"Return unavailabilities from this date eg. 2024-05-09T08:00:00. Can't request more than 1 week at a time.","title":"Start"},"description":"Return unavailabilities from this date eg. 2024-05-09T08:00:00. Can't request more than 1 week at a time."},{"name":"end","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"description":"Return unavailabilities up until this date e.g 2024-05-09T08:00:00. Can't request more than 1 week at a time.","title":"End"},"description":"Return unavailabilities up until this date e.g 2024-05-09T08:00:00. Can't request more than 1 week at a time."},{"name":"person_ids","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"null"}],"description":"Filter unavailabilities by person ids (e.g. '4,6,7,8')","title":"Person Ids"},"description":"Filter unavailabilities by person ids (e.g. '4,6,7,8')"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/UnavailabilityResponse"},"title":"Response Get Unavailabilities By Date Range Api V1 Unavailabilities Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/unavailabilities/future_balance/{person_id}":{"get":{"tags":["Unavailabilities"],"summary":"Get Future Balance","operationId":"get_future_balance_api_v1_unavailabilities_future_balance__person_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"person_id","in":"path","required":true,"schema":{"type":"integer","description":"The ID of the person to retrieve","title":"Person Id"},"description":"The ID of the person to retrieve"},{"name":"dates","in":"query","required":false,"schema":{"anyOf":[{"type":"array","items":{"type":"string"}},{"type":"null"}],"description":"Optional dates to query the future balance for (e.g. [\"2024-05-09\", \"2024-05-10\"]). If not provided, only today's date will be queried.","title":"Dates"},"description":"Optional dates to query the future balance for (e.g. [\"2024-05-09\", \"2024-05-10\"]). If not provided, only today's date will be queried."}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/unavailabilities/balances/batch":{"post":{"tags":["Unavailabilities"],"summary":"Get Batch Time Off Balances","description":"Calculate time off balances for multiple people.\n\nUseful for reporting and displaying balances across teams/roles.\nCalculates balances considering:\n- Current balance from ADP or accrual rules\n- Already scheduled time off\n- Future balance predictions for ADP-backed policies\n\nArgs:\n    batch_request: Request containing person IDs and calculation parameters\n\nReturns:\n    Balance information for each person","operationId":"get_batch_time_off_balances_api_v1_unavailabilities_balances_batch_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TimeOffBalanceBatchRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TimeOffBalanceBatchResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/v1/pay_cycles":{"get":{"tags":["Pay Cycles"],"summary":"Get Pay Cycles","operationId":"get_pay_cycles_api_v1_pay_cycles_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}},"security":[{"HTTPBearer":[]}]},"post":{"tags":["Pay Cycles"],"summary":"Add Pay Cycle","operationId":"add_pay_cycle_api_v1_pay_cycles_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PayCycleNew"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PayCycle"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/v1/pay_cycles/{id}":{"put":{"tags":["Pay Cycles"],"summary":"Update Pay Cycle","operationId":"update_pay_cycle_api_v1_pay_cycles__id__put","security":[{"HTTPBearer":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer","description":"The ID of the pay cycle to update","title":"Id"},"description":"The ID of the pay cycle to update"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PayCycleOptional"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PayCycle"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Pay Cycles"],"summary":"Delete Pay Cycle","operationId":"delete_pay_cycle_api_v1_pay_cycles__id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer","description":"The ID of the pay cycle to delete","title":"Id"},"description":"The ID of the pay cycle to delete"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/unavailability_types":{"get":{"tags":["UnavailabilityTypes"],"summary":"Get Unavailability Types","operationId":"get_unavailability_types_api_v1_unavailability_types_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"include_teams","in":"query","required":false,"schema":{"type":"boolean","default":true,"title":"Include Teams"}},{"name":"include_roles","in":"query","required":false,"schema":{"type":"boolean","default":true,"title":"Include Roles"}},{"name":"include_people","in":"query","required":false,"schema":{"type":"boolean","default":true,"title":"Include People"}},{"name":"include_accrual_rules","in":"query","required":false,"schema":{"type":"boolean","default":true,"title":"Include Accrual Rules"}},{"name":"include_custom_options","in":"query","required":false,"schema":{"type":"boolean","default":true,"title":"Include Custom Options"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/payors":{"get":{"tags":["Payors"],"summary":"Get Payors","operationId":"get_payors_api_v1_payors_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}},"security":[{"HTTPBearer":[]}]},"post":{"tags":["Payors"],"summary":"Add Payor","operationId":"add_payor_api_v1_payors_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PayorNew"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/v1/payors/enrollments":{"get":{"tags":["Payors"],"summary":"Get Payor Enrollments","operationId":"get_payor_enrollments_api_v1_payors_enrollments_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/PayorEnrollmentAPI"},"type":"array","title":"Response Get Payor Enrollments Api V1 Payors Enrollments Get"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/v1/payors/{id}":{"put":{"tags":["Payors"],"summary":"Update Payor","operationId":"update_payor_api_v1_payors__id__put","security":[{"HTTPBearer":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer","description":"The ID of the payor to update","title":"Id"},"description":"The ID of the payor to update"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PayorOptional"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Payors"],"summary":"Delete Payor","operationId":"delete_payor_api_v1_payors__id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer","description":"The ID of the payor to delete","title":"Id"},"description":"The ID of the payor to delete"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/patients":{"get":{"tags":["Patients"],"summary":"Get Patients","operationId":"get_patients_api_v1_patients_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"include_archived","in":"query","required":false,"schema":{"anyOf":[{"type":"boolean"},{"type":"null"}],"description":"Whether to include archived patients","default":false,"title":"Include Archived"},"description":"Whether to include archived patients"},{"name":"include_payor_enrollments","in":"query","required":false,"schema":{"anyOf":[{"type":"boolean"},{"type":"null"}],"description":"Whether to include payor enrollments","default":false,"title":"Include Payor Enrollments"},"description":"Whether to include payor enrollments"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Patients"],"summary":"Add Patient","operationId":"add_patient_api_v1_patients_post","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PatientNew"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Patient"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/patients/{id}":{"get":{"tags":["Patients"],"summary":"Get Patient By Id","operationId":"get_patient_by_id_api_v1_patients__id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer","description":"The ID of the patient to retrieve","title":"Id"},"description":"The ID of the patient to retrieve"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PatientsOutExternalAPI"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"put":{"tags":["Patients"],"summary":"Update Patient","operationId":"update_patient_api_v1_patients__id__put","security":[{"HTTPBearer":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer","description":"The ID of the patient to update","title":"Id"},"description":"The ID of the patient to update"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PatientOptional"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Patient"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Patients"],"summary":"Delete Patient","operationId":"delete_patient_api_v1_patients__id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer","description":"The ID of the patient to delete","title":"Id"},"description":"The ID of the patient to delete"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/assistant/feedback":{"post":{"tags":["Activities"],"summary":"Create Feedback","operationId":"create_feedback_api_v1_assistant_feedback_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/FeedbackInput"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/v1/assistant/mutations":{"post":{"tags":["Activities"],"summary":"Post Mutations","description":"Save writes. Forecast actions and request policy are checked first.\n\nA failure there is a 422 and nothing is saved. Field checks run inside the apply.\ncheck_approval_requirements is set by the code executor. Only then does ai_update_approval\nstop the list: that write and everything after it come back in pending.","operationId":"post_mutations_api_v1_assistant_mutations_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"check_approval_requirements","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Check Approval Requirements"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/MutationsIn"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/assistant":{"get":{"tags":["Activities"],"summary":"Get Messages","operationId":"get_messages_api_v1_assistant_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"thread_id","in":"query","required":false,"schema":{"type":"integer","title":"Thread Id"}},{"name":"include_sender","in":"query","required":false,"schema":{"type":"boolean","default":true,"title":"Include Sender"}},{"name":"include_jobs","in":"query","required":false,"schema":{"type":"boolean","default":true,"title":"Include Jobs"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","maximum":500,"default":50,"title":"Limit"}},{"name":"offset","in":"query","required":false,"schema":{"type":"integer","minimum":0,"default":0,"title":"Offset"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Activities"],"summary":"Handle User Message","operationId":"handle_user_message_api_v1_assistant_post","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserMessageInput"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/assistant/threads":{"get":{"tags":["Activities"],"summary":"Get Threads","operationId":"get_threads_api_v1_assistant_threads_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/ThreadAPIResponse"},"type":"array","title":"Response Get Threads Api V1 Assistant Threads Get"}}}}},"security":[{"HTTPBearer":[]}]},"post":{"tags":["Activities"],"summary":"Create Thread","operationId":"create_thread_api_v1_assistant_threads_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ThreadNew"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ThreadAPIResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/v1/assistant/threads/{thread_id}/mark-read":{"put":{"tags":["Activities"],"summary":"Mark Thread As Read","operationId":"mark_thread_as_read_api_v1_assistant_threads__thread_id__mark_read_put","security":[{"HTTPBearer":[]}],"parameters":[{"name":"thread_id","in":"path","required":true,"schema":{"type":"integer","title":"Thread Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/assistant/threads/{thread_id}":{"delete":{"tags":["Activities"],"summary":"Delete Thread","operationId":"delete_thread_api_v1_assistant_threads__thread_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"thread_id","in":"path","required":true,"schema":{"type":"integer","title":"Thread Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/assistant/workflows":{"get":{"tags":["Activities"],"summary":"Get Workflows","description":"The org's workflows with the tools each one adds to the assistant.","operationId":"get_workflows_api_v1_assistant_workflows_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/Workflow"},"type":"array","title":"Response Get Workflows Api V1 Assistant Workflows Get"}}}}},"security":[{"HTTPBearer":[]}]},"post":{"tags":["Activities"],"summary":"Create Workflow","operationId":"create_workflow_api_v1_assistant_workflows_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/WorkflowNew"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Workflow"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/v1/assistant/workflows/{workflow_id}":{"put":{"tags":["Activities"],"summary":"Update Workflow","operationId":"update_workflow_api_v1_assistant_workflows__workflow_id__put","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workflow_id","in":"path","required":true,"schema":{"type":"integer","title":"Workflow Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/WorkflowOptional"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Workflow"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Activities"],"summary":"Delete Workflow","operationId":"delete_workflow_api_v1_assistant_workflows__workflow_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workflow_id","in":"path","required":true,"schema":{"type":"integer","title":"Workflow Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/assistant/workflows/{workflow_id}/tools":{"post":{"tags":["Activities"],"summary":"Create Workflow Tool","operationId":"create_workflow_tool_api_v1_assistant_workflows__workflow_id__tools_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workflow_id","in":"path","required":true,"schema":{"type":"integer","title":"Workflow Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/WorkflowToolNew"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/WorkflowTool"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/assistant/workflows/{workflow_id}/tools/{tool_id}":{"put":{"tags":["Activities"],"summary":"Update Workflow Tool","operationId":"update_workflow_tool_api_v1_assistant_workflows__workflow_id__tools__tool_id__put","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workflow_id","in":"path","required":true,"schema":{"type":"integer","title":"Workflow Id"}},{"name":"tool_id","in":"path","required":true,"schema":{"type":"integer","title":"Tool Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/WorkflowToolOptional"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/WorkflowTool"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Activities"],"summary":"Delete Workflow Tool","operationId":"delete_workflow_tool_api_v1_assistant_workflows__workflow_id__tools__tool_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workflow_id","in":"path","required":true,"schema":{"type":"integer","title":"Workflow Id"}},{"name":"tool_id","in":"path","required":true,"schema":{"type":"integer","title":"Tool Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/assistant/workflow_runs":{"get":{"tags":["Activities"],"summary":"Get Workflow Runs","description":"Which conversations were attributed to each workflow, and how closely it was followed.","operationId":"get_workflow_runs_api_v1_assistant_workflow_runs_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"workflow_id","in":"query","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Workflow Id"}},{"name":"thread_id","in":"query","required":false,"schema":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Thread Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/WorkflowRun"},"title":"Response Get Workflow Runs Api V1 Assistant Workflow Runs Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/assistant/workflow_runs/{run_id}/messages":{"get":{"tags":["Activities"],"summary":"Get Workflow Run Messages","description":"The conversation behind one run, in the order it was sent.\n\nA run holds message ids rather than text, and can span threads and channels, so this\nis the join the caller would otherwise have to do per thread.","operationId":"get_workflow_run_messages_api_v1_assistant_workflow_runs__run_id__messages_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"run_id","in":"path","required":true,"schema":{"type":"integer","title":"Run Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/WorkflowRunMessage"},"title":"Response Get Workflow Run Messages Api V1 Assistant Workflow Runs  Run Id  Messages Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/assistant/workflow_runs/score":{"post":{"tags":["Activities"],"summary":"Score Person Workflows","description":"Re-group one person's recent messages now, skipping the idle wait the sweep applies.","operationId":"score_person_workflows_api_v1_assistant_workflow_runs_score_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ScorePersonInput"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/WorkflowRun"},"type":"array","title":"Response Score Person Workflows Api V1 Assistant Workflow Runs Score Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/v1/assistant/confirm":{"post":{"tags":["Activities"],"summary":"Confirm Tool Calls","operationId":"confirm_tool_calls_api_v1_assistant_confirm_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConfirmToolCallsInput"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/v1/assistant/cancel_scheduled_jobs":{"post":{"tags":["Activities"],"summary":"Cancel Scheduled Jobs","description":"Cancel scheduled jobs associated with a message.","operationId":"cancel_scheduled_jobs_api_v1_assistant_cancel_scheduled_jobs_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CancelScheduledJobsInput"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/v1/assistant/scheduled_trigger":{"post":{"tags":["Activities"],"summary":"Scheduled Trigger","operationId":"scheduled_trigger_api_v1_assistant_scheduled_trigger_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ScheduledTriggerRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/v1/assistant/send_outbound":{"post":{"tags":["Activities"],"summary":"Send Outbound Message","description":"Send SMS or email on behalf of the current user. Admins only.","operationId":"send_outbound_message_api_v1_assistant_send_outbound_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SendOutboundMessageInput"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/v1/sms/webhook/incoming":{"post":{"tags":["SMS Webhook"],"summary":"Receive Sms","description":"Receives incoming SMS messages from Twilio.\n\nConfigure in Twilio Console > Phone Numbers > Your Number > Messaging:\nWebhook URL: https://your-domain.com/api/v1/sms/webhook/incoming","operationId":"receive_sms_api_v1_sms_webhook_incoming_post","requestBody":{"content":{"application/x-www-form-urlencoded":{"schema":{"$ref":"#/components/schemas/Body_receive_sms_api_v1_sms_webhook_incoming_post"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/propelauth/webhook":{"post":{"tags":["PropelAuth Webhook"],"summary":"Propelauth Webhook","operationId":"propelauth_webhook_api_v1_propelauth_webhook_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/v1/rb2b/webhook":{"post":{"tags":["RB2B Webhook"],"summary":"Rb2B Webhook","operationId":"rb2b_webhook_api_v1_rb2b_webhook_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}}}},"/api/v1/google/webhook":{"post":{"tags":["Google Calendar Webhook"],"summary":"Google Calendar Webhook","operationId":"google_calendar_webhook_api_v1_google_webhook_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Google Calendar Webhook Api V1 Google Webhook Post"}}}}}}},"/api/v1/slack-post/send":{"post":{"tags":["Slack Post"],"summary":"Slack Post Send","operationId":"slack_post_send_api_v1_slack_post_send_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SlackPostPayload"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/v1/ai-security/events":{"get":{"tags":["AI Security"],"summary":"Get Events","operationId":"get_events_api_v1_ai_security_events_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"start_date","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"description":"Filter events on or after this datetime (ISO 8601)","title":"Start Date"},"description":"Filter events on or after this datetime (ISO 8601)"},{"name":"end_date","in":"query","required":false,"schema":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"description":"Filter events on or before this datetime (ISO 8601)","title":"End Date"},"description":"Filter events on or before this datetime (ISO 8601)"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/AiSecurityEventAPI"},"title":"Response Get Events Api V1 Ai Security Events Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["AI Security"],"summary":"Create Event","operationId":"create_event_api_v1_ai_security_events_post","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AiSecurityEventNew"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AiSecurityEventAPI"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/ai-security/not-installed":{"get":{"tags":["AI Security"],"summary":"Get Not Installed","operationId":"get_not_installed_api_v1_ai_security_not_installed_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/PersonPhiStatusAPI"},"type":"array","title":"Response Get Not Installed Api V1 Ai Security Not Installed Get"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/v1/ai-security/heartbeat":{"post":{"tags":["AI Security"],"summary":"Heartbeat","operationId":"heartbeat_api_v1_ai_security_heartbeat_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/HeartbeatIn"}}},"required":true},"responses":{"204":{"description":"Successful Response"},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/v1/ai-security/events/{event_id}/accept":{"patch":{"tags":["AI Security"],"summary":"Accept Event","operationId":"accept_event_api_v1_ai_security_events__event_id__accept_patch","security":[{"HTTPBearer":[]}],"parameters":[{"name":"event_id","in":"path","required":true,"schema":{"type":"integer","title":"Event Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AiSecurityEventAPI"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/ai-security/settings":{"get":{"tags":["AI Security"],"summary":"Get Settings","operationId":"get_settings_api_v1_ai_security_settings_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AiSecuritySettingsAPI"}}}}},"security":[{"HTTPBearer":[]}]},"put":{"tags":["AI Security"],"summary":"Update Settings","operationId":"update_settings_api_v1_ai_security_settings_put","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AiSecuritySettingsUpdate"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AiSecuritySettingsAPI"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/api/v1/external/auth/exchange":{"post":{"tags":["External Auth"],"summary":"Exchange Code","operationId":"exchange_code_api_v1_external_auth_exchange_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ExchangeRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TokenResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/external/auth/refresh":{"post":{"tags":["External Auth"],"summary":"Refresh Token","operationId":"refresh_token_api_v1_external_auth_refresh_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RefreshRequest"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TokenResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/simulate_events/500/manual_raise":{"post":{"summary":"Manual Raise 500","operationId":"manual_raise_500_api_v1_simulate_events_500_manual_raise_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}},"security":[{"HTTPBearer":[]}]}},"/api/v1/simulate_events/500/natural_error":{"post":{"summary":"Natural Raise 500","operationId":"natural_raise_500_api_v1_simulate_events_500_natural_error_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}},"security":[{"HTTPBearer":[]}]}},"/api/v1/simulate_events/500/id/{id}":{"post":{"summary":"Raise With Id 500","operationId":"raise_with_id_500_api_v1_simulate_events_500_id__id__post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string","title":"Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/api/v1/simulate_events/500/chained":{"post":{"summary":"Chained Raise 500","operationId":"chained_raise_500_api_v1_simulate_events_500_chained_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}},"security":[{"HTTPBearer":[]}]}},"/api/v1/simulate_events/500/chained_implicit":{"post":{"summary":"Chained Implicit Raise 500","operationId":"chained_implicit_raise_500_api_v1_simulate_events_500_chained_implicit_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}},"security":[{"HTTPBearer":[]}]}},"/api/v1/simulate_events/500/library_raise":{"post":{"summary":"Library Raise 500","operationId":"library_raise_500_api_v1_simulate_events_500_library_raise_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}},"security":[{"HTTPBearer":[]}]}},"/api/v1/simulate_events/500/nested":{"post":{"summary":"Nested Raise 500","operationId":"nested_raise_500_api_v1_simulate_events_500_nested_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}},"security":[{"HTTPBearer":[]}]}},"/api/v1/simulate_events/500/slow":{"post":{"summary":"Slow Raise 500","operationId":"slow_raise_500_api_v1_simulate_events_500_slow_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"seconds","in":"query","required":false,"schema":{"type":"number","default":11,"title":"Seconds"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}}},"components":{"schemas":{"AccessLevelResponse":{"properties":{"id":{"type":"integer","title":"Id"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name"},"archived":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Archived"}},"type":"object","required":["id"],"title":"AccessLevelResponse"},"Action":{"properties":{"action_type":{"type":"string","title":"Action Type","description":"The type of action"},"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status","description":"Outcome of the action, e.g. pending/approved/denied/cancelled/denied_invalid/denied_auto_denial for action_type=request_decision; not every action_type uses this"},"source":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source","description":"Where the action came from, e.g. api or agent"},"person_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Person Id","description":"The ID of the associated person"},"organisation_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Organisation Id","description":"The ID of the organisation"},"timestamp":{"type":"string","format":"date-time","title":"Timestamp","description":"The time (UTC) when the action happened e.g 2023-07-27 06:30:00+00"},"auto_generated":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Auto Generated","description":"Whether the timestamp was auto-generated or input by a user","default":false},"activity_type_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Activity Type Id","description":"The ID of the associated activity type"},"shift_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Shift Id","description":"The ID of the associated shift"},"linked_clock_in_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Linked Clock In Id","description":"ID of earlier clock_in for which a clock_out relates"},"external_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"External Id","description":"The ID of the associated external action"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes","description":"Notes about the action"},"value":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Value","description":"The value of the action"},"value_metadata":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Value Metadata","description":"The metadata of the action"},"request_metadata":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Request Metadata","description":"The metadata of the request"},"expires":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expires","description":"The time (UTC) when the action expires e.g 2023-07-27 06:30:00+00"},"request_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Request Id","description":"The ID of the associated request"},"actor_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Actor Id","description":"The ID of the actor performing the action"},"time_processed":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Time Processed","description":"When a notification-queue consumer handled this row; null until then"},"id":{"type":"integer","title":"Id","description":"The unique ID of the activity"},"time_created":{"type":"string","format":"date-time","title":"Time Created","description":"The time (UTC) when the action was created e.g 2023-07-27 06:30:00+00"},"time_updated":{"type":"string","format":"date-time","title":"Time Updated","description":"The time (UTC) when the activity was last updated e.g 2023-07-27 06:30:00+00"},"archived":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Archived","description":"Whether action has been archived","default":false}},"type":"object","required":["action_type","timestamp","time_created","time_updated"],"title":"Action"},"ActionNew":{"properties":{"action_type":{"type":"string","title":"Action Type","description":"The type of action"},"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status","description":"Outcome of the action, e.g. pending/approved/denied/cancelled/denied_invalid/denied_auto_denial for action_type=request_decision; not every action_type uses this"},"source":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source","description":"Where the action came from, e.g. api or agent"},"person_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Person Id","description":"The ID of the associated person"},"organisation_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Organisation Id","description":"The ID of the organisation"},"timestamp":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Timestamp","description":"Timestamp of the action"},"auto_generated":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Auto Generated","description":"Whether the timestamp was auto-generated or input by a user","default":false},"activity_type_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Activity Type Id","description":"The ID of the associated activity type"},"shift_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Shift Id","description":"The ID of the associated shift"},"linked_clock_in_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Linked Clock In Id","description":"ID of earlier clock_in for which a clock_out relates"},"external_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"External Id","description":"The ID of the associated external action"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes","description":"Notes about the action"},"value":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Value","description":"The value of the action"},"value_metadata":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Value Metadata","description":"The metadata of the action"},"request_metadata":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Request Metadata","description":"The metadata of the request"},"expires":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expires","description":"The time (UTC) when the action expires e.g 2023-07-27 06:30:00+00"},"request_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Request Id","description":"The ID of the associated request"},"actor_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Actor Id","description":"The ID of the actor performing the action"},"time_processed":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Time Processed","description":"When a notification-queue consumer handled this row; null until then"}},"type":"object","required":["action_type"],"title":"ActionNew"},"ActionOptional":{"properties":{"action_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Action Type","description":"The type of action"},"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status","description":"Outcome of the action, e.g. pending/approved/denied/cancelled/denied_invalid/denied_auto_denial for action_type=request_decision; not every action_type uses this"},"source":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source","description":"Where the action came from, e.g. api or agent"},"person_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Person Id","description":"The ID of the associated person"},"organisation_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Organisation Id","description":"The ID of the organisation"},"timestamp":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Timestamp","description":"The time (UTC) when the action happened e.g 2023-07-27 06:30:00+00"},"auto_generated":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Auto Generated","description":"Whether the timestamp was auto-generated or input by a user","default":false},"activity_type_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Activity Type Id","description":"The ID of the associated activity type"},"shift_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Shift Id","description":"The ID of the associated shift"},"linked_clock_in_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Linked Clock In Id","description":"ID of earlier clock_in for which a clock_out relates"},"external_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"External Id","description":"The ID of the associated external action"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes","description":"Notes about the action"},"value":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Value","description":"The value of the action"},"value_metadata":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Value Metadata","description":"The metadata of the action"},"request_metadata":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Request Metadata","description":"The metadata of the request"},"expires":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expires","description":"The time (UTC) when the action expires e.g 2023-07-27 06:30:00+00"},"request_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Request Id","description":"The ID of the associated request"},"actor_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Actor Id","description":"The ID of the actor performing the action"},"time_processed":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Time Processed","description":"When a notification-queue consumer handled this row; null until then"},"id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Id","description":"The unique ID of the activity"},"time_created":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Time Created","description":"The time (UTC) when the action was created e.g 2023-07-27 06:30:00+00"},"time_updated":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Time Updated","description":"The time (UTC) when the activity was last updated e.g 2023-07-27 06:30:00+00"},"archived":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Archived","description":"Whether action has been archived","default":false}},"type":"object","title":"ActionOptional"},"ActionRead":{"properties":{"action_type":{"type":"string","title":"Action Type","description":"The type of action"},"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status","description":"Outcome of the action, e.g. pending/approved/denied/cancelled/denied_invalid/denied_auto_denial for action_type=request_decision; not every action_type uses this"},"source":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source","description":"Where the action came from, e.g. api or agent"},"person_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Person Id","description":"The ID of the associated person"},"organisation_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Organisation Id","description":"The ID of the organisation"},"timestamp":{"type":"string","format":"date-time","title":"Timestamp","description":"The time (UTC) when the action happened e.g 2023-07-27 06:30:00+00"},"auto_generated":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Auto Generated","description":"Whether the timestamp was auto-generated or input by a user","default":false},"activity_type_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Activity Type Id","description":"The ID of the associated activity type"},"shift_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Shift Id","description":"The ID of the associated shift"},"linked_clock_in_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Linked Clock In Id","description":"ID of earlier clock_in for which a clock_out relates"},"external_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"External Id","description":"The ID of the associated external action"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes","description":"Notes about the action"},"value":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Value","description":"The value of the action"},"value_metadata":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Value Metadata","description":"The metadata of the action"},"request_metadata":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Request Metadata","description":"The metadata of the request"},"expires":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expires","description":"The time (UTC) when the action expires e.g 2023-07-27 06:30:00+00"},"request_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Request Id","description":"The ID of the associated request"},"actor_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Actor Id","description":"The ID of the actor performing the action"},"time_processed":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Time Processed","description":"When a notification-queue consumer handled this row; null until then"},"id":{"type":"integer","title":"Id","description":"The unique ID of the activity"},"time_created":{"type":"string","format":"date-time","title":"Time Created","description":"The time (UTC) when the action was created e.g 2023-07-27 06:30:00+00"},"time_updated":{"type":"string","format":"date-time","title":"Time Updated","description":"The time (UTC) when the activity was last updated e.g 2023-07-27 06:30:00+00"},"archived":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Archived","description":"Whether action has been archived","default":false}},"type":"object","required":["action_type","timestamp","time_created","time_updated"],"title":"ActionRead"},"ActionReadAPI":{"properties":{"action_type":{"type":"string","title":"Action Type","description":"The type of action"},"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status","description":"Outcome of the action, e.g. pending/approved/denied/cancelled/denied_invalid/denied_auto_denial for action_type=request_decision; not every action_type uses this"},"source":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Source","description":"Where the action came from, e.g. api or agent"},"person_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Person Id","description":"The ID of the associated person"},"organisation_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Organisation Id","description":"The ID of the organisation"},"timestamp":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Timestamp","description":"Timestamp of the action"},"auto_generated":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Auto Generated","description":"Whether the timestamp was auto-generated or input by a user","default":false},"activity_type_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Activity Type Id","description":"The ID of the associated activity type"},"shift_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Shift Id","description":"The ID of the associated shift"},"linked_clock_in_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Linked Clock In Id","description":"ID of earlier clock_in for which a clock_out relates"},"external_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"External Id","description":"The ID of the associated external action"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes","description":"Notes about the action"},"value":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Value","description":"The value of the action"},"value_metadata":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Value Metadata","description":"The metadata of the action"},"request_metadata":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Request Metadata","description":"The metadata of the request"},"expires":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expires","description":"The time (UTC) when the action expires e.g 2023-07-27 06:30:00+00"},"request_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Request Id","description":"The ID of the associated request"},"actor_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Actor Id","description":"The ID of the actor performing the action"},"time_processed":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Time Processed","description":"When a notification-queue consumer handled this row; null until then"},"id":{"type":"integer","title":"Id","description":"The unique ID of the activity"},"archived":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Archived","description":"Whether action has been archived","default":false},"time_created":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Time Created","description":"The time (UTC) when the action was created"},"time_updated":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Time Updated","description":"The time (UTC) when the action was last updated"}},"type":"object","required":["action_type","id"],"title":"ActionReadAPI"},"ActivityClockInRequest":{"properties":{"shift_id":{"type":"integer","title":"Shift Id","description":"ID of the shift"},"activity_type_id":{"type":"integer","title":"Activity Type Id","description":"ID of the activity type to clock into"},"external_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"External Id","description":"External reference ID (e.g., ticket number)"}},"type":"object","required":["shift_id","activity_type_id"],"title":"ActivityClockInRequest","description":"Request body for clocking into an activity"},"ActivityClockOutRequest":{"properties":{"shift_id":{"type":"integer","title":"Shift Id","description":"ID of the shift"}},"type":"object","required":["shift_id"],"title":"ActivityClockOutRequest","description":"Request body for clocking out of an activity"},"ActivityNew":{"properties":{"id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Id","description":"The unique ID of the activity"},"activity_type_id":{"type":"integer","title":"Activity Type Id","description":"The ID of the activity type"},"start":{"type":"string","format":"date-time","title":"Start","description":"The start time (UTC) of the activity e.g 2023-07-27 06:30:00+00"},"end":{"type":"string","format":"date-time","title":"End","description":"The end time (UTC) of the activity e.g 2023-07-27 06:30:00+00"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes","description":"Notes for the activity"},"recurrence_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Recurrence Id","description":"The recurrence ID for the activity"},"shift_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Shift Ids","description":"List of shift IDs to which the activity is joined"},"archived":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Archived","description":"Whether activity has been archived","default":false},"recurrence_details":{"anyOf":[{"$ref":"#/components/schemas/RecurrenceNew"},{"type":"null"}],"description":"The recurrence details for the activity"},"external_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"External Id","description":"ID linking activity to external integrations, i.e. Healthie, etc"},"pattern_override_uuid":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Pattern Override Uuid","description":"Slot uuid from the recurrence's pattern_overrides that produced this activity"},"conference":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Conference","description":"Video conference room details (provider, room name/url, expiry); server-managed"}},"type":"object","required":["activity_type_id","start","end"],"title":"ActivityNew"},"ActivityOptional":{"properties":{"id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Id","description":"The unique ID of the activity"},"activity_type_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Activity Type Id","description":"The ID of the activity type"},"start":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Start","description":"The start time (UTC) of the activity"},"end":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"End","description":"The end time (UTC) of the activity"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes","description":"Notes for the activity"},"recurrence_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Recurrence Id","description":"The recurrence ID for the activity"},"shift_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Shift Ids","description":"List of shift IDs to which the activity is joined"},"archived":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Archived","description":"Whether activity has been archived"},"recurrence_details":{"anyOf":[{"$ref":"#/components/schemas/RecurrenceNew"},{"type":"null"}],"description":"The recurrence details for the activity"},"organisation_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Organisation Id","description":"The ID of the organisation"},"time_created":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Time Created","description":"The time when the activity was created"},"time_updated":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Time Updated","description":"The time when the activity was last updated"},"time_published":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Time Published","description":"When activity was last published"},"gcal_event_ids":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Gcal Event Ids","description":"Google Calendar event IDs"},"conference":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Conference","description":"Video conference room details (provider, room name/url, expiry)"},"external_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"External Id","description":"ID linking activity to external integrations, i.e. Healthie, etc"},"pattern_override_uuid":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Pattern Override Uuid","description":"Slot uuid from the recurrence's pattern_overrides that produced this activity"}},"type":"object","title":"ActivityOptional"},"ActivityRead":{"properties":{"id":{"type":"integer","title":"Id","description":"The unique ID of the activity"},"activity_type_id":{"type":"integer","title":"Activity Type Id","description":"The ID of the activity type"},"start":{"type":"string","format":"date-time","title":"Start","description":"The start time (UTC) of the activity e.g 2023-07-27 06:30:00+00"},"end":{"type":"string","format":"date-time","title":"End","description":"The end time (UTC) of the activity e.g 2023-07-27 06:30:00+00"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes","description":"Notes for the activity"},"recurrence_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Recurrence Id","description":"The recurrence ID for the activity"},"shift_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Shift Ids","description":"List of shift IDs to which the activity is joined"},"archived":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Archived","description":"Whether activity has been archived","default":false},"recurrence_details":{"anyOf":[{"$ref":"#/components/schemas/RecurrenceNew"},{"type":"null"}],"description":"The recurrence details for the activity"},"external_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"External Id","description":"ID linking activity to external integrations, i.e. Healthie, etc"},"pattern_override_uuid":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Pattern Override Uuid","description":"Slot uuid from the recurrence's pattern_overrides that produced this activity"},"conference":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Conference","description":"Video conference room details (provider, room name/url, expiry); server-managed"},"organisation_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Organisation Id","description":"The ID of the organisation that the activity belongs to"},"time_created":{"type":"string","format":"date-time","title":"Time Created","description":"The time (UTC) when the activity was created e.g 2023-07-27 06:30:00+00"},"time_updated":{"type":"string","format":"date-time","title":"Time Updated","description":"The time (UTC) when the activity was last updated e.g 2023-07-27 06:30:00+00"},"time_published":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Time Published","description":"When activity was last published"}},"type":"object","required":["activity_type_id","start","end","time_created","time_updated"],"title":"ActivityRead"},"ActivitySwapRequest":{"properties":{"shift_id":{"type":"integer","title":"Shift Id","description":"ID of the shift"},"activity_type_id":{"type":"integer","title":"Activity Type Id","description":"ID of the activity type to swap to"}},"type":"object","required":["shift_id","activity_type_id"],"title":"ActivitySwapRequest","description":"Request body for swapping the activity type on the active activity without resetting the timer"},"ActivityTypeKind":{"type":"string","enum":["blocked","available","appointment"],"title":"ActivityTypeKind"},"ActivityTypeNew":{"properties":{"name":{"type":"string","title":"Name","description":"The name of the activity type"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Description of the activity type"},"tag":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tag","description":"Tag associated with the activity type (e.g. Out of Office, Focus Time","default":"default"},"kind":{"anyOf":[{"$ref":"#/components/schemas/ActivityTypeKind"},{"type":"null"}],"description":"The kind of activity type (blocked, available, appointment)"},"slot_generation_mode":{"anyOf":[{"$ref":"#/components/schemas/SlotGenerationMode"},{"type":"null"}],"description":"Whether the appointment is bookable across the whole shift (default_available) or only where availability is added explicitly (availability_required)","default":"default_available"},"max_capacity":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Capacity","description":"Max number of people who can book the same slot"},"booking_limit":{"anyOf":[{"$ref":"#/components/schemas/BookingLimit"},{"type":"null"}],"description":"Patients can book at most {count} appointments within {period_value} {period_unit}(s)"},"required_hosts":{"anyOf":[{"items":{"$ref":"#/components/schemas/RequiredHost"},"type":"array"},{"type":"null"}],"title":"Required Hosts","description":"Teams and roles required to host this activity type, with counts"},"color":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Color","description":"The color of the activity type"},"aht":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Aht","description":"Average handle time of the activity in seconds"},"shrinkage":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Shrinkage","description":"Shrinkage of the activity in seconds"},"priority":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Priority","description":"Priority of the activity between 0 and 1"},"required_hours":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Required Hours","description":"Required hours target"},"enabled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Enabled","description":"Whether this activity type is enabled","default":true},"service":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Service","description":"Service time of the activity in seconds"},"sla":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Sla","description":"Service level agreement of the activity (percentage expressed as a fraction)"},"parameters":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Parameters","description":"Scheduling parameters"},"custom_option_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Custom Option Ids","description":"List of custom option IDs associated with the shift type"},"custom_fields":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Custom Fields","description":"Custom field values for this activity type, keyed by custom field ID"},"client_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Client Id","description":"ID of the client that this activity type belongs to"},"group":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Group","description":"Group of the activity type"},"external_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"External Id","description":"External ID of the activity type"},"external_appointment_type_ids":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"External Appointment Type Ids","description":"List of external appointment type IDs (e.g., Healthie)"},"integration_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Integration Id","description":"ID of the integration that owns/syncs this activity type"},"exclude_from_time_tracking":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Exclude From Time Tracking","description":"Whether employees can select this activity type in timesheets and clock-ins"},"patient_licensure_states":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Patient Licensure States","description":"States where licensure is required: null = none, [\"ANY\"] = any state, or a list of state codes"},"patient_payor_enrollment_required":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Patient Payor Enrollment Required","description":"Whether this activity type requires the provider to be enrolled in the patient's payor"},"patient_match_criteria":{"anyOf":[{"items":{"$ref":"#/components/schemas/PatientMatchCriterion"},"type":"array"},{"type":"null"}],"title":"Patient Match Criteria","description":"Patient/provider attribute match criteria (age, language)"},"patient_provider_match_mode":{"anyOf":[{"$ref":"#/components/schemas/PatientProviderMatchMode"},{"type":"null"}],"description":"Steer bookings to the patient's primary provider: always | if_primary_unavailable"},"slot_alerts":{"anyOf":[{"items":{"$ref":"#/components/schemas/SlotAlert"},"type":"array"},{"type":"null"}],"title":"Slot Alerts","description":"Warnings and alerts: rules for alerting when the next available slot is too far out"},"license_type_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"License Type Ids","description":"List of license type IDs that this activity type requires"},"team_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Team Ids","description":"List of teams that can perform this activity"},"role_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Role Ids","description":"List of roles that can perform this activity"},"person_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Person Ids","description":"List of people that can perform this activity"}},"type":"object","required":["name"],"title":"ActivityTypeNew"},"ActivityTypeOutAPI":{"properties":{"id":{"type":"integer","title":"Id","description":"The unique ID of the activity type"},"name":{"type":"string","title":"Name","description":"The name of the activity type"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Description of the activity type"},"tag":{"type":"string","title":"Tag","description":"Tag associated with the activity type (e.g. Out of Office, Focus Time"},"kind":{"anyOf":[{"$ref":"#/components/schemas/ActivityTypeKind"},{"type":"null"}],"description":"The kind of activity type (blocked, available, appointment)"},"slot_generation_mode":{"anyOf":[{"$ref":"#/components/schemas/SlotGenerationMode"},{"type":"null"}],"description":"Whether the appointment is bookable across the whole shift (default_available) or only where availability is added explicitly (availability_required)","default":"default_available"},"max_capacity":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Capacity","description":"Max number of people who can book the same slot"},"booking_limit":{"anyOf":[{"$ref":"#/components/schemas/BookingLimit"},{"type":"null"}],"description":"Patients can book at most {count} appointments within {period_value} {period_unit}(s)"},"required_hosts":{"anyOf":[{"items":{"$ref":"#/components/schemas/RequiredHost"},"type":"array"},{"type":"null"}],"title":"Required Hosts","description":"Teams and roles required to host this activity type, with counts"},"color":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Color","description":"The color of the activity type"},"aht":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Aht","description":"Average handle time of the activity in seconds"},"shrinkage":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Shrinkage","description":"Shrinkage of the activity in seconds"},"service":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Service","description":"Service time of the activity in seconds"},"sla":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Sla","description":"Service level agreement of the activity (percentage expressed as a fraction)"},"priority":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Priority","description":"Priority of the activity between 0 and 1"},"required_hours":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Required Hours","description":"Required hours target"},"parameters":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Parameters","description":"Scheduling parameters"},"custom_fields":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Custom Fields","description":"Custom field values for this activity type, keyed by custom field ID"},"client_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Client Id","description":"ID of the client that this activity type belongs to"},"group":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Group","description":"Group of the activity type"},"external_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"External Id","description":"External ID of the activity type"},"external_appointment_type_ids":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"External Appointment Type Ids","description":"List of external appointment type IDs (e.g., Healthie)"},"integration_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Integration Id","description":"ID of the integration that owns/syncs this activity type"},"exclude_from_time_tracking":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Exclude From Time Tracking","description":"Whether employees can select this activity type in timesheets and clock-ins"},"patient_licensure_states":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Patient Licensure States","description":"States where licensure is required: null = none, [\"ANY\"] = any state, or a list of state codes"},"patient_payor_enrollment_required":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Patient Payor Enrollment Required","description":"Whether this activity type requires the provider to be enrolled in the patient's payor"},"patient_match_criteria":{"anyOf":[{"items":{"$ref":"#/components/schemas/PatientMatchCriterion"},"type":"array"},{"type":"null"}],"title":"Patient Match Criteria","description":"Patient/provider attribute match criteria (age, language)"},"patient_provider_match_mode":{"anyOf":[{"$ref":"#/components/schemas/PatientProviderMatchMode"},{"type":"null"}],"description":"Steer bookings to the patient's primary provider: always | if_primary_unavailable"},"slot_alerts":{"anyOf":[{"items":{"$ref":"#/components/schemas/SlotAlert"},"type":"array"},{"type":"null"}],"title":"Slot Alerts","description":"Warnings and alerts: rules for alerting when the next available slot is too far out"},"organisation_id":{"type":"integer","title":"Organisation Id","description":"The ID of the organisation the activity type belongs to"},"time_created":{"type":"string","format":"date-time","title":"Time Created","description":"The time (UTC) when the activity type was created e.g 2023-07-27 06:30:00+00"},"time_updated":{"type":"string","format":"date-time","title":"Time Updated","description":"The time (UTC) when the activity type was last updated e.g 2023-07-27 06:30:00+00"},"archived":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Archived","default":false},"enabled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Enabled","description":"Whether this activity type is enabled","default":true},"license_types":{"anyOf":[{"items":{"$ref":"#/components/schemas/LicenseTypeReponse"},"type":"array"},{"type":"null"}],"title":"License Types"},"teams":{"anyOf":[{"items":{"$ref":"#/components/schemas/TeamReponse"},"type":"array"},{"type":"null"}],"title":"Teams"},"roles":{"anyOf":[{"items":{"$ref":"#/components/schemas/RoleReponse"},"type":"array"},{"type":"null"}],"title":"Roles"},"people":{"anyOf":[{"items":{"$ref":"#/components/schemas/PersonResponse"},"type":"array"},{"type":"null"}],"title":"People"},"custom_options":{"anyOf":[{"items":{"$ref":"#/components/schemas/CustomOptionModel"},"type":"array"},{"type":"null"}],"title":"Custom Options"},"datastreams":{"anyOf":[{"items":{"$ref":"#/components/schemas/DatastreamModel"},"type":"array"},{"type":"null"}],"title":"Datastreams"},"total_roles":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Total Roles"},"total_teams":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Total Teams"},"total_people":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Total People"},"total_licenses":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Total Licenses"},"total_skills":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Total Skills"}},"type":"object","required":["id","name","tag","organisation_id","time_created","time_updated"],"title":"ActivityTypeOutAPI"},"ActivityTypeRead":{"properties":{"id":{"type":"integer","title":"Id","description":"The unique ID of the activity type"},"name":{"type":"string","title":"Name","description":"The name of the activity type"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Description of the activity type"},"tag":{"type":"string","title":"Tag","description":"Tag associated with the activity type (e.g. Out of Office, Focus Time"},"kind":{"anyOf":[{"$ref":"#/components/schemas/ActivityTypeKind"},{"type":"null"}],"description":"The kind of activity type (blocked, available, appointment)"},"slot_generation_mode":{"anyOf":[{"$ref":"#/components/schemas/SlotGenerationMode"},{"type":"null"}],"description":"Whether the appointment is bookable across the whole shift (default_available) or only where availability is added explicitly (availability_required)","default":"default_available"},"max_capacity":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Capacity","description":"Max number of people who can book the same slot"},"booking_limit":{"anyOf":[{"$ref":"#/components/schemas/BookingLimit"},{"type":"null"}],"description":"Patients can book at most {count} appointments within {period_value} {period_unit}(s)"},"required_hosts":{"anyOf":[{"items":{"$ref":"#/components/schemas/RequiredHost"},"type":"array"},{"type":"null"}],"title":"Required Hosts","description":"Teams and roles required to host this activity type, with counts"},"color":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Color","description":"The color of the activity type"},"aht":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Aht","description":"Average handle time of the activity in seconds"},"shrinkage":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Shrinkage","description":"Shrinkage of the activity in seconds"},"service":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Service","description":"Service time of the activity in seconds"},"priority":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Priority","description":"Priority of the activity between 0 and 1"},"required_hours":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Required Hours","description":"Required hours target"},"custom_option_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Custom Option Ids","description":"List of custom option IDs associated with the shift type"},"custom_fields":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Custom Fields","description":"Custom field values for this activity type, keyed by custom field ID"},"enabled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Enabled","description":"Whether this activity type is enabled","default":true},"client_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Client Id","description":"ID of the client that this activity type belongs to"},"group":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Group","description":"Group of the activity type"},"external_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"External Id","description":"External ID of the activity type"},"external_appointment_type_ids":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"External Appointment Type Ids","description":"List of external appointment type IDs (e.g., Healthie)"},"integration_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Integration Id","description":"ID of the integration that owns/syncs this activity type"},"exclude_from_time_tracking":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Exclude From Time Tracking","description":"Whether employees can select this activity type in timesheets and clock-ins"},"patient_licensure_states":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Patient Licensure States","description":"States where licensure is required: null = none, [\"ANY\"] = any state, or a list of state codes"},"patient_payor_enrollment_required":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Patient Payor Enrollment Required","description":"Whether this activity type requires the provider to be enrolled in the patient's payor"},"patient_match_criteria":{"anyOf":[{"items":{"$ref":"#/components/schemas/PatientMatchCriterion"},"type":"array"},{"type":"null"}],"title":"Patient Match Criteria","description":"Patient/provider attribute match criteria (age, language)"},"patient_provider_match_mode":{"anyOf":[{"$ref":"#/components/schemas/PatientProviderMatchMode"},{"type":"null"}],"description":"Steer bookings to the patient's primary provider: always | if_primary_unavailable"},"sla":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Sla","description":"Service level agreement of the activity (percentage expressed as a fraction)"},"parameters":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Parameters","description":"Scheduling parameters"},"slot_alerts":{"anyOf":[{"items":{"$ref":"#/components/schemas/SlotAlert"},"type":"array"},{"type":"null"}],"title":"Slot Alerts","description":"Warnings and alerts: rules for alerting when the next available slot is too far out"},"license_type_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"License Type Ids","description":"List of license type IDs that this activity type requires"},"team_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Team Ids","description":"List of teams that can perform this activity"},"role_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Role Ids","description":"List of roles that can perform this activity"},"person_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Person Ids","description":"List of people that can perform this activity"}},"type":"object","required":["id","name","tag"],"title":"ActivityTypeRead"},"ActualTicketCountsRequest":{"properties":{"integration_ids":{"items":{"type":"integer"},"type":"array","title":"Integration Ids","description":"List of integration IDs to include"},"start":{"type":"string","format":"date-time","title":"Start","description":"Start datetime for data (ISO format)"},"end":{"type":"string","format":"date-time","title":"End","description":"End datetime for data (ISO format)"},"custom_field_filters":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Custom Field Filters","description":"Optional filters for custom fields"}},"type":"object","required":["integration_ids","start","end"],"title":"ActualTicketCountsRequest"},"AiSecurityEventAPI":{"properties":{"id":{"type":"integer","title":"Id"},"organisation_id":{"type":"integer","title":"Organisation Id"},"person_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Person Id"},"site":{"type":"string","title":"Site"},"flags":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Flags"},"accepted":{"type":"boolean","title":"Accepted"},"time_created":{"type":"string","format":"date-time","title":"Time Created"}},"type":"object","required":["id","organisation_id","person_id","site","flags","accepted","time_created"],"title":"AiSecurityEventAPI"},"AiSecurityEventNew":{"properties":{"site":{"type":"string","title":"Site"},"flags":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Flags"}},"type":"object","required":["site","flags"],"title":"AiSecurityEventNew"},"AiSecuritySettingsAPI":{"properties":{"mode":{"type":"string","title":"Mode"},"sites":{"items":{"type":"string"},"type":"array","title":"Sites"},"regex_patterns":{"anyOf":[{"items":{"additionalProperties":true,"type":"object"},"type":"array"},{"type":"null"}],"title":"Regex Patterns"},"keywords":{"anyOf":[{"items":{"additionalProperties":true,"type":"object"},"type":"array"},{"type":"null"}],"title":"Keywords"}},"type":"object","required":["mode","sites"],"title":"AiSecuritySettingsAPI"},"AiSecuritySettingsUpdate":{"properties":{"mode":{"type":"string","title":"Mode"},"sites":{"items":{"type":"string"},"type":"array","title":"Sites"},"regex_patterns":{"anyOf":[{"items":{"additionalProperties":true,"type":"object"},"type":"array"},{"type":"null"}],"title":"Regex Patterns"},"keywords":{"anyOf":[{"items":{"additionalProperties":true,"type":"object"},"type":"array"},{"type":"null"}],"title":"Keywords"}},"type":"object","required":["mode","sites"],"title":"AiSecuritySettingsUpdate"},"AppointmentNew":{"properties":{"appointment_type_id":{"type":"integer","title":"Appointment Type Id","description":"Activity type this appointment is booked against"},"start":{"type":"string","format":"date-time","title":"Start","description":"Start time (UTC)"},"end":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"End","description":"End time (UTC). Unset when the source visit has no scheduled end."},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes","description":"Notes for the appointment"},"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status","description":"Lifecycle status from the source system, such as booked or canceled"},"conference":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Conference","description":"Video conference room details"},"gcal_event_ids":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Gcal Event Ids","description":"Google Calendar event ids"},"archived":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Archived","description":"Whether the appointment has been deleted","default":false},"external_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"External Id","description":"ID from an external system such as Athena or Acuity"},"patient_state":{"anyOf":[{"type":"string","maxLength":2},{"type":"null"}],"title":"Patient State","description":"Two-letter patient state code"},"payor_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Payor Id","description":"Planbase payor for this appointment"},"custom_fields":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Custom Fields","description":"Custom fields of the appointment"},"provider_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Provider Ids","description":"Providers on the appointment"},"patient_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Patient Ids","description":"Patients already on the appointment"},"patient":{"anyOf":[{"$ref":"#/components/schemas/PatientNew"},{"type":"null"}],"description":"Patient to find or create when patient_ids is not given"},"time_created":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Time Created","description":"When the appointment was created in the source system"}},"type":"object","required":["appointment_type_id","start"],"title":"AppointmentNew"},"AvailabilityEntry":{"properties":{"start":{"type":"string","format":"date-time","title":"Start"},"end":{"type":"string","format":"date-time","title":"End"}},"type":"object","required":["start","end"],"title":"AvailabilityEntry"},"AvailabilityNew":{"properties":{"start":{"type":"string","format":"date-time","title":"Start","description":"The start time (UTC) of the availability e.g 2023-07-27 06:30:00+00"},"end":{"type":"string","format":"date-time","title":"End","description":"The end time (UTC) of the availability e.g 2023-07-27 06:30:00+00"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes","description":"Notes"},"person_id":{"type":"integer","title":"Person Id","description":"The ID of the person the availability belongs to"},"hidden":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Hidden","description":"Whether availability has been hidden","default":false},"source_shift_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Source Shift Id","description":"Underlying shift ID, if auto-created from a shift request"}},"type":"object","required":["start","end","person_id"],"title":"AvailabilityNew"},"AvailabilityRead":{"properties":{"id":{"type":"integer","title":"Id","description":"ID of the availability being updated"},"start":{"type":"string","format":"date-time","title":"Start","description":"The start time (UTC) of the availability e.g 2023-07-27 06:30:00+00"},"end":{"type":"string","format":"date-time","title":"End","description":"The end time (UTC) of the availability e.g 2023-07-27 06:30:00+00"},"person_id":{"type":"integer","title":"Person Id","description":"The ID of the person the availability belongs to"},"hidden":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Hidden","description":"Whether availability has been hidden","default":false},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes","description":"Notes"},"time_created":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Time Created","description":"The time (UTC) when the availability was created"},"time_updated":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Time Updated","description":"The time (UTC) when the availability was last updated"},"source_shift_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Source Shift Id","description":"Underlying shift ID, if auto-created from a shift request"}},"type":"object","required":["start","end","person_id"],"title":"AvailabilityRead"},"AvailabilityValidationRequest":{"properties":{"person_id":{"type":"integer","title":"Person Id"},"availabilities":{"items":{"$ref":"#/components/schemas/AvailabilityEntry"},"type":"array","title":"Availabilities"}},"type":"object","required":["person_id","availabilities"],"title":"AvailabilityValidationRequest"},"BalanceDetail":{"properties":{"unavailability_type_id":{"type":"integer","title":"Unavailability Type Id","description":"ID of the unavailability type"},"unavailability_type_name":{"type":"string","title":"Unavailability Type Name","description":"Name of the unavailability type"},"balance":{"type":"number","title":"Balance","description":"Current balance in hours"},"scheduled":{"type":"number","title":"Scheduled","description":"Hours already scheduled (other requests)"},"this_request":{"type":"number","title":"This Request","description":"Hours in this request"},"available_hours":{"type":"number","title":"Available Hours","description":"Hours available after deductions"},"is_valid":{"type":"boolean","title":"Is Valid","description":"Whether this type has sufficient balance"},"predictive_balance":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Predictive Balance","description":"Predictive balance in hours"}},"type":"object","required":["unavailability_type_id","unavailability_type_name","balance","scheduled","this_request","available_hours","is_valid"],"title":"BalanceDetail","description":"Detailed balance information for a specific unavailability type"},"BaseTicket":{"properties":{"start":{"type":"integer","title":"Start"},"end":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"End"},"person_email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Person Email"}},"additionalProperties":true,"type":"object","required":["start"],"title":"BaseTicket"},"Body_publish_shifts_api_v1_shifts_publish_post":{"properties":{"shift_ids":{"items":{"type":"integer"},"type":"array","title":"Shift Ids"},"publishing_channels":{"items":{"type":"string","enum":["calendar","sms","slack","email"]},"type":"array","title":"Publishing Channels"}},"type":"object","required":["shift_ids","publishing_channels"],"title":"Body_publish_shifts_api_v1_shifts_publish_post"},"Body_receive_sms_api_v1_sms_webhook_incoming_post":{"properties":{"From":{"type":"string","title":"From"},"Body":{"type":"string","title":"Body","default":""},"MessageSid":{"type":"string","title":"Messagesid"},"NumMedia":{"type":"string","title":"Nummedia","default":"0"}},"type":"object","required":["From","MessageSid"],"title":"Body_receive_sms_api_v1_sms_webhook_incoming_post"},"BookingLimit":{"properties":{"count":{"type":"integer","title":"Count","description":"Max number of appointments a patient can book within the period"},"period_value":{"type":"integer","title":"Period Value","description":"Length of the period, e.g. 2 for '2 weeks'","default":1},"period_unit":{"type":"string","enum":["day","week","month"],"title":"Period Unit","description":"Unit of the period (day | week | month)"}},"type":"object","required":["count","period_unit"],"title":"BookingLimit"},"CancelScheduledJobsInput":{"properties":{"message_id":{"type":"integer","title":"Message Id"}},"type":"object","required":["message_id"],"title":"CancelScheduledJobsInput"},"Client":{"properties":{"name":{"type":"string","title":"Name","description":"The client's name"},"external_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"External Id","description":"The client's external ID"},"secondary_external_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Secondary External Id","description":"The client's secondary external ID"},"operating_hours":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Operating Hours","description":"The client's operating hours"},"account":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Account","description":"The name of the account that this client belongs to"},"person_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Person Ids","description":"List of person IDs associated with this client"},"activity_type_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Activity Type Ids","description":"List of activity type IDs associated with this client"},"license_type_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"License Type Ids","description":"List of license type IDs which require credentialing for this client"},"custom_fields":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Custom Fields","description":"Custom fields for this client (reference/joined-table fields not supported)"},"id":{"type":"integer","title":"Id","description":"The client's primary ID which is generated when the client is created"},"time_created":{"type":"string","format":"date-time","title":"Time Created","description":"The time when the client was created"},"time_updated":{"type":"string","format":"date-time","title":"Time Updated","description":"The time when the client was last updated"},"person_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Person Count","description":"Count of non-archived people assigned to this client"}},"type":"object","required":["name","id","time_created","time_updated"],"title":"Client"},"ClientAssignmentAPI":{"properties":{"person_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Person Id","description":"The ID of the person associated with this assignment."},"client_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Client Id","description":"The ID of the client associated with this assignment."},"start":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Start","description":"When the assignment starts. This field is optional."},"end":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"End","description":"When the assignment ends. This field is optional."},"license_type_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"License Type Id","description":"The ID of the license type associated with this assignment."}},"type":"object","title":"ClientAssignmentAPI"},"ClientAssignmentNew":{"properties":{"client_id":{"type":"integer","title":"Client Id","description":"The ID of the client associated with this assignment."},"start":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Start","description":"When the assignment starts. This field is optional."},"end":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"End","description":"When the assignment ends. This field is optional."},"license_type_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"License Type Id","description":"The ID of the license type associated with this assignment."},"activity_type_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Activity Type Id","description":"The ID of the activity type associated with this assignment."}},"type":"object","required":["client_id"],"title":"ClientAssignmentNew"},"ClientNew":{"properties":{"name":{"type":"string","title":"Name","description":"The client's name"},"external_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"External Id","description":"The client's external ID"},"secondary_external_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Secondary External Id","description":"The client's secondary external ID"},"operating_hours":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Operating Hours","description":"The client's operating hours"},"account":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Account","description":"The name of the account that this client belongs to"},"person_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Person Ids","description":"List of person IDs associated with this client"},"activity_type_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Activity Type Ids","description":"List of activity type IDs associated with this client"},"license_type_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"License Type Ids","description":"List of license type IDs which require credentialing for this client"},"custom_fields":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Custom Fields","description":"Custom fields for this client (reference/joined-table fields not supported)"}},"type":"object","required":["name"],"title":"ClientNew"},"ClientOptional":{"properties":{"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name","description":"The client's name"},"external_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"External Id","description":"The client's external ID"},"secondary_external_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Secondary External Id","description":"The client's secondary external ID"},"operating_hours":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Operating Hours","description":"The client's operating hours"},"account":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Account","description":"The name of the account that this client belongs to"},"person_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Person Ids","description":"List of person IDs associated with this client"},"activity_type_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Activity Type Ids","description":"List of activity type IDs associated with this client"},"license_type_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"License Type Ids","description":"List of license type IDs which require credentialing for this client"},"custom_fields":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Custom Fields","description":"Custom fields for this client (reference/joined-table fields not supported)"},"id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Id","description":"The client's primary ID which is generated when the client is created"},"time_created":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Time Created","description":"The time when the client was created"},"time_updated":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Time Updated","description":"The time when the client was last updated"},"person_count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Person Count","description":"Count of non-archived people assigned to this client"}},"type":"object","title":"ClientOptional"},"ClientRead":{"properties":{"id":{"type":"integer","title":"Id","description":"The client's primary ID which is generated when the client is created"},"name":{"type":"string","title":"Name","description":"The client's name"},"external_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"External Id","description":"The client's external ID"},"secondary_external_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Secondary External Id","description":"The client's secondary external ID"},"operating_hours":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Operating Hours","description":"The client's operating hours"},"account":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Account","description":"The name of the account that this client belongs to"}},"type":"object","required":["id","name"],"title":"ClientRead"},"ClockActionResponse":{"properties":{"shift_id":{"type":"integer","title":"Shift Id"},"message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Message"},"duration_hours":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Duration Hours"},"duration_minutes":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Duration Minutes"}},"type":"object","required":["shift_id"],"title":"ClockActionResponse","description":"Response for clock action endpoints"},"ClockInRequest":{"properties":{"shift_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Shift Id","description":"ID of the shift to clock into. If None, a new shift will be created."},"team_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Team Id","description":"Team ID for new shift (required if shift_id is None)"},"role_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Role Id","description":"Role ID for new shift (required if shift_id is None)"},"flex_hours":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Flex Hours","description":"Whether the shift has flexible hours","default":false}},"type":"object","title":"ClockInRequest","description":"Request body for clocking in"},"ClockOutRequest":{"properties":{"shift_id":{"type":"integer","title":"Shift Id","description":"ID of the shift to clock out of"}},"type":"object","required":["shift_id"],"title":"ClockOutRequest","description":"Request body for clocking out"},"ConfirmToolCallsInput":{"properties":{"message_id":{"type":"integer","title":"Message Id"}},"type":"object","required":["message_id"],"title":"ConfirmToolCallsInput"},"CurrentUserResponse":{"properties":{"id":{"type":"integer","title":"Id","description":"The unique ID of the person"},"first_name":{"type":"string","title":"First Name","description":"The person's first name"},"last_name":{"type":"string","title":"Last Name","description":"The person's last name"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email","description":"The person's email address"},"cell":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cell","description":"The person's cell phone number"},"notifications_text":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Notifications Text","description":"Whether person opts in to SMS communications","default":true},"notifications_slack":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Notifications Slack","description":"Whether person opts in to Slack communications","default":true},"notifications_email":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Notifications Email","description":"Whether person opts in to email communications","default":true},"sms_disabled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Sms Disabled","description":"Whether person has disabled SMS communications through Twilio specifically","default":false},"enable_login":{"type":"boolean","title":"Enable Login","description":"Enable login for this person","default":false},"employee_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Employee Id","description":"The person's employee ID"},"wise_recipient_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Wise Recipient Id","description":"The person's Recipient ID from Wise"},"wise_recipient_currency":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Wise Recipient Currency","description":"The person's Recipient Currency from Wise"},"external_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"External Id","description":"The person's ID from an external system e.g payroll"},"inactive":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Inactive","description":"Whether provider is currently active in Planbase","default":false},"timezone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Timezone","description":"The timezone where the person works."},"start_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Start Date","description":"The start date of the person's employment"},"last_archived_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Archived At","description":"The timestamp when the person was archived"},"employment_end_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Employment End Date","description":"The date when the person's employment ended"},"employment_type":{"anyOf":[{},{"type":"null"}],"title":"Employment Type","description":"The person's employment type, e.g. full-time or part-time"},"custom_option_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Custom Option Ids","description":"List of custom option IDs associated with the person"},"exempt":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Exempt","description":"Whether the person is exempt from overtime"},"rate":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Rate","description":"The person's pay rate"},"rate_type":{"anyOf":[{},{"type":"null"}],"title":"Rate Type","description":"The person's rate type e.g. hourly or salary"},"regular_work_hours":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Regular Work Hours","description":"The person's regular work hours as a JSON object"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes","description":"The person's notes"},"submits_availability":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Submits Availability","description":"Whether the person submits their availability"},"submits_unavailability":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Submits Unavailability","description":"Whether the person submits unavailability"},"saved_filters":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Saved Filters","description":"The person's saved filters"},"pay_cycle_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Pay Cycle Id","description":"The ID of the person's pay cycle"},"pay_cycle_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Pay Cycle Name","description":"The name of the person's pay cycle"},"min_daily_hours":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Min Daily Hours","description":"Minimum contracted daily hours"},"max_daily_hours":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Daily Hours","description":"Maximum contracted daily hours"},"min_weekly_hours":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Min Weekly Hours","description":"Minimum contracted weekly hours"},"max_weekly_hours":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Weekly Hours","description":"Maximum contracted weekly hours"},"min_monthly_hours":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Min Monthly Hours","description":"Minimum contracted monthly hours"},"max_monthly_hours":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Monthly Hours","description":"Maximum contracted monthly hours"},"weekends_month":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Weekends Month","description":"Minimum contracted weekend days per month"},"flex_hours":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Flex Hours","description":"Whether the person's shifts are flexible","default":false},"access_level_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Level Name","description":"The person's access level"},"access_level_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Access Level Id","description":"The ID of the person's access level"},"archived":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Archived","description":"Whether the person is archived","default":false},"organisation_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Organisation Id","description":"The ID of the organisation the person belongs to"},"weekday_start":{"anyOf":[{},{"type":"null"}],"title":"Weekday Start","description":"The first day of the person's work week"},"avatar_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Avatar Url","description":"URL of the person's avatar image"},"clockin_calls":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Clockin Calls","description":"Whether the person gets reminder calls to clock in","default":false},"clockin_required":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Clockin Required","description":"Whether the person is required to clock in","default":false},"employment_classification":{"anyOf":[{},{"type":"null"}],"title":"Employment Classification","description":"The person's employment classification, e.g. W2 or 1099"},"time_created":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Time Created","description":"The time (UTC) when the person was created"},"time_updated":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Time Updated","description":"The time (UTC) when the person was last updated"},"unavailability_allowances":{"anyOf":[{"items":{"$ref":"#/components/schemas/UnavailabilityAllowanceAPIResponse"},"type":"array"},{"type":"null"}],"title":"Unavailability Allowances"},"unavailability_balances":{"anyOf":[{"items":{"$ref":"#/components/schemas/UnavailabilityBalanceAPIResponse"},"type":"array"},{"type":"null"}],"title":"Unavailability Balances"},"status":{"anyOf":[{"$ref":"#/components/schemas/StatusResponse"},{"type":"null"}]},"min_supported_ios_version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Min Supported Ios Version"},"min_supported_client_version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Min Supported Client Version"},"available_organisations":{"anyOf":[{"items":{"$ref":"#/components/schemas/OrganisationMembership"},"type":"array"},{"type":"null"}],"title":"Available Organisations","description":"Orgs this PropelAuth user can switch into (same auth_id, multiple people)"},"org_scope":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Org Scope"}},"type":"object","required":["id","first_name","last_name"],"title":"CurrentUserResponse"},"CustomOption":{"properties":{"field_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Field Name"},"custom_field_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Custom Field Id"},"value":{"type":"string","title":"Value"},"field_type":{"anyOf":[{"$ref":"#/components/schemas/FieldType"},{"type":"null"}]},"id":{"type":"integer","title":"Id"},"time_created":{"type":"string","format":"date-time","title":"Time Created"},"time_updated":{"type":"string","format":"date-time","title":"Time Updated"}},"type":"object","required":["value","id","time_created","time_updated"],"title":"CustomOption"},"CustomOptionModel":{"properties":{"id":{"type":"integer","title":"Id"},"value":{"type":"string","title":"Value"},"field_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Field Name"},"custom_field_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Custom Field Id"}},"type":"object","required":["id","value"],"title":"CustomOptionModel"},"Datastream":{"properties":{"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name","description":"Name of the work stream"},"color":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Color","description":"Color of the datastream"},"forecasting_model":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Forecasting Model","description":"Which model to use for forecasting"},"covariates":{"anyOf":[{"items":{"$ref":"#/components/schemas/DatastreamCovariate"},"type":"array"},{"type":"null"}],"title":"Covariates","description":"Custom-object fields joined as predictors when forecasting_model is ml","default":[]},"license_type_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"License Type Ids","description":"List of license type IDs this datastream includes"},"team_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Team Ids","description":"List of teams this datastream includes"},"role_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Role Ids","description":"List of roles this datastream includes"},"person_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Person Ids","description":"List of people this datastream includes"},"client_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Client Ids","description":"List of clients this datastream includes"},"integration_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Integration Ids","description":"List of integrations this datastream includes"},"unavailability_type_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Unavailability Type Ids","description":"List of unavailability types this datastream includes"},"template_datastream_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Template Datastream Ids","description":"Template datastream IDs to build predictions if there isn't enough historical data"},"aht":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Aht","description":"Average handle time of the datastream"},"interval":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Interval","description":"Time interval of the datastream"},"service":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Service","description":"Target wait time in hours"},"sla":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Sla","description":"Service level agreement of the datastream"},"shrinkage":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Shrinkage","description":"Shrinkage of the datastream"},"efficiency":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Efficiency","description":"Efficiency of the datastream"},"forecast_updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Forecast Updated At","description":"Timestamp when forecast was last generated"},"excluded_keywords":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Excluded Keywords","description":"List of excluded keywords","default":[]},"included_keywords":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Included Keywords","description":"List of included keywords","default":[]},"planbase_assignee":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Planbase Assignee","description":"Whether tickets must be assigned to people in Planbase","default":false},"include_appointments":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Include Appointments","description":"Also count appointments in this forecast","default":false},"appointments_by_time_created":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Appointments By Time Created","description":"Count appointments by time_created instead of start","default":false},"operating_hours":{"anyOf":[{"$ref":"#/components/schemas/OperatingHours"},{"type":"null"}],"description":"Clinic opening hours used to place appointment demand"},"lead_time_transform":{"anyOf":[{"$ref":"#/components/schemas/LeadTimeTransform"},{"type":"null"}],"description":"How bookings spread into the times patients want to be seen"},"location":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Location","description":"Location of the datastream"},"latitude":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Latitude","description":"Latitude of the datastream"},"longitude":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Longitude","description":"Longitude of the datastream"},"region":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Region","description":"Region of the datastream"},"country":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Country","description":"Country of the datastream"},"version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Version","description":"Current model version"},"is_training":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Training","description":"Whether a model is currently being trained","default":false},"daily_average":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Daily Average","description":"Average daily #"},"mape":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Mape","description":"Out of sample MAPE from training"},"id":{"type":"integer","title":"Id","description":"Unique identifier for the work stream"},"time_created":{"type":"string","format":"date-time","title":"Time Created","description":"Timestamp of when the work stream was created"},"time_updated":{"type":"string","format":"date-time","title":"Time Updated","description":"Timestamp of when the work stream was last updated"},"organisation_id":{"type":"integer","title":"Organisation Id","description":"ID of the organization the work stream belongs to"}},"type":"object","required":["id","time_created","time_updated","organisation_id"],"title":"Datastream"},"DatastreamCovariate":{"properties":{"custom_object_id":{"type":"integer","title":"Custom Object Id"},"date_field_id":{"type":"integer","title":"Date Field Id"},"field_ids":{"items":{"type":"integer"},"type":"array","title":"Field Ids","default":[]}},"type":"object","required":["custom_object_id","date_field_id"],"title":"DatastreamCovariate"},"DatastreamModel":{"properties":{"id":{"type":"integer","title":"Id"},"name":{"type":"string","title":"Name"}},"type":"object","required":["id","name"],"title":"DatastreamModel"},"DeviceNew":{"properties":{"device_id":{"type":"string","title":"Device Id","description":"The ID of the device"},"expo_push_token":{"type":"string","title":"Expo Push Token","description":"The Expo push token of the device"},"person_id":{"type":"integer","title":"Person Id","description":"The ID of the associated person"}},"type":"object","required":["device_id","expo_push_token","person_id"],"title":"DeviceNew"},"DirectoryPerson":{"properties":{"id":{"type":"integer","title":"Id"},"first_name":{"type":"string","title":"First Name"},"last_name":{"type":"string","title":"Last Name"},"email":{"type":"string","title":"Email"},"access_level":{"$ref":"#/components/schemas/AccessLevelResponse"}},"type":"object","required":["id","first_name","last_name","email","access_level"],"title":"DirectoryPerson"},"DynamicActivityOut":{"properties":{"id":{"type":"integer","title":"Id","description":"The unique ID of the activity"},"activity_type_id":{"type":"integer","title":"Activity Type Id","description":"The ID of the activity type"},"start":{"type":"string","format":"date-time","title":"Start","description":"The start time (UTC) of the activity e.g 2023-07-27 06:30:00+00"},"end":{"type":"string","format":"date-time","title":"End","description":"The end time (UTC) of the activity e.g 2023-07-27 06:30:00+00"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes","description":"Notes for the activity"},"recurrence_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Recurrence Id","description":"The recurrence ID for the activity"},"shift_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Shift Ids","description":"List of shift IDs to which the activity is joined"},"archived":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Archived","description":"Whether activity has been archived","default":false},"recurrence_details":{"anyOf":[{"$ref":"#/components/schemas/RecurrenceNew"},{"type":"null"}],"description":"The recurrence details for the activity"},"external_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"External Id","description":"ID linking activity to external integrations, i.e. Healthie, etc"},"pattern_override_uuid":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Pattern Override Uuid","description":"Slot uuid from the recurrence's pattern_overrides that produced this activity"},"conference":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Conference","description":"Video conference room details (provider, room name/url, expiry); server-managed"},"organisation_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Organisation Id","description":"The ID of the organisation that the activity belongs to"},"time_created":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Time Created","description":"The time (UTC) when the activity was created e.g 2023-07-27 06:30:00+00"},"time_updated":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Time Updated","description":"The time (UTC) when the activity was last updated e.g 2023-07-27 06:30:00+00"},"time_published":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Time Published","description":"When activity was last published"}},"type":"object","required":["activity_type_id","start","end"],"title":"DynamicActivityOut","description":"ActivityRead for callers validating from an already-loaded ORM Activity rather\nthan an id-only projection.\n\n`shift_ids` is derived from the `shifts` relationship when loaded (left unset otherwise).\n`time_created`/`time_updated` are optional here (unlike ActivityRead) since this also\nvalidates activity snapshots from a shift's published_detail, which lacks them."},"DynamicAppointmentOut":{"properties":{"appointment_type_id":{"type":"integer","title":"Appointment Type Id","description":"Activity type this appointment is booked against"},"start":{"type":"string","format":"date-time","title":"Start","description":"Start time (UTC)"},"end":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"End","description":"End time (UTC). Unset when the source visit has no scheduled end."},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes","description":"Notes for the appointment"},"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status","description":"Lifecycle status from the source system, such as booked or canceled"},"conference":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Conference","description":"Video conference room details"},"gcal_event_ids":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Gcal Event Ids","description":"Google Calendar event ids"},"archived":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Archived","description":"Whether the appointment has been deleted","default":false},"external_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"External Id","description":"ID from an external system such as Athena or Acuity"},"patient_state":{"anyOf":[{"type":"string","maxLength":2},{"type":"null"}],"title":"Patient State","description":"Two-letter patient state code"},"payor_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Payor Id","description":"Planbase payor for this appointment"},"custom_fields":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Custom Fields","description":"Custom fields of the appointment"},"id":{"type":"integer","title":"Id","description":"The unique ID of the appointment"},"organisation_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Organisation Id","description":"Organisation the appointment belongs to"},"time_created":{"type":"string","format":"date-time","title":"Time Created","description":"When the appointment was created"},"time_updated":{"type":"string","format":"date-time","title":"Time Updated","description":"When the appointment was last updated"},"payor":{"anyOf":[{"$ref":"#/components/schemas/DynamicPayorOut"},{"type":"null"}]},"patients":{"anyOf":[{"items":{"$ref":"#/components/schemas/DynamicPatientOut"},"type":"array"},{"type":"null"}],"title":"Patients"},"providers":{"anyOf":[{"items":{"$ref":"#/components/schemas/DynamicProviderOut"},"type":"array"},{"type":"null"}],"title":"Providers"}},"type":"object","required":["appointment_type_id","start","id","time_created","time_updated"],"title":"DynamicAppointmentOut","description":"Appointment plus relationships requested via include."},"DynamicPatientOut":{"properties":{"id":{"type":"integer","title":"Id","description":"The patient's primary ID which is generated when the patient is created"},"external_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"External Id","description":"The patient's external identifier (e.g. EHR ID)"},"first_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"First Name","description":"The patient's first name"},"last_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Name","description":"The patient's last name"},"birth_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Birth Date","description":"The patient's date of birth"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email","description":"The patient's email"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone","description":"The patient's phone number"},"language":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Language","description":"The patient's language"},"address_line1":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address Line1","description":"Address line 1"},"address_line2":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address Line2","description":"Address line 2"},"address_city":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address City","description":"City"},"address_district":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address District","description":"District / county"},"address_state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address State","description":"State or region"},"address_postal_code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address Postal Code","description":"Postal / ZIP code"},"address_country":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address Country","description":"Country"}},"type":"object","required":["id"],"title":"DynamicPatientOut","description":"Patient fields that were actually loaded."},"DynamicPayorOut":{"properties":{"id":{"type":"integer","title":"Id","description":"The payor's primary ID"},"name":{"type":"string","title":"Name","description":"The payor's name"},"group_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Group Name","description":"The payor's group name"},"external_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"External Id","description":"The payor's external ID"}},"type":"object","required":["id","name"],"title":"DynamicPayorOut","description":"Payor fields that were actually loaded. Unrequested columns stay out of the response."},"DynamicProviderOut":{"properties":{"id":{"type":"integer","title":"Id","description":"The provider's person id"},"first_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"First Name"},"last_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Name"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"},"external_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"External Id"}},"type":"object","required":["id"],"title":"DynamicProviderOut","description":"Provider fields that were actually loaded. Only id is required, so providers(id) stays just the id."},"DynamicShiftOut":{"properties":{"id":{"type":"integer","title":"Id","description":"The unique ID of the shift"},"organisation_id":{"type":"integer","title":"Organisation Id","description":"The ID of the organisation the shift belongs to"},"start":{"type":"string","format":"date-time","title":"Start","description":"The start time (UTC) of the shift e.g 2023-07-27 06:30:00+00"},"end":{"type":"string","format":"date-time","title":"End","description":"The end time (UTC) of the shift e.g 2023-07-27 06:30:00+00"},"team_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Team Id","description":"The ID of the team the shift belongs to"},"role_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Role Id","description":"The ID of the role the shift belongs to"},"shift_type_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Shift Type Id","description":"The ID of the shift type"},"person_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Person Id","description":"The ID of the person assigned to the shift (if any)"},"payment_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Payment Id","description":"The ID of the payment associated with the shift"},"people_required":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"People Required","description":"The number of people required for the shift if unassigned"},"rrule":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Rrule","description":"The recurrence rule for the shift"},"recurrence_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Recurrence Id","description":"The recurrence ID for the shift"},"needs_publishing_calendar":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Needs Publishing Calendar","description":"Whether the shift needs re-syncing to the user's calendar","default":false},"needs_publishing_slack":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Needs Publishing Slack","description":"Whether the shift needs re-publishing on slack","default":false},"is_publishing_calendar":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Publishing Calendar","description":"Whether the shift is re-syncing to the user's calendar","default":false},"is_publishing_slack":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Publishing Slack","description":"Whether the shift is re-publishing on slack","default":false},"needs_publishing_email":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Needs Publishing Email","description":"Whether the shift needs re-sending email to the user","default":false},"needs_publishing_sms":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Needs Publishing Sms","description":"Whether the shift needs re-sending sms to the user","default":false},"is_publishing_email":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Publishing Email","description":"Whether the shift is re-sending email to the user","default":false},"is_publishing_sms":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Publishing Sms","description":"Whether the shift is re-sending sms to the user","default":false},"approved":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Approved","description":"Whether timesheet associated with the shift has been approved","default":false},"time_published":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Time Published","description":"When shift was last published"},"auto_approve_changes":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Auto Approve Changes","description":"Whether shift change requests should be approved automatically","default":false},"allow_alternative_times":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Allow Alternative Times","description":"Whether person can request changes to the timing of their shift","default":false},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes","description":"Any notes about the shift"},"created_at_clock_in":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Created At Clock In","description":"Whether shift was created as a result of clocking-in","default":false},"flex_hours":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Flex Hours","description":"Whether the shift has flexible hours","default":false},"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status","description":"The status of the shift","default":"approved"},"archived":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Archived","description":"Whether shift has been archived","default":false},"timecard":{"anyOf":[{"$ref":"#/components/schemas/Timesheet"},{"type":"null"}],"description":"Calculated timecard based on actual clock in/out times"},"scheduled_timecard":{"anyOf":[{"$ref":"#/components/schemas/Timesheet"},{"type":"null"}],"description":"Calculated timecard based on scheduled shift times"},"time_created":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Time Created","description":"The time (UTC) when the shift was created"},"time_updated":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Time Updated","description":"The time (UTC) when the shift was last updated"},"published_detail":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Published Detail","description":"Details the shift that was published"},"activities":{"anyOf":[{"items":{"$ref":"#/components/schemas/DynamicActivityOut"},"type":"array"},{"type":"null"}],"title":"Activities"},"person":{"anyOf":[{"$ref":"#/components/schemas/PersonRead"},{"type":"null"}]},"team":{"anyOf":[{"$ref":"#/components/schemas/TeamRead"},{"type":"null"}]},"role":{"anyOf":[{"$ref":"#/components/schemas/RoleRead"},{"type":"null"}]},"shift_type":{"anyOf":[{"$ref":"#/components/schemas/ShiftTypeRead"},{"type":"null"}]},"actions":{"anyOf":[{"items":{"$ref":"#/components/schemas/ActionReadAPI"},"type":"array"},{"type":"null"}],"title":"Actions"},"clients":{"anyOf":[{"items":{"$ref":"#/components/schemas/ClientRead"},"type":"array"},{"type":"null"}],"title":"Clients"},"license_types":{"anyOf":[{"items":{"$ref":"#/components/schemas/LicenseTypeRead"},"type":"array"},{"type":"null"}],"title":"License Types"},"client_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Client Ids"},"license_type_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"License Type Ids"},"published_status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Published Status"}},"type":"object","required":["id","organisation_id","start","end"],"title":"DynamicShiftOut","description":"Single response shape for both client and non-client /v2 consumers.\n\n`client_ids`/`license_type_ids`/`published_status` are derived here so callers don't\nneed separate id-list vs. full-object serialization paths."},"EligiblePerson":{"properties":{"id":{"type":"integer","title":"Id","description":"The person who could claim this opening"},"first_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"First Name","description":"The person's first name"},"last_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Name","description":"The person's last name"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email","description":"The person's email address"}},"type":"object","required":["id"],"title":"EligiblePerson","description":"A person who could claim this opening.\n\nid, first_name, last_name, and email are the only fields returned."},"ExchangeRequest":{"properties":{"code":{"type":"string","title":"Code"},"redirect_uri":{"type":"string","title":"Redirect Uri"},"code_verifier":{"type":"string","title":"Code Verifier"}},"type":"object","required":["code","redirect_uri","code_verifier"],"title":"ExchangeRequest"},"FeedbackInput":{"properties":{"message_id":{"type":"integer","title":"Message Id","description":"ID of the message (required for create)"},"is_positive":{"type":"boolean","title":"Is Positive","description":"Whether the feedback is positive or negative"},"tags":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Tags","description":"Categories of feedback"},"comments":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Comments","description":"Free-form comments from the user"}},"type":"object","required":["message_id","is_positive"],"title":"FeedbackInput","description":"Schema for creating/updating feedback"},"FieldType":{"type":"string","enum":["text","list","boolean","date","time","datetime","attachment","reference"],"title":"FieldType"},"FilterType":{"type":"string","enum":["AND","OR"],"title":"FilterType"},"ForecastPayload":{"properties":{"datastream_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Datastream Id"},"datastream_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Datastream Name"},"ts_data":{"anyOf":[{"items":{"$ref":"#/components/schemas/TSRecord"},"type":"array"},{"type":"null"}],"title":"Ts Data"},"pred_timestamp_from":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Pred Timestamp From"},"pred_timestamp_to":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Pred Timestamp To"},"timestamp_from":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Timestamp From"},"timestamp_to":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Timestamp To"},"train_model":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Train Model","default":true},"version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Version","default":"default"},"tune_with_daily_mape":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Tune With Daily Mape","default":false},"included_demand_drivers":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Included Demand Drivers","default":{}},"settings":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Settings","default":{}},"box_office":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Box Office","default":false},"max_val_weeks":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Val Weeks","default":3},"coordinates":{"anyOf":[{"items":{"prefixItems":[{"type":"number"},{"type":"number"}],"type":"array","maxItems":2,"minItems":2},"type":"array"},{"type":"null"}],"title":"Coordinates","default":[]}},"type":"object","title":"ForecastPayload"},"ForecastResponse":{"properties":{"id":{"type":"integer","title":"Id"},"name":{"type":"string","title":"Name"},"time_created":{"type":"string","format":"date-time","title":"Time Created","description":"Timestamp of when the datastream was created"},"time_updated":{"type":"string","format":"date-time","title":"Time Updated","description":"Timestamp of when the datastream was last updated"},"is_training":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Training","description":"Whether the datastream is currently training"},"version":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Version","description":"The version of the datastream"}},"type":"object","required":["id","name","time_created","time_updated"],"title":"ForecastResponse"},"HTTPValidationError":{"properties":{"detail":{"items":{"$ref":"#/components/schemas/ValidationError"},"type":"array","title":"Detail"}},"type":"object","title":"HTTPValidationError"},"HealthResponse":{"properties":{"status":{"type":"string","title":"Status","default":"pass"},"description":{"type":"string","title":"Description","default":"Planbase Backend API Service"},"checks":{"additionalProperties":{"items":{"additionalProperties":true,"type":"object"},"type":"array"},"type":"object","title":"Checks","default":{}}},"type":"object","title":"HealthResponse"},"HealthieWebhookPayload":{"properties":{"resource_id":{"type":"integer","title":"Resource Id"},"resource_id_type":{"type":"string","title":"Resource Id Type"},"event_type":{"type":"string","enum":["appointment.created","appointment.updated","appointment.deleted"],"title":"Event Type"},"changed_fields":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Changed Fields"}},"type":"object","required":["resource_id","resource_id_type","event_type"],"title":"HealthieWebhookPayload"},"HeartbeatIn":{"properties":{"active_domain":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Active Domain"}},"type":"object","title":"HeartbeatIn"},"IntegrationRead":{"properties":{"id":{"type":"integer","title":"Id","description":"Unique identifier for the integration"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name","description":"Name of the integration"},"client_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Client Id","description":"Client ID associated with the integration"}},"type":"object","required":["id"],"title":"IntegrationRead"},"LeadTimeSegment":{"properties":{"label":{"anyOf":[{"type":"string","maxLength":100},{"type":"null"}],"title":"Label"},"when":{"$ref":"#/components/schemas/SegmentWhen"},"targets":{"items":{"$ref":"#/components/schemas/LeadTimeTarget"},"type":"array","maxItems":100,"minItems":1,"title":"Targets"}},"additionalProperties":false,"type":"object","required":["when","targets"],"title":"LeadTimeSegment"},"LeadTimeTarget":{"properties":{"day":{"anyOf":[{"type":"integer"},{"items":{"type":"integer"},"type":"array"}],"title":"Day"},"time":{"items":{"type":"string"},"type":"array","title":"Time"},"weight":{"type":"number","minimum":0.0,"title":"Weight"}},"additionalProperties":false,"type":"object","required":["day","time","weight"],"title":"LeadTimeTarget"},"LeadTimeTransform":{"properties":{"version":{"type":"integer","const":1,"title":"Version"},"min_notice_minutes":{"type":"integer","maximum":1440.0,"minimum":0.0,"title":"Min Notice Minutes","default":60},"closed_policy":{"type":"string","enum":["discard","first_available","next_open_day"],"title":"Closed Policy","default":"next_open_day"},"segments":{"items":{"$ref":"#/components/schemas/LeadTimeSegment"},"type":"array","maxItems":24,"minItems":1,"title":"Segments"}},"additionalProperties":false,"type":"object","required":["version","segments"],"title":"LeadTimeTransform"},"LicenseAPI":{"properties":{"license_type_id":{"type":"integer","title":"License Type Id"},"person_id":{"type":"integer","title":"Person Id"},"expires":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Expires"},"issued":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Issued"},"is_qualification":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Qualification"},"active":{"type":"boolean","title":"Active","default":true}},"type":"object","required":["license_type_id","person_id"],"title":"LicenseAPI"},"LicenseNew":{"properties":{"license_type_id":{"type":"integer","title":"License Type Id","description":"The ID of the license type associated with this license."},"license_number":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"License Number","description":"The unique number associated with this license. This field is optional."},"expires":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Expires","description":"The expiry date of the license. This field is optional."},"issued":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Issued","description":"The expiry date of the license. This field is optional."},"active":{"type":"boolean","title":"Active","description":"Whether this license is active for the person.","default":true}},"type":"object","required":["license_type_id"],"title":"LicenseNew"},"LicenseTypeNew":{"properties":{"name":{"type":"string","title":"Name","description":"The license type's name. Must be unique"},"is_qualification":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Qualification","description":"Whether this is a license or skill. Should be True for license, false for skill"},"external_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"External Id","description":"External identifier"},"state":{"anyOf":[{"$ref":"#/components/schemas/USState"},{"type":"null"}],"description":"The US state associated with the license type"},"role_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Role Ids","description":"List of role IDs that require this license type"},"person_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Person Ids","description":"List of person IDs that hold this license"},"activity_type_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Activity Type Ids","description":"List of activity type IDs that require this license type"}},"type":"object","required":["name"],"title":"LicenseTypeNew"},"LicenseTypeRead":{"properties":{"id":{"type":"integer","title":"Id","description":"The license type's primary ID which is generated when the license type is created"},"name":{"type":"string","title":"Name","description":"The license type's name. Must be unique"},"is_qualification":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Qualification","description":"Whether this is a license (True) or a skill (False)"},"state":{"anyOf":[{"$ref":"#/components/schemas/USState"},{"type":"null"}],"description":"The US state associated with the license type"}},"type":"object","required":["id","name"],"title":"LicenseTypeRead"},"LicenseTypeReponse":{"properties":{"id":{"type":"integer","title":"Id"},"name":{"type":"string","title":"Name"},"is_qualification":{"type":"boolean","title":"Is Qualification"}},"type":"object","required":["id","name","is_qualification"],"title":"LicenseTypeReponse"},"ManagerAssignmentNew":{"properties":{"person_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Person Id","description":"The ID of the manager. Inferred from the person being created or updated when omitted."},"team_id":{"type":"integer","title":"Team Id","description":"The ID of the team they manage"},"role_id":{"type":"integer","title":"Role Id","description":"The ID of the role they manage"},"has_write_access":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Has Write Access","description":"Whether the manager has write access","default":false}},"type":"object","required":["team_id","role_id"],"title":"ManagerAssignmentNew"},"MinimalHealthResponse":{"properties":{"status":{"type":"string","title":"Status","default":"pass"}},"type":"object","title":"MinimalHealthResponse"},"MutationsIn":{"properties":{"mutations":{"items":{"additionalProperties":true,"type":"object"},"type":"array","title":"Mutations","default":[]},"thread_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Thread Id"}},"type":"object","title":"MutationsIn"},"OperatingHours":{"properties":{"timezone":{"type":"string","title":"Timezone"},"weekly":{"additionalProperties":{"items":{"items":{"type":"string"},"type":"array"},"type":"array"},"propertyNames":{"enum":["mon","tue","wed","thu","fri","sat","sun"]},"type":"object","title":"Weekly"},"closed_dates":{"items":{"type":"string"},"type":"array","title":"Closed Dates"}},"additionalProperties":false,"type":"object","required":["timezone","weekly"],"title":"OperatingHours","description":"When the clinic is open. A weekday missing from `weekly` is closed."},"OrganisationMembership":{"properties":{"organisation_id":{"type":"integer","title":"Organisation Id"},"organisation_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Organisation Name"},"person_id":{"type":"integer","title":"Person Id"},"is_active":{"type":"boolean","title":"Is Active","default":false}},"type":"object","required":["organisation_id","person_id"],"title":"OrganisationMembership"},"OverrideShift":{"properties":{"id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Id"},"start":{"type":"string","format":"date-time","title":"Start"},"end":{"type":"string","format":"date-time","title":"End"},"team_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Team Id"},"role_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Role Id"},"shift_type_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Shift Type Id"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"activities":{"anyOf":[{"items":{"$ref":"#/components/schemas/RequestActivityMinimal"},"type":"array"},{"type":"null"}],"title":"Activities"}},"type":"object","required":["start","end"],"title":"OverrideShift","description":"One shift that should exist in an override's date range."},"OverrideTimeOff":{"properties":{"id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Id"},"start":{"type":"string","format":"date-time","title":"Start"},"end":{"type":"string","format":"date-time","title":"End"},"unavailability_type_id":{"type":"integer","title":"Unavailability Type Id"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"make_up_time":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Make Up Time"}},"type":"object","required":["start","end","unavailability_type_id"],"title":"OverrideTimeOff","description":"One unavailability that should exist in an override's date range."},"Patient":{"properties":{"external_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"External Id","description":"The patient's external identifier (e.g. EHR ID)"},"first_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"First Name","description":"The patient's first name"},"last_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Name","description":"The patient's last name"},"birth_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Birth Date","description":"The patient's date of birth"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email","description":"The patient's email"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone","description":"The patient's phone number"},"language":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Language","description":"The patient's language"},"address_line1":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address Line1","description":"Address line 1"},"address_line2":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address Line2","description":"Address line 2"},"address_city":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address City","description":"City"},"address_district":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address District","description":"District / county"},"address_state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address State","description":"State or region"},"address_postal_code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address Postal Code","description":"Postal / ZIP code"},"address_country":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address Country","description":"Country"},"activity_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Activity Ids","description":"List of activity IDs associated with this patient"},"client_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Client Ids","description":"List of client IDs associated with this patient"},"primary_provider_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Primary Provider Id","description":"The provider (person) ID that is this patient's primary provider"},"payor_enrollments_in":{"anyOf":[{"items":{"$ref":"#/components/schemas/PayorEnrollmentItem"},"type":"array"},{"type":"null"}],"title":"Payor Enrollments In","description":"List of payor enrollments that this patient has"},"custom_option_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Custom Option Ids","description":"List of custom option IDs associated with the patient"},"custom_fields":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Custom Fields","description":"Custom fields for this patient (reference/joined-table fields not supported)"},"id":{"type":"integer","title":"Id","description":"The patient's primary ID"},"time_created":{"type":"string","format":"date-time","title":"Time Created","description":"The time when the patient was created"},"time_updated":{"type":"string","format":"date-time","title":"Time Updated","description":"The time when the patient was last updated"},"archived":{"type":"boolean","title":"Archived","description":"Whether the patient is archived","default":false},"payor_provider_enrollments":{"anyOf":[{"items":{"$ref":"#/components/schemas/PayorProviderEnrollmentOptional"},"type":"array"},{"type":"null"}],"title":"Payor Provider Enrollments","description":"The patient's payor enrollments"},"primary_provider":{"anyOf":[{"$ref":"#/components/schemas/PersonRead"},{"type":"null"}],"description":"The patient's primary provider"}},"type":"object","required":["id","time_created","time_updated"],"title":"Patient"},"PatientMatchCriterion":{"properties":{"attribute":{"type":"string","enum":["age","language"],"title":"Attribute","description":"Patient attribute this rule checks (age | language)"},"match_type":{"type":"string","enum":["exact","range"],"title":"Match Type","description":"exact value, or (age only) a min/max range","default":"exact"},"value":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Value","description":"Match target, e.g. language 'es' or an age '40'"},"tolerance":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Tolerance","description":"For match_type=range: +/- around value (age only)"},"license_type_id":{"type":"integer","title":"License Type Id","description":"Skill or license (license_type ID) the provider must have when the patient matches"},"enforcement":{"type":"string","enum":["always","unless_no_other_providers"],"title":"Enforcement","description":"always | unless_no_other_providers","default":"always"}},"type":"object","required":["attribute","license_type_id"],"title":"PatientMatchCriterion"},"PatientNew":{"properties":{"external_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"External Id","description":"The patient's external identifier (e.g. EHR ID)"},"first_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"First Name","description":"The patient's first name"},"last_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Name","description":"The patient's last name"},"birth_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Birth Date","description":"The patient's date of birth"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email","description":"The patient's email"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone","description":"The patient's phone number"},"language":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Language","description":"The patient's language"},"address_line1":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address Line1","description":"Address line 1"},"address_line2":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address Line2","description":"Address line 2"},"address_city":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address City","description":"City"},"address_district":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address District","description":"District / county"},"address_state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address State","description":"State or region"},"address_postal_code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address Postal Code","description":"Postal / ZIP code"},"address_country":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address Country","description":"Country"},"activity_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Activity Ids","description":"List of activity IDs associated with this patient"},"client_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Client Ids","description":"List of client IDs associated with this patient"},"primary_provider_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Primary Provider Id","description":"The provider (person) ID that is this patient's primary provider"},"payor_enrollments_in":{"anyOf":[{"items":{"$ref":"#/components/schemas/PayorEnrollmentItem"},"type":"array"},{"type":"null"}],"title":"Payor Enrollments In","description":"List of payor enrollments that this patient has"},"custom_option_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Custom Option Ids","description":"List of custom option IDs associated with the patient"},"custom_fields":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Custom Fields","description":"Custom fields for this patient (reference/joined-table fields not supported)"}},"type":"object","title":"PatientNew"},"PatientOptional":{"properties":{"external_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"External Id","description":"The patient's external identifier (e.g. EHR ID)"},"first_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"First Name","description":"The patient's first name"},"last_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Name","description":"The patient's last name"},"birth_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Birth Date","description":"The patient's date of birth"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email","description":"The patient's email"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone","description":"The patient's phone number"},"language":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Language","description":"The patient's language"},"address_line1":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address Line1","description":"Address line 1"},"address_line2":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address Line2","description":"Address line 2"},"address_city":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address City","description":"City"},"address_district":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address District","description":"District / county"},"address_state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address State","description":"State or region"},"address_postal_code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address Postal Code","description":"Postal / ZIP code"},"address_country":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address Country","description":"Country"},"activity_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Activity Ids","description":"List of activity IDs associated with this patient"},"client_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Client Ids","description":"List of client IDs associated with this patient"},"primary_provider_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Primary Provider Id","description":"The provider (person) ID that is this patient's primary provider"},"payor_enrollments_in":{"anyOf":[{"items":{"$ref":"#/components/schemas/PayorEnrollmentItem"},"type":"array"},{"type":"null"}],"title":"Payor Enrollments In","description":"List of payor enrollments that this patient has"},"custom_option_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Custom Option Ids","description":"List of custom option IDs associated with the patient"},"custom_fields":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Custom Fields","description":"Custom fields for this patient (reference/joined-table fields not supported)"},"id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Id","description":"The patient's primary ID"},"time_created":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Time Created","description":"The time when the patient was created"},"time_updated":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Time Updated","description":"The time when the patient was last updated"},"archived":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Archived","description":"Whether the patient is archived","default":false},"payor_provider_enrollments":{"anyOf":[{"items":{"$ref":"#/components/schemas/PayorProviderEnrollmentOptional"},"type":"array"},{"type":"null"}],"title":"Payor Provider Enrollments","description":"The patient's payor enrollments"},"primary_provider":{"anyOf":[{"$ref":"#/components/schemas/PersonRead"},{"type":"null"}],"description":"The patient's primary provider"}},"type":"object","title":"PatientOptional"},"PatientProviderMatchMode":{"type":"string","enum":["always","if_primary_unavailable"],"title":"PatientProviderMatchMode"},"PatientsOutExternalAPI":{"properties":{"external_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"External Id","description":"The patient's external identifier (e.g. EHR ID)"},"first_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"First Name","description":"The patient's first name"},"last_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Name","description":"The patient's last name"},"birth_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Birth Date","description":"The patient's date of birth"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email","description":"The patient's email"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone","description":"The patient's phone number"},"language":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Language","description":"The patient's language"},"address_line1":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address Line1","description":"Address line 1"},"address_line2":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address Line2","description":"Address line 2"},"address_city":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address City","description":"City"},"address_district":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address District","description":"District / county"},"address_state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address State","description":"State or region"},"address_postal_code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address Postal Code","description":"Postal / ZIP code"},"address_country":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address Country","description":"Country"},"activity_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Activity Ids","description":"List of activity IDs associated with this patient"},"client_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Client Ids","description":"List of client IDs associated with this patient"},"primary_provider_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Primary Provider Id","description":"The provider (person) ID that is this patient's primary provider"},"payor_enrollments_in":{"anyOf":[{"items":{"$ref":"#/components/schemas/PayorEnrollmentItem"},"type":"array"},{"type":"null"}],"title":"Payor Enrollments In","description":"List of payor enrollments that this patient has"},"custom_option_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Custom Option Ids","description":"List of custom option IDs associated with the patient"},"custom_fields":{"anyOf":[{"additionalProperties":{"items":{"type":"string"},"type":"array"},"type":"object"},{"type":"null"}],"title":"Custom Fields"},"id":{"type":"integer","title":"Id","description":"The patient's primary ID"},"time_created":{"type":"string","format":"date-time","title":"Time Created","description":"The time when the patient was created"},"time_updated":{"type":"string","format":"date-time","title":"Time Updated","description":"The time when the patient was last updated"},"archived":{"type":"boolean","title":"Archived","description":"Whether the patient is archived","default":false},"payor_provider_enrollments":{"anyOf":[{"items":{"$ref":"#/components/schemas/PayorProviderEnrollmentOptional"},"type":"array"},{"type":"null"}],"title":"Payor Provider Enrollments","description":"The patient's payor enrollments"},"primary_provider":{"anyOf":[{"$ref":"#/components/schemas/PersonRead"},{"type":"null"}],"description":"The patient's primary provider"}},"type":"object","required":["id","time_created","time_updated"],"title":"PatientsOutExternalAPI"},"PayCycle":{"properties":{"name":{"type":"string","title":"Name","description":"The name of the pay cycle"},"frequency":{"type":"string","title":"Frequency","description":"The frequency of the pay cycle"},"start_date":{"type":"string","format":"date","title":"Start Date","description":"The start date of the pay cycle"},"pay_run_offset":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Pay Run Offset","description":"The pay run offset of the pay cycle"},"sync_days":{"items":{"type":"integer"},"type":"array","title":"Sync Days","description":"Days within the pay cycle to sync data","default":[]},"id":{"type":"integer","title":"Id","description":"The unique ID of the pay cycle"},"time_created":{"type":"string","format":"date-time","title":"Time Created","description":"The time when the pay cycle was created"},"time_updated":{"type":"string","format":"date-time","title":"Time Updated","description":"The time when the pay cycle was last updated"},"archived":{"type":"boolean","title":"Archived","description":"Whether the pay cycle is archived","default":false},"organisation_id":{"type":"integer","title":"Organisation Id","description":"The ID of the organisation associated with this pay cycle"}},"type":"object","required":["name","frequency","start_date","id","time_created","time_updated","organisation_id"],"title":"PayCycle"},"PayCycleNew":{"properties":{"name":{"type":"string","title":"Name","description":"The name of the pay cycle"},"frequency":{"type":"string","title":"Frequency","description":"The frequency of the pay cycle"},"start_date":{"type":"string","format":"date","title":"Start Date","description":"The start date of the pay cycle"},"pay_run_offset":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Pay Run Offset","description":"The pay run offset of the pay cycle"},"sync_days":{"items":{"type":"integer"},"type":"array","title":"Sync Days","description":"Days within the pay cycle to sync data","default":[]}},"type":"object","required":["name","frequency","start_date"],"title":"PayCycleNew"},"PayCycleOptional":{"properties":{"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name","description":"The name of the pay cycle"},"frequency":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Frequency","description":"The frequency of the pay cycle"},"start_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Start Date","description":"The start date of the pay cycle"},"pay_run_offset":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Pay Run Offset","description":"The pay run offset of the pay cycle"},"sync_days":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Sync Days","description":"Days within the pay cycle to sync data","default":[]},"id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Id","description":"The unique ID of the pay cycle"},"time_created":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Time Created","description":"The time when the pay cycle was created"},"time_updated":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Time Updated","description":"The time when the pay cycle was last updated"},"archived":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Archived","description":"Whether the pay cycle is archived","default":false},"organisation_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Organisation Id","description":"The ID of the organisation associated with this pay cycle"}},"type":"object","title":"PayCycleOptional"},"PayRuleAmount":{"properties":{"id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Id","description":"ID of the amount"},"value":{"type":"number","title":"Value","description":"Payment amount of the amount"},"type_":{"type":"string","title":"Type","description":"Amount type. Common values: hourly, fixed, multiplier, activity, activity_count, activity_multiplier (aka activities_multiplier), ticket."},"excluded_ticket_keywords":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Excluded Ticket Keywords","description":"Optional list of excluded ticketing keywords."},"included_ticket_keywords":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Included Ticket Keywords","description":"Optional list of included ticketing keywords."},"only_count_during_shift":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Only Count During Shift","description":"Only count tickets that started between the shift's start and end.","default":false},"integration_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Integration Ids","description":"Optional list of linked integration ids."},"activity_type_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Activity Type Ids","description":"Optional list of linked activity type ids."},"archived":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Archived","default":false}},"type":"object","title":"PayRuleAmount"},"PayRuleAmountRead":{"properties":{"id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Id","description":"ID of the amount"},"value":{"type":"number","title":"Value","description":"Payment amount of the amount"},"type_":{"type":"string","title":"Type","description":"Amount type. Common values: hourly, fixed, multiplier, activity, activity_count, activity_multiplier (aka activities_multiplier), ticket."},"excluded_ticket_keywords":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Excluded Ticket Keywords","description":"Optional list of excluded ticketing keywords."},"included_ticket_keywords":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Included Ticket Keywords","description":"Optional list of included ticketing keywords."},"only_count_during_shift":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Only Count During Shift","description":"Only count tickets that started between the shift's start and end.","default":false},"integration_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Integration Ids","description":"Optional list of linked integration ids."},"activity_type_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Activity Type Ids","description":"Optional list of linked activity type ids."},"archived":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Archived","default":false},"integrations":{"anyOf":[{"items":{"$ref":"#/components/schemas/IntegrationRead"},"type":"array"},{"type":"null"}],"title":"Integrations","description":"Optional list of linked integrations.","default":[]},"activity_types":{"anyOf":[{"items":{"$ref":"#/components/schemas/ActivityTypeRead"},"type":"array"},{"type":"null"}],"title":"Activity Types","description":"Optional list of linked integrations.","default":[]}},"type":"object","title":"PayRuleAmountRead"},"PayRuleNew":{"properties":{"name":{"type":"string","title":"Name","description":"The name of the pay rule"},"export_code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Export Code","description":"The export code used for payroll system exports"},"enabled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Enabled","description":"Whether this pay rule is enabled","default":true},"pay_rule_amounts":{"anyOf":[{"items":{"$ref":"#/components/schemas/PayRuleAmount"},"type":"array"},{"type":"null"}],"title":"Pay Rule Amounts","description":"The associated pay rule amounts"},"is_override":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Override","description":"Whether this pay rule is an override","default":false},"after_week_hours_condition":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"After Week Hours Condition","description":"Only apply rule after these hours have been worked in a week"},"on_condition":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"On Condition","description":"Only apply rule if working on these days"},"time_condition":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Time Condition","description":"Only apply rule if working on these times"},"custom_object_count_conditions":{"anyOf":[{"items":{"additionalProperties":true,"type":"object"},"type":"array"},{"type":"null"}],"title":"Custom Object Count Conditions","description":"Only apply rule if the number of custom objects meets these conditions"},"between_week_hours_condition":{"anyOf":[{"items":{"additionalProperties":true,"type":"object"},"type":"array"},{"type":"null"}],"title":"Between Week Hours Condition","description":"Only apply rule if working between these hours"},"include_shifts_without_tags":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Include Shifts Without Tags","description":"Whether to include shifts without tags in the rule","default":false},"team_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Team Ids","description":"List of teams that use this pay rule"},"role_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Role Ids","description":"List of roles that use this pay rule"},"person_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Person Ids","description":"List of people that use this pay rule"},"shift_type_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Shift Type Ids","description":"List of shift types that trigger this pay rule"},"custom_option_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Custom Option Ids","description":"List of custom options that trigger this pay rule"}},"type":"object","required":["name"],"title":"PayRuleNew"},"PayRuleRead":{"properties":{"id":{"type":"integer","title":"Id","description":"The unique ID of the pay rule"},"name":{"type":"string","title":"Name","description":"The name of the pay rule"},"export_code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Export Code","description":"The export code used for payroll system exports"},"enabled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Enabled","description":"Whether this pay rule is enabled","default":true},"pay_rule_amounts":{"anyOf":[{"items":{"$ref":"#/components/schemas/PayRuleAmountRead"},"type":"array"},{"type":"null"}],"title":"Pay Rule Amounts","description":"The associated pay rule amounts"},"is_override":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Override","description":"Whether this pay rule is an override","default":false},"after_week_hours_condition":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"After Week Hours Condition","description":"Only apply rule after these hours have been worked in a week"},"on_condition":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"On Condition","description":"Only apply rule if working on these days"},"time_condition":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Time Condition","description":"Only apply rule if working on these times"},"custom_object_count_conditions":{"anyOf":[{"items":{"additionalProperties":true,"type":"object"},"type":"array"},{"type":"null"}],"title":"Custom Object Count Conditions","description":"Only apply rule if the number of custom objects meets these conditions"},"between_week_hours_condition":{"anyOf":[{"items":{"additionalProperties":true,"type":"object"},"type":"array"},{"type":"null"}],"title":"Between Week Hours Condition","description":"Only apply rule if working between these hours"},"include_shifts_without_tags":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Include Shifts Without Tags","description":"Whether to include shifts without tags in the rule","default":false}},"type":"object","required":["id","name"],"title":"PayRuleRead"},"PayorEnrollmentAPI":{"properties":{"payor_id":{"type":"integer","title":"Payor Id","description":"The ID of the payor"},"person_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Person Id","description":"The ID of the person"},"patient_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Patient Id","description":"The ID of the patient"},"application_status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Application Status","description":"The enrollment application status"},"is_enrolled":{"type":"boolean","title":"Is Enrolled","description":"Whether the person or patient is enrolled with this payor"}},"type":"object","required":["payor_id","is_enrolled"],"title":"PayorEnrollmentAPI"},"PayorEnrollmentItem":{"properties":{"payor_id":{"type":"integer","title":"Payor Id","description":"The ID of the payor"},"application_status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Application Status","description":"The enrollment application status"},"is_enrolled":{"type":"boolean","title":"Is Enrolled","description":"Whether the person is enrolled with this payor","default":false},"effective_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Effective Date","description":"When the enrollment becomes effective"},"end_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"End Date","description":"When the enrollment ends"}},"type":"object","required":["payor_id"],"title":"PayorEnrollmentItem"},"PayorNew":{"properties":{"name":{"type":"string","title":"Name","description":"The payor's name"},"group_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Group Name","description":"The payor's group name"},"external_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"External Id","description":"The payor's external ID"},"enrolled_people":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Enrolled People","description":"Person IDs enrolled with this payor"},"covered_patients":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Covered Patients","description":"Patient IDs covered by this payor"}},"type":"object","required":["name"],"title":"PayorNew"},"PayorOptional":{"properties":{"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name","description":"The payor's name"},"group_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Group Name","description":"The payor's group name"},"external_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"External Id","description":"The payor's external ID"},"enrolled_people":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Enrolled People","description":"Person IDs enrolled with this payor"},"covered_patients":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Covered Patients","description":"Patient IDs covered by this payor"},"id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Id","description":"The payor's primary ID"},"time_created":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Time Created","description":"The time when the payor was created"},"time_updated":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Time Updated","description":"The time when the payor was last updated"},"archived":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Archived","description":"Whether the payor is archived","default":false},"organisation_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Organisation Id","description":"The organisation ID this payor belongs to"}},"type":"object","title":"PayorOptional"},"PayorProviderEnrollmentOptional":{"properties":{"id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Id","description":"The enrollment's primary ID"},"payor_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Payor Id","description":"The ID of the payor"},"patient_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Patient Id","description":"The ID of the patient"},"application_status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Application Status","description":"The enrollment application status"},"is_enrolled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Enrolled","description":"Whether the patient is enrolled with this payor"},"effective_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Effective Date","description":"When the enrollment becomes effective"},"end_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"End Date","description":"When the enrollment ends"},"time_created":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Time Created","description":"The time when the enrollment was created"},"time_updated":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Time Updated","description":"The time when the enrollment was last updated"},"archived":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Archived","description":"Whether the enrollment is archived","default":false},"organisation_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Organisation Id","description":"The organisation ID this enrollment belongs to"}},"type":"object","title":"PayorProviderEnrollmentOptional"},"PersonBalances":{"properties":{"person_id":{"type":"integer","title":"Person Id","description":"ID of the person"},"balances":{"items":{"$ref":"#/components/schemas/BalanceDetail"},"type":"array","title":"Balances","description":"Balance details for each unavailability type"}},"type":"object","required":["person_id","balances"],"title":"PersonBalances","description":"Balance information for a single person"},"PersonNew":{"properties":{"first_name":{"type":"string","title":"First Name","description":"The person's first name"},"last_name":{"type":"string","title":"Last Name","description":"The person's last name"},"email":{"type":"string","title":"Email","description":"The person's email address"},"cell":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cell","description":"The person's cell phone number"},"notifications_text":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Notifications Text","description":"Whether person opts in to SMS communications","default":true},"notifications_slack":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Notifications Slack","description":"Whether person opts in to Slack communications","default":true},"notifications_email":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Notifications Email","description":"Whether person opts in to email communications","default":true},"sms_disabled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Sms Disabled","description":"Whether person has disabled SMS communications through Twilio specifically","default":false},"enable_login":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Enable Login","description":"Enable login for this person","default":false},"employee_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Employee Id","description":"The person's employee ID"},"external_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"External Id","description":"The person's ID from an external system e.g payroll"},"wise_recipient_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Wise Recipient Id","description":"The person's Recipient ID from Wise"},"wise_recipient_currency":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Wise Recipient Currency","description":"The person's Recipient Currency from Wise"},"inactive":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Inactive","description":"Whether provider is currently active in Planbase","default":false},"archived":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Archived","description":"Whether provider is archived in Planbase","default":false},"timezone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Timezone","description":"The timezone where the person works."},"start_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Start Date","description":"The start date of the person's employment"},"employment_end_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Employment End Date","description":"The date when the person's employment ended"},"employment_type":{"anyOf":[{},{"type":"null"}],"title":"Employment Type","description":"The person's employment type, e.g. full-time or part-time"},"custom_option_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Custom Option Ids","description":"List of custom option IDs associated with the person"},"exempt":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Exempt","description":"Whether the person is exempt from overtime"},"rate":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Rate","description":"The person's pay rate"},"rate_type":{"anyOf":[{},{"type":"null"}],"title":"Rate Type","description":"The person's rate type e.g. hourly or salary"},"employment_classification":{"anyOf":[{},{"type":"null"}],"title":"Employment Classification","description":"The person's employment classification, e.g. W2, 1099"},"regular_work_hours":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Regular Work Hours","description":"The person's regular work hours as a JSON object"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes","description":"The person's notes"},"submits_availability":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Submits Availability","description":"Whether the person submits their availability"},"submits_unavailability":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Submits Unavailability","description":"Whether the person submits unavailability"},"access_level_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Level Type","description":"The person's access level","default":"staff"},"min_daily_hours":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Min Daily Hours","description":"Minimum contracted daily hours"},"max_daily_hours":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Daily Hours","description":"Maximum contracted daily hours"},"min_weekly_hours":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Min Weekly Hours","description":"Minimum contracted weekly hours"},"max_weekly_hours":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Weekly Hours","description":"Maximum contracted weekly hours"},"weekday_start":{"anyOf":[{},{"type":"null"}],"title":"Weekday Start","description":"Weekday start"},"min_monthly_hours":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Min Monthly Hours","description":"Minimum contracted monthly hours"},"max_monthly_hours":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Monthly Hours","description":"Maximum contracted monthly hours"},"weekends_month":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Weekends Month","description":"Minimum contracted weekends per month"},"flex_hours":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Flex Hours","description":"Whether the person's shifts are flexible","default":false},"pay_cycle_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Pay Cycle Id","description":"The ID of the person's pay cycle"},"pay_cycle_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Pay Cycle Name","description":"The name of the person's pay cycle"},"saved_filters":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Saved Filters","description":"The person's saved filters"},"team_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Team Ids","description":"List of team IDs the person is a member of"},"role_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Role Ids","description":"List of role IDs the person can perform"},"client_assignments_in":{"anyOf":[{"items":{"$ref":"#/components/schemas/ClientAssignmentNew"},"type":"array"},{"type":"null"}],"title":"Client Assignments In","description":"List of client assignments that this person has"},"manager_assignments_in":{"anyOf":[{"items":{"$ref":"#/components/schemas/ManagerAssignmentNew"},"type":"array"},{"type":"null"}],"title":"Manager Assignments In","description":"List of teams and roles this person manages"},"licenses_in":{"anyOf":[{"items":{"$ref":"#/components/schemas/LicenseNew"},"type":"array"},{"type":"null"}],"title":"Licenses In","description":"List of new licenses that this person has"},"payor_enrollments_in":{"anyOf":[{"items":{"$ref":"#/components/schemas/PayorEnrollmentItem"},"type":"array"},{"type":"null"}],"title":"Payor Enrollments In","description":"List of payor enrollments that this person has"},"occurrences_in":{"anyOf":[{"items":{"$ref":"#/components/schemas/ActionOptional"},"type":"array"},{"type":"null"}],"title":"Occurrences In","description":"List of occurrences (notable events or incidents) for this person"},"custom_fields":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Custom Fields","description":"List of custom fields that this person has"},"unavailability_allowances_in":{"anyOf":[{"items":{"$ref":"#/components/schemas/UnavailabilityAllowanceNew"},"type":"array"},{"type":"null"}],"title":"Unavailability Allowances In","description":"List of unavailability allowances that this person has"},"unavailability_balances_in":{"anyOf":[{"items":{"$ref":"#/components/schemas/UnavailabilityBalanceNew"},"type":"array"},{"type":"null"}],"title":"Unavailability Balances In","description":"List of unavailability balances that this person has"}},"type":"object","required":["first_name","last_name","email"],"title":"PersonNew"},"PersonOptional":{"properties":{"id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Id","description":"The unique ID of the person"},"first_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"First Name","description":"The person's first name"},"last_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Name","description":"The person's last name"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email","description":"The person's email address"},"cell":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cell","description":"The person's cell phone number"},"notifications_text":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Notifications Text","description":"Whether person opts in to SMS communications","default":true},"notifications_slack":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Notifications Slack","description":"Whether person opts in to Slack communications","default":true},"notifications_email":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Notifications Email","description":"Whether person opts in to email communications","default":true},"sms_disabled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Sms Disabled","description":"Whether person has disabled SMS communications through Twilio specifically","default":false},"enable_login":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Enable Login","description":"Enable login for this person","default":false},"employee_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Employee Id","description":"The person's employee ID"},"external_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"External Id","description":"The person's ID from an external system e.g payroll"},"wise_recipient_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Wise Recipient Id","description":"The person's Recipient ID from Wise"},"wise_recipient_currency":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Wise Recipient Currency","description":"The person's Recipient Currency from Wise"},"inactive":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Inactive","description":"Whether provider is currently active in Planbase","default":false},"timezone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Timezone","description":"The timezone where the person works."},"start_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Start Date","description":"The start date of the person's employment"},"employment_end_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Employment End Date","description":"The date when the person's employment ended"},"employment_type":{"anyOf":[{},{"type":"null"}],"title":"Employment Type","description":"The person's employment type, e.g. full-time or part-time"},"employment_classification":{"anyOf":[{},{"type":"null"}],"title":"Employment Classification","description":"The person's employment classification, e.g. W2, 1099"},"exempt":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Exempt","description":"Whether the person is exempt from overtime"},"rate":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Rate","description":"The person's pay rate"},"rate_type":{"anyOf":[{},{"type":"null"}],"title":"Rate Type","description":"The person's rate type e.g. hourly or salary"},"regular_work_hours":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Regular Work Hours","description":"The person's regular work hours as a JSON object"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes","description":"The person's notes"},"submits_availability":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Submits Availability","description":"Whether the person submits their availability"},"submits_unavailability":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Submits Unavailability","description":"Whether the person submits unavailability"},"access_level_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Level Type","description":"The person's access level","default":"staff"},"min_daily_hours":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Min Daily Hours","description":"Minimum contracted daily hours"},"max_daily_hours":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Daily Hours","description":"Maximum contracted daily hours"},"min_weekly_hours":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Min Weekly Hours","description":"Minimum contracted weekly hours"},"max_weekly_hours":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Weekly Hours","description":"Maximum contracted weekly hours"},"weekday_start":{"anyOf":[{},{"type":"null"}],"title":"Weekday Start","description":"Weekday start"},"min_monthly_hours":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Min Monthly Hours","description":"Minimum contracted monthly hours"},"max_monthly_hours":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Monthly Hours","description":"Maximum contracted monthly hours"},"weekends_month":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Weekends Month","description":"Minimum contracted weekends per month"},"saved_filters":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Saved Filters","description":"The person's saved filters"},"pay_cycle_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Pay Cycle Id","description":"The ID of the person's pay cycle"},"pay_cycle_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Pay Cycle Name","description":"The name of the person's pay cycle"},"flex_hours":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Flex Hours","description":"Whether the person's shifts are flexible","default":false},"organisation_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Organisation Id","description":"The ID of the organisation the person belongs to"},"time_created":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Time Created","description":"The time when the person was created"},"time_updated":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Time Updated","description":"The time when the person was last updated"},"archived":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Archived","default":false},"auth_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Auth Id","description":"The person's authentication ID"},"google_access_token":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Google Access Token","description":"Hashed access token for GCal integration"},"google_access_token_expires":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Google Access Token Expires","description":"When access token for GCal integration expires"},"google_refresh_token":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Google Refresh Token","description":"Hashed refresh token for GCal integration"},"google_connected_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Google Connected At","description":"When synced with Google"},"gcal_watch_channel_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Gcal Watch Channel Id","description":"Google Calendar watch channel ID for the gcal pull sync"},"gcal_watch_resource_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Gcal Watch Resource Id","description":"Google Calendar watch resource ID for the gcal pull sync"},"gcal_watch_expiration":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Gcal Watch Expiration","description":"When the Google Calendar watch channel expires"},"gcal_sync_token":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Gcal Sync Token","description":"Google Calendar incremental sync token for the gcal pull sync"},"slack_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Slack Id","description":"User ID in Slack"},"assistant_thread_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Assistant Thread Id","description":"Thread ID in OpenAI"},"team_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Team Ids","description":"List of team IDs the person is a member of"},"role_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Role Ids","description":"List of role IDs the person can perform"},"custom_fields":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Custom Fields","description":"List of custom fields that this person has"},"client_assignments_in":{"anyOf":[{"items":{"$ref":"#/components/schemas/ClientAssignmentNew"},"type":"array"},{"type":"null"}],"title":"Client Assignments In","description":"List of client assignments that this person has"},"manager_assignments_in":{"anyOf":[{"items":{"$ref":"#/components/schemas/ManagerAssignmentNew"},"type":"array"},{"type":"null"}],"title":"Manager Assignments In","description":"List of teams and roles this person manages"},"licenses_in":{"anyOf":[{"items":{"$ref":"#/components/schemas/LicenseNew"},"type":"array"},{"type":"null"}],"title":"Licenses In","description":"List of new licenses that this person has"},"payor_enrollments_in":{"anyOf":[{"items":{"$ref":"#/components/schemas/PayorEnrollmentItem"},"type":"array"},{"type":"null"}],"title":"Payor Enrollments In","description":"List of payor enrollments that this person has"},"occurrences_in":{"anyOf":[{"items":{"$ref":"#/components/schemas/ActionOptional"},"type":"array"},{"type":"null"}],"title":"Occurrences In","description":"List of occurrences (notable events or incidents) for this person"},"unavailability_allowances_in":{"anyOf":[{"items":{"$ref":"#/components/schemas/UnavailabilityAllowanceNew"},"type":"array"},{"type":"null"}],"title":"Unavailability Allowances In","description":"List of unavailability allowances that this person has"},"unavailability_balances_in":{"anyOf":[{"items":{"$ref":"#/components/schemas/UnavailabilityBalanceNew"},"type":"array"},{"type":"null"}],"title":"Unavailability Balances In","description":"List of unavailability balances that this person has"},"status":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Status","description":"Status information with multiple possible keys"}},"type":"object","title":"PersonOptional"},"PersonPhiStatusAPI":{"properties":{"id":{"type":"integer","title":"Id"},"first_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"First Name"},"last_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Last Name"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email"}},"type":"object","required":["id"],"title":"PersonPhiStatusAPI"},"PersonRead":{"properties":{"id":{"type":"integer","title":"Id","description":"The unique ID of the person"},"first_name":{"type":"string","title":"First Name","description":"The person's first name"},"last_name":{"type":"string","title":"Last Name","description":"The person's last name"},"email":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Email","description":"The person's email address"},"cell":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cell","description":"The person's cell phone number"},"notifications_text":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Notifications Text","description":"Whether person opts in to SMS communications","default":true},"notifications_slack":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Notifications Slack","description":"Whether person opts in to Slack communications","default":true},"notifications_email":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Notifications Email","description":"Whether person opts in to email communications","default":true},"sms_disabled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Sms Disabled","description":"Whether person has disabled SMS communications through Twilio specifically","default":false},"enable_login":{"type":"boolean","title":"Enable Login","description":"Enable login for this person","default":false},"employee_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Employee Id","description":"The person's employee ID"},"wise_recipient_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Wise Recipient Id","description":"The person's Recipient ID from Wise"},"wise_recipient_currency":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Wise Recipient Currency","description":"The person's Recipient Currency from Wise"},"external_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"External Id","description":"The person's ID from an external system e.g payroll"},"inactive":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Inactive","description":"Whether provider is currently active in Planbase","default":false},"timezone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Timezone","description":"The timezone where the person works."},"start_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Start Date","description":"The start date of the person's employment"},"last_archived_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Archived At","description":"The timestamp when the person was archived"},"employment_end_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Employment End Date","description":"The date when the person's employment ended"},"employment_type":{"anyOf":[{},{"type":"null"}],"title":"Employment Type","description":"The person's employment type, e.g. full-time or part-time"},"custom_option_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Custom Option Ids","description":"List of custom option IDs associated with the person"},"exempt":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Exempt","description":"Whether the person is exempt from overtime"},"rate":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Rate","description":"The person's pay rate"},"rate_type":{"anyOf":[{},{"type":"null"}],"title":"Rate Type","description":"The person's rate type e.g. hourly or salary"},"regular_work_hours":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Regular Work Hours","description":"The person's regular work hours as a JSON object"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes","description":"The person's notes"},"submits_availability":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Submits Availability","description":"Whether the person submits their availability"},"submits_unavailability":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Submits Unavailability","description":"Whether the person submits unavailability"},"saved_filters":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Saved Filters","description":"The person's saved filters"},"pay_cycle_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Pay Cycle Id","description":"The ID of the person's pay cycle"},"pay_cycle_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Pay Cycle Name","description":"The name of the person's pay cycle"},"min_daily_hours":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Min Daily Hours","description":"Minimum contracted daily hours"},"max_daily_hours":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Daily Hours","description":"Maximum contracted daily hours"},"min_weekly_hours":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Min Weekly Hours","description":"Minimum contracted weekly hours"},"max_weekly_hours":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Weekly Hours","description":"Maximum contracted weekly hours"},"min_monthly_hours":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Min Monthly Hours","description":"Minimum contracted monthly hours"},"max_monthly_hours":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Monthly Hours","description":"Maximum contracted monthly hours"},"weekends_month":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Weekends Month","description":"Minimum contracted weekend days per month"},"flex_hours":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Flex Hours","description":"Whether the person's shifts are flexible","default":false},"access_level_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Level Name","description":"The person's access level"},"access_level_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Access Level Id","description":"The ID of the person's access level"},"archived":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Archived","description":"Whether the person is archived","default":false},"organisation_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Organisation Id","description":"The ID of the organisation the person belongs to"},"weekday_start":{"anyOf":[{},{"type":"null"}],"title":"Weekday Start","description":"The first day of the person's work week"},"avatar_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Avatar Url","description":"URL of the person's avatar image"},"clockin_calls":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Clockin Calls","description":"Whether the person gets reminder calls to clock in","default":false},"clockin_required":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Clockin Required","description":"Whether the person is required to clock in","default":false},"employment_classification":{"anyOf":[{},{"type":"null"}],"title":"Employment Classification","description":"The person's employment classification, e.g. W2 or 1099"},"time_created":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Time Created","description":"The time (UTC) when the person was created"},"time_updated":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Time Updated","description":"The time (UTC) when the person was last updated"}},"type":"object","required":["id","first_name","last_name"],"title":"PersonRead"},"PersonResponse":{"properties":{"id":{"type":"integer","title":"Id"},"first_name":{"type":"string","title":"First Name"},"last_name":{"type":"string","title":"Last Name"}},"type":"object","required":["id","first_name","last_name"],"title":"PersonResponse"},"PersonUpdateAPI":{"properties":{"first_name":{"type":"string","title":"First Name","description":"The person's first name"},"last_name":{"type":"string","title":"Last Name","description":"The person's last name"},"email":{"type":"string","title":"Email","description":"The person's email address"},"cell":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Cell","description":"The person's cell phone number"},"notifications_text":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Notifications Text","description":"Whether person opts in to SMS communications","default":true},"notifications_slack":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Notifications Slack","description":"Whether person opts in to Slack communications","default":true},"notifications_email":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Notifications Email","description":"Whether person opts in to email communications","default":true},"sms_disabled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Sms Disabled","description":"Whether person has disabled SMS communications through Twilio specifically","default":false},"enable_login":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Enable Login","description":"Enable login for this person","default":false},"employee_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Employee Id","description":"The person's employee ID"},"external_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"External Id","description":"The person's ID from an external system e.g payroll"},"wise_recipient_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Wise Recipient Id","description":"The person's Recipient ID from Wise"},"wise_recipient_currency":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Wise Recipient Currency","description":"The person's Recipient Currency from Wise"},"inactive":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Inactive","description":"Whether provider is currently active in Planbase","default":false},"archived":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Archived","description":"Whether provider is archived in Planbase","default":false},"timezone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Timezone","description":"The timezone where the person works."},"start_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Start Date","description":"The start date of the person's employment"},"employment_end_date":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Employment End Date","description":"The date when the person's employment ended"},"employment_type":{"anyOf":[{},{"type":"null"}],"title":"Employment Type","description":"The person's employment type, e.g. full-time or part-time"},"custom_option_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Custom Option Ids","description":"List of custom option IDs associated with the person"},"exempt":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Exempt","description":"Whether the person is exempt from overtime"},"rate":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Rate","description":"The person's pay rate"},"rate_type":{"anyOf":[{},{"type":"null"}],"title":"Rate Type","description":"The person's rate type e.g. hourly or salary"},"employment_classification":{"anyOf":[{},{"type":"null"}],"title":"Employment Classification","description":"The person's employment classification, e.g. W2, 1099"},"regular_work_hours":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Regular Work Hours","description":"The person's regular work hours as a JSON object"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes","description":"The person's notes"},"submits_availability":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Submits Availability","description":"Whether the person submits their availability"},"submits_unavailability":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Submits Unavailability","description":"Whether the person submits unavailability"},"access_level_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Level Type","description":"The person's access level","default":"staff"},"min_daily_hours":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Min Daily Hours","description":"Minimum contracted daily hours"},"max_daily_hours":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Daily Hours","description":"Maximum contracted daily hours"},"min_weekly_hours":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Min Weekly Hours","description":"Minimum contracted weekly hours"},"max_weekly_hours":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Weekly Hours","description":"Maximum contracted weekly hours"},"weekday_start":{"anyOf":[{},{"type":"null"}],"title":"Weekday Start","description":"Weekday start"},"min_monthly_hours":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Min Monthly Hours","description":"Minimum contracted monthly hours"},"max_monthly_hours":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Max Monthly Hours","description":"Maximum contracted monthly hours"},"weekends_month":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Weekends Month","description":"Minimum contracted weekends per month"},"flex_hours":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Flex Hours","description":"Whether the person's shifts are flexible","default":false},"pay_cycle_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Pay Cycle Id","description":"The ID of the person's pay cycle"},"pay_cycle_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Pay Cycle Name","description":"The name of the person's pay cycle"},"saved_filters":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Saved Filters","description":"The person's saved filters"},"team_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Team Ids","description":"List of team IDs the person is a member of"},"role_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Role Ids","description":"List of role IDs the person can perform"},"client_assignments_in":{"anyOf":[{"items":{"$ref":"#/components/schemas/ClientAssignmentNew"},"type":"array"},{"type":"null"}],"title":"Client Assignments In","description":"List of client assignments that this person has"},"manager_assignments_in":{"anyOf":[{"items":{"$ref":"#/components/schemas/ManagerAssignmentNew"},"type":"array"},{"type":"null"}],"title":"Manager Assignments In","description":"List of teams and roles this person manages"},"licenses_in":{"anyOf":[{"items":{"$ref":"#/components/schemas/LicenseNew"},"type":"array"},{"type":"null"}],"title":"Licenses In","description":"List of new licenses that this person has"},"payor_enrollments_in":{"anyOf":[{"items":{"$ref":"#/components/schemas/PayorEnrollmentItem"},"type":"array"},{"type":"null"}],"title":"Payor Enrollments In","description":"List of payor enrollments that this person has"},"occurrences_in":{"anyOf":[{"items":{"$ref":"#/components/schemas/ActionOptional"},"type":"array"},{"type":"null"}],"title":"Occurrences In","description":"List of occurrences (notable events or incidents) for this person"},"custom_fields":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Custom Fields","description":"List of custom fields that this person has"},"unavailability_allowances_in":{"anyOf":[{"items":{"$ref":"#/components/schemas/UnavailabilityAllowanceNew"},"type":"array"},{"type":"null"}],"title":"Unavailability Allowances In","description":"List of unavailability allowances that this person has"},"unavailability_balances_in":{"anyOf":[{"items":{"$ref":"#/components/schemas/UnavailabilityBalanceNew"},"type":"array"},{"type":"null"}],"title":"Unavailability Balances In","description":"List of unavailability balances that this person has"},"team_propogation":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Team Propogation"},"role_propogation":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Role Propogation"}},"type":"object","required":["first_name","last_name","email"],"title":"PersonUpdateAPI"},"PredictedTicketCountsRequest":{"properties":{"integration_ids":{"items":{"type":"integer"},"type":"array","title":"Integration Ids","description":"List of integration IDs to include"},"start":{"type":"string","format":"date-time","title":"Start","description":"Start datetime for data (ISO format)"},"end":{"type":"string","format":"date-time","title":"End","description":"End datetime for data (ISO format)"},"custom_field_filters":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Custom Field Filters","description":"Optional filters for custom fields"},"model":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Model","description":"Model to use for predictions","default":"chronos-2"},"training_range_start":{"type":"string","format":"date-time","title":"Training Range Start","description":"Start datetime for training data (ISO format). Training data ends at 'start' parameter."}},"type":"object","required":["integration_ids","start","end","training_range_start"],"title":"PredictedTicketCountsRequest"},"Prompt":{"properties":{"title":{"type":"string","title":"Title","description":"Short label shown in autocomplete"},"content":{"type":"string","title":"Content","description":"Prompt text content"},"exec_content":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Exec Content","description":"Python code to execute directly, bypassing the LLM"},"execute_directly":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Execute Directly","description":"If true, exec_content is run verbatim; if false, it is only offered as example code in the prompt","default":false},"is_visible_to_org":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Visible To Org","description":"If true, prompt can be seen org-wide","default":false},"id":{"type":"integer","title":"Id","description":"Unique identifier for the prompt"},"time_created":{"type":"string","format":"date-time","title":"Time Created","description":"Timestamp of when the prompt was created"},"time_updated":{"type":"string","format":"date-time","title":"Time Updated","description":"Timestamp of when the prompt was last updated"},"person_id":{"type":"integer","title":"Person Id","description":"ID of the authoring person"},"organisation_id":{"type":"integer","title":"Organisation Id","description":"ID of the organization this prompt belongs to"},"archived":{"type":"boolean","title":"Archived","description":"Whether this prompt is archived"}},"type":"object","required":["title","content","id","time_created","time_updated","person_id","organisation_id","archived"],"title":"Prompt"},"PromptNew":{"properties":{"title":{"type":"string","title":"Title","description":"Short label shown in autocomplete"},"content":{"type":"string","title":"Content","description":"Prompt text content"},"exec_content":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Exec Content","description":"Python code to execute directly, bypassing the LLM"},"execute_directly":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Execute Directly","description":"If true, exec_content is run verbatim; if false, it is only offered as example code in the prompt","default":false},"is_visible_to_org":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Visible To Org","description":"If true, prompt can be seen org-wide","default":false}},"type":"object","required":["title","content"],"title":"PromptNew"},"PromptOptional":{"properties":{"title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Title","description":"Short label shown in autocomplete"},"content":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Content","description":"Prompt text content"},"exec_content":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Exec Content","description":"Python code to execute directly, bypassing the LLM"},"execute_directly":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Execute Directly","description":"If true, exec_content is run verbatim; if false, it is only offered as example code in the prompt","default":false},"is_visible_to_org":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Visible To Org","description":"If true, prompt can be seen org-wide","default":false},"id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Id","description":"Unique identifier for the prompt"},"time_created":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Time Created","description":"Timestamp of when the prompt was created"},"time_updated":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Time Updated","description":"Timestamp of when the prompt was last updated"},"person_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Person Id","description":"ID of the authoring person"},"organisation_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Organisation Id","description":"ID of the organization this prompt belongs to"},"archived":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Archived","description":"Whether this prompt is archived"}},"type":"object","title":"PromptOptional"},"RecurrenceNew":{"properties":{"id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Id","description":"The ID of the recurrence"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name","description":"Human-readable name for the recurrence"},"dtstart":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Dtstart","description":"Start date of the recurrence (RFC 5545 DTSTART)"},"freq":{"type":"string","title":"Freq","description":"Frequency: DAILY, WEEKLY, MONTHLY, etc."},"interval":{"type":"integer","title":"Interval","description":"How often the rule repeats","default":1},"count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Count","description":"Number of occurrences"},"until":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Until","description":"End date"},"tzid":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tzid","description":"Timezone identifier"},"byday":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Byday","description":"Days of week (MO, TU, WE, etc.)"},"bymonthday":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Bymonthday","description":"Days of month"},"bymonth":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Bymonth","description":"Months"},"exdate":{"anyOf":[{"items":{"type":"string","format":"date"},"type":"array"},{"type":"null"}],"title":"Exdate","description":"Per-date shifts to exclude"},"activities_exdate":{"anyOf":[{"additionalProperties":{"additionalProperties":{"items":{"additionalProperties":true,"type":"object"},"type":"array"},"type":"object"},"type":"object"},{"type":"null"}],"title":"Activities Exdate","description":"Per-date activities to exclude: {\"YYYY-MM-DD\": {\"activities\": [{\"uuid\": \"...\", \"activity_type_id\": 1}]}}"},"pattern_overrides":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Pattern Overrides","description":"Monthly pattern overrides: {week_of_month: {DAY: <entry|[entry,...]>}} where entry = {start_time, end_time, activities}; a list lets a single weekday produce multiple shifts"},"assignments":{"anyOf":[{"items":{"$ref":"#/components/schemas/RecurrencePersonRange"},"type":"array"},{"type":"null"}],"title":"Assignments","description":"Per-person date windows for which this recurrence applies"},"removed_person_range_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Removed Person Range Ids","description":"(Update only) IDs of RecurrencePersonRange rows to remove from this recurrence; their generated shifts are also deleted"},"reference_shift_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Reference Shift Id","description":"The ID of the shift that this recurrence is derived from"},"original_recurrence_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Original Recurrence Id","description":"The ID of the original recurrence that this recurrence is derived from"},"reference_activity_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Reference Activity Id","description":"The ID of the activity that this recurrence is derived from"},"next_recurrence_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Next Recurrence Id","description":"When this recurrence is split, points to the next recurrence in the split chain"}},"type":"object","required":["freq"],"title":"RecurrenceNew"},"RecurrenceOptional":{"properties":{"id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Id","description":"The unique ID of the recurrence"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name","description":"Human-readable name for the recurrence"},"dtstart":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Dtstart","description":"Start date of the recurrence (RFC 5545 DTSTART)"},"freq":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Freq","description":"Frequency: DAILY, WEEKLY, MONTHLY, etc."},"interval":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Interval","description":"How often the rule repeats","default":1},"count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Count","description":"Number of occurrences"},"until":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Until","description":"End date"},"tzid":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tzid","description":"Timezone identifier"},"byday":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Byday","description":"Days of week (MO, TU, WE, etc.)"},"bymonthday":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Bymonthday","description":"Days of month"},"bymonth":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Bymonth","description":"Months"},"exdate":{"anyOf":[{"items":{"type":"string","format":"date"},"type":"array"},{"type":"null"}],"title":"Exdate","description":"Per-date shifts to exclude"},"activities_exdate":{"anyOf":[{"additionalProperties":{"additionalProperties":{"items":{"additionalProperties":true,"type":"object"},"type":"array"},"type":"object"},"type":"object"},{"type":"null"}],"title":"Activities Exdate","description":"Per-date activities to exclude: {\"YYYY-MM-DD\": {\"activities\": [{\"uuid\": \"...\", \"activity_type_id\": 1}]}}"},"pattern_overrides":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Pattern Overrides","description":"Monthly pattern overrides: {week_of_month: {DAY: <entry|[entry,...]>}} where entry = {start_time, end_time, activities}; a list lets a single weekday produce multiple shifts"},"assignments":{"anyOf":[{"items":{"$ref":"#/components/schemas/RecurrencePersonRange"},"type":"array"},{"type":"null"}],"title":"Assignments","description":"Per-person date windows for which this recurrence applies"},"removed_person_range_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Removed Person Range Ids","description":"(Update only) IDs of RecurrencePersonRange rows to remove from this recurrence; their generated shifts are also deleted"},"reference_shift_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Reference Shift Id","description":"The ID of the shift that this recurrence is derived from"},"original_recurrence_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Original Recurrence Id","description":"The ID of the original recurrence that this recurrence is derived from"},"reference_activity_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Reference Activity Id","description":"The ID of the activity that this recurrence is derived from"},"next_recurrence_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Next Recurrence Id","description":"When this recurrence is split, points to the next recurrence in the split chain"},"time_created":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Time Created","description":"The time when the recurrence was created"},"time_updated":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Time Updated","description":"The time when the recurrence was last updated"},"archived":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Archived","description":"Whether the recurrence is archived","default":false},"organisation_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Organisation Id","description":"The ID of the organisation associated with this recurrence"}},"type":"object","title":"RecurrenceOptional"},"RecurrenceOutAPI":{"properties":{"id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Id","description":"The ID of the recurrence"},"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name","description":"Human-readable name for the recurrence"},"dtstart":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Dtstart","description":"Start date of the recurrence (RFC 5545 DTSTART)"},"freq":{"type":"string","title":"Freq","description":"Frequency: DAILY, WEEKLY, MONTHLY, etc."},"interval":{"type":"integer","title":"Interval","description":"How often the rule repeats","default":1},"count":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Count","description":"Number of occurrences"},"until":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Until","description":"End date"},"tzid":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Tzid","description":"Timezone identifier"},"byday":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Byday","description":"Days of week (MO, TU, WE, etc.)"},"bymonthday":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Bymonthday","description":"Days of month"},"bymonth":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Bymonth","description":"Months"},"exdate":{"anyOf":[{"items":{"type":"string","format":"date"},"type":"array"},{"type":"null"}],"title":"Exdate","description":"Per-date shifts to exclude"},"activities_exdate":{"anyOf":[{"additionalProperties":{"additionalProperties":{"items":{"additionalProperties":true,"type":"object"},"type":"array"},"type":"object"},"type":"object"},{"type":"null"}],"title":"Activities Exdate","description":"Per-date activities to exclude: {\"YYYY-MM-DD\": {\"activities\": [{\"uuid\": \"...\", \"activity_type_id\": 1}]}}"},"pattern_overrides":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Pattern Overrides","description":"Monthly pattern overrides: {week_of_month: {DAY: <entry|[entry,...]>}} where entry = {start_time, end_time, activities}; a list lets a single weekday produce multiple shifts"},"assignments":{"anyOf":[{"items":{"$ref":"#/components/schemas/RecurrencePersonRange"},"type":"array"},{"type":"null"}],"title":"Assignments","description":"Per-person date windows for which this recurrence applies"},"removed_person_range_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Removed Person Range Ids","description":"(Update only) IDs of RecurrencePersonRange rows to remove from this recurrence; their generated shifts are also deleted"},"reference_shift_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Reference Shift Id","description":"The ID of the shift that this recurrence is derived from"},"original_recurrence_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Original Recurrence Id","description":"The ID of the original recurrence that this recurrence is derived from"},"reference_activity_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Reference Activity Id","description":"The ID of the activity that this recurrence is derived from"},"next_recurrence_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Next Recurrence Id","description":"When this recurrence is split, points to the next recurrence in the split chain"},"validations":{"anyOf":[{"items":{},"type":"array"},{"type":"null"}],"title":"Validations","description":"Validations for the recurrence"},"reference_activity":{"anyOf":[{"$ref":"#/components/schemas/ActivityOptional"},{"type":"null"}],"description":"Reference activity"},"reference_shift":{"anyOf":[{"$ref":"#/components/schemas/ShiftOptional"},{"type":"null"}],"description":"Reference shift"},"person_ranges":{"anyOf":[{"items":{"$ref":"#/components/schemas/RecurrencePersonRange"},"type":"array"},{"type":"null"}],"title":"Person Ranges","description":"Per-person date windows for which this recurrence applies"},"begin":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Begin","readOnly":true}},"type":"object","required":["freq","begin"],"title":"RecurrenceOutAPI"},"RecurrencePersonRange":{"properties":{"id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Id","description":"The ID of the range"},"recurrence_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Recurrence Id","description":"The recurrence this range belongs to"},"person_id":{"type":"integer","title":"Person Id","description":"The person this range applies to"},"from_date":{"type":"string","format":"date","title":"From Date","description":"Start date (inclusive)"},"to_date":{"type":"string","format":"date","title":"To Date","description":"End date (inclusive)"},"team_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Team Id","description":"Team ID for this person range"},"role_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Role Id","description":"Role ID for this person range"},"exdate":{"anyOf":[{"items":{"type":"string","format":"date"},"type":"array"},{"type":"null"}],"title":"Exdate","description":"Per-date shifts to exclude"},"holiday_exdates":{"anyOf":[{"items":{"type":"string","format":"date"},"type":"array"},{"type":"null"}],"title":"Holiday Exdates","description":"Per-date shifts excluded because of holidays"},"exdays":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Exdays","description":"Weekdays to exclude (MO, TU, WE, TH, FR, SA, SU)"},"activities_exdate":{"anyOf":[{"additionalProperties":{"additionalProperties":{"items":{"additionalProperties":true,"type":"object"},"type":"array"},"type":"object"},"type":"object"},{"type":"null"}],"title":"Activities Exdate","description":"Per-date activities to exclude: {\"YYYY-MM-DD\": {\"activities\": [{\"uuid\": \"...\", \"activity_type_id\": 1}]}}"}},"type":"object","required":["person_id","from_date","to_date"],"title":"RecurrencePersonRange"},"RefreshRequest":{"properties":{"refresh_token":{"type":"string","title":"Refresh Token"}},"type":"object","required":["refresh_token"],"title":"RefreshRequest"},"RequestActivityMinimal":{"properties":{"id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Id"},"activity_type_id":{"type":"integer","title":"Activity Type Id"},"start":{"type":"string","format":"date-time","title":"Start"},"end":{"type":"string","format":"date-time","title":"End"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"}},"type":"object","required":["activity_type_id","start","end"],"title":"RequestActivityMinimal"},"RequestCancelIn":{"properties":{"type":{"type":"string","enum":["availability","modify_shift","cancel_shift","time_off","modify_time_off","cancel_time_off","claim_shift","release_shift"],"title":"Type"},"resource_id":{"type":"integer","title":"Resource Id","description":"resource_id from GET /api/v1/requests"}},"type":"object","required":["type","resource_id"],"title":"RequestCancelIn","description":"Withdraw one pending request. resource_id and type are the pair from\nGET /api/v1/requests; a resource_id without a pending request of exactly that type\nis rejected."},"RequestCancelsIn":{"properties":{"items":{"items":{"$ref":"#/components/schemas/RequestCancelIn"},"type":"array","minItems":1,"title":"Items"}},"type":"object","required":["items"],"title":"RequestCancelsIn"},"RequestDecisionIn":{"properties":{"type":{"type":"string","enum":["availability","modify_shift","cancel_shift","time_off","modify_time_off","cancel_time_off","claim_shift","release_shift"],"title":"Type"},"resource_id":{"type":"integer","title":"Resource Id","description":"resource_id from GET /api/v1/requests"},"decision":{"type":"string","enum":["approved","denied"],"title":"Decision","description":"approved or denied."},"flags":{"additionalProperties":{"type":"boolean"},"type":"object","title":"Flags","description":"Named side effects to apply with this decision. Currently supported: close_shift_offer (claim_shift approve only) - also closes the open shift after accepting this offer."}},"type":"object","required":["type","resource_id","decision"],"title":"RequestDecisionIn","description":"Approve or deny one pending request. resource_id and type are the pair from\nGET /api/v1/requests; a resource_id without a pending request of exactly that type\nis rejected."},"RequestDecisionsIn":{"properties":{"items":{"items":{"$ref":"#/components/schemas/RequestDecisionIn"},"type":"array","minItems":1,"title":"Items"}},"type":"object","required":["items"],"title":"RequestDecisionsIn"},"RequestEntryMinimal":{"properties":{"id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Id"},"start":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Start"},"end":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"End"},"person_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Person Id"},"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"team_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Team Id"},"role_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Role Id"},"shift_type_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Shift Type Id"},"activities":{"anyOf":[{"items":{"$ref":"#/components/schemas/RequestActivityMinimal"},"type":"array"},{"type":"null"}],"title":"Activities"},"unavailability_type_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Unavailability Type Id"},"exported":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Exported"},"make_up_time":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Make Up Time"}},"type":"object","title":"RequestEntryMinimal"},"RequestIn":{"properties":{"type":{"type":"string","enum":["availability","modify_shift","cancel_shift","time_off","modify_time_off","cancel_time_off","claim_shift","release_shift"],"title":"Type"},"resource_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Resource Id","description":"Deprecated. Still kept until the mobile app is updated.","deprecated":true},"person_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Person Id","description":"Person the request is for. Required when the request does not name an existing row; otherwise read off that row."},"start":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Start","description":"Label time; derived from the resource or first requested_entry when omitted"},"requested_entries":{"items":{"$ref":"#/components/schemas/RequestEntryMinimal"},"type":"array","title":"Requested Entries","description":"What this request is asking to receive. Only used on create.\n- availability: the new shift.\n- modify_shift: the proposed replacement shift.\n- cancel_shift: empty. Nothing is being asked for.\n- claim_shift: the shift being claimed. id is required. A vacant shift, or one with a pending release.\n- release_shift: empty for a give-away. For a trade, up to 5 slots the person would accept. A slot is one slice. The same shift can fill more than one slot. start and end are that slice; omit them to ask for the whole shift.\n- time_off: the new windows. Each one needs unavailability_type_id.\n- modify_time_off: the proposed replacement. May include shift entries.\n- cancel_time_off: empty. Nothing is being asked for."},"offered_entries":{"items":{"$ref":"#/components/schemas/RequestEntryMinimal"},"type":"array","title":"Offered Entries","description":"What this request is giving up, named by id. Only used on create.\n- availability: empty. Nothing is being given up.\n- modify_shift: exactly one entry. id is the existing shift. start and end are optional.\n- cancel_shift: exactly one entry. id is the existing shift. start and end are optional.\n- claim_shift: empty for a plain claim. For a trade, the claimant's own shift. It must be one of that release's trade-in picks and must belong to the claimant. When that shift was named once, start and end are optional. When it was named with more than one window, start and end must match the window being accepted.\n- release_shift: exactly one entry. id is the shift. start and end are the window inside that shift. Send the shift's own times to release all of it. A trade must offer the whole shift.\n- time_off: empty. Nothing is being given up.\n- modify_time_off: exactly one entry. id is the existing unavailability. start and end are optional.\n- cancel_time_off: exactly one entry. id is the existing unavailability. start and end are optional."},"decision":{"type":"string","enum":["pending","approved","denied","cancelled"],"title":"Decision","description":"pending submits as a pending request; approved submits as approved (validation may still drop it to pending). denied/cancelled are for internal use by POST /decide and /cancel - do not send them here.","default":"approved"},"flags":{"additionalProperties":{"type":"boolean"},"type":"object","title":"Flags","description":"Reserved for request-type-specific side effects; unused on create."},"value":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Value","description":"Occurrence/balance override for time_off (e.g. waiving occurrence deduction). Unused by other types."}},"type":"object","required":["type"],"title":"RequestIn","description":"One request to create.\n\nWhat you currently hold and are giving up goes in offered_entries. What you want\ngoes in requested_entries. modify_* and cancel_* send exactly one offered entry\nwhose id is the existing shift or time off. time_off, availability, claim_shift,\nand release_shift leave resource_id unset. A row that already has a pending\nrequest of the same type is rejected — use POST /decide or POST /cancel on that\npending request instead."},"RequestItem":{"properties":{"resource_id":{"type":"integer","title":"Resource Id","description":"Which row this request is about.\n- availability: a synthetic negative id for the open window.\n- modify_shift: the shift being changed.\n- cancel_shift: the shift being cancelled.\n- claim_shift: the shift_swap id for this claim.\n- release_shift: the shift_swap id for this release.\n- time_off: the unavailability.\n- modify_time_off: the approved unavailability being changed.\n- cancel_time_off: the approved unavailability being cancelled."},"type":{"type":"string","enum":["availability","modify_shift","cancel_shift","time_off","modify_time_off","cancel_time_off","claim_shift","release_shift"],"title":"Type"},"person_id":{"type":"integer","title":"Person Id","description":"ID of the person attached to the resource being modified"},"start":{"type":"string","format":"date-time","title":"Start","description":"Start time of the existing resource (for client labels; not used in approvals)"},"time_created":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Time Created","description":"time_created of the underlying shift, time off, availability, or cover row. Null when that row does not exist yet, such as validate_only."},"requested_entries":{"items":{"$ref":"#/components/schemas/RequestEntryMinimal"},"type":"array","title":"Requested Entries","description":"What this request is asking to receive.\n- availability: the new shift.\n- modify_shift: the proposed replacement shift.\n- cancel_shift: empty. Nothing is being asked for.\n- claim_shift: the shift being claimed.\n- release_shift: empty for a give-away. For a trade, up to 5 slots the person would accept. The same shift can fill more than one slot.\n- time_off: the new windows.\n- modify_time_off: the proposed replacement. May include shift entries.\n- cancel_time_off: empty. Nothing is being asked for."},"offered_entries":{"items":{"$ref":"#/components/schemas/RequestEntryMinimal"},"type":"array","title":"Offered Entries","description":"What this request is giving up.\n- availability: empty. Nothing is being given up.\n- modify_shift: the existing shift.\n- cancel_shift: the existing shift.\n- claim_shift: the claimant's own shift when this is a trade. Empty for a plain claim.\n- release_shift: the shift or window being released.\n- time_off: empty. Nothing is being given up.\n- modify_time_off: the existing unavailability.\n- cancel_time_off: the existing unavailability."},"status":{"type":"string","title":"Status","description":"Status of the underlying resource. Defaults to 'pending' since most types are pending-only by construction. claim_shift can come back 'approved' when the caller's statuses includes it; time_off can come back 'approved' the same way.","default":"pending"},"validations":{"items":{"type":"string"},"type":"array","title":"Validations","description":"Policy messages raised while processing this request, e.g. 'Your availability will be reviewed by an admin.' Empty when nothing was flagged."},"notified":{"type":"boolean","title":"Notified","description":"Whether the person was sent a notification about this request","default":false}},"type":"object","required":["resource_id","type","person_id","start","requested_entries"],"title":"RequestItem"},"RequestValidation":{"properties":{"approval_status":{"type":"string","title":"Approval Status"},"message":{"type":"string","title":"Message"},"occurrence":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Occurrence","default":0},"is_hidden_occurrence":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Hidden Occurrence","default":false},"entry":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Entry"}},"type":"object","required":["approval_status","message"],"title":"RequestValidation","description":"Single validation result for a time off request"},"RequestValidationResponse":{"properties":{"validations":{"items":{"$ref":"#/components/schemas/RequestValidation"},"type":"array","title":"Validations"},"overall_status":{"type":"string","title":"Overall Status"}},"type":"object","required":["validations","overall_status"],"title":"RequestValidationResponse","description":"Response containing all validation results for a time off request","example":{"overall_status":"pending","validations":[{"approval_status":"MANAGER","entry":{"start":"2025-01-15T10:00:00Z","type_id":5},"is_hidden_occurrence":false,"message":"Vacation requests need at least 48 hours notice","occurrence":1}]}},"RequestableTradeSlot":{"properties":{"id":{"type":"integer","title":"Id"},"start":{"type":"string","format":"date-time","title":"Start"},"end":{"type":"string","format":"date-time","title":"End"},"team_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Team Id"},"role_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Role Id"},"shift_type_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Shift Type Id"},"person_first_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Person First Name"},"person_last_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Person Last Name"}},"type":"object","required":["id","start","end"],"title":"RequestableTradeSlot","description":"A single offerable (shift, start, end) window returned by\nGET /shifts/requestable - one row per valid slot-interval-aligned start\nwithin a candidate shift. Deliberately excludes person_id and every\nDynamicShiftOut field not needed to render/submit a trade choice.\n\nid/start/end line up with RequestEntryMinimal so this can be passed\nstraight through to release_shift's requested_entries with zero\ntransformation."},"RequestsIn":{"properties":{"items":{"items":{"$ref":"#/components/schemas/RequestIn"},"type":"array","minItems":1,"title":"Items","description":"One or more request payloads. Items and requested_entries for the same person whose windows fall in the same work week are submitted together so weekly rules apply to the full week."}},"type":"object","required":["items"],"title":"RequestsIn"},"RequestsOut":{"properties":{"results":{"items":{"$ref":"#/components/schemas/RequestItem"},"type":"array","title":"Results"}},"type":"object","required":["results"],"title":"RequestsOut"},"RequiredHost":{"properties":{"team_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Team Id","description":"Team required to host the activity type"},"role_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Role Id","description":"Role required to host the activity type"},"count":{"type":"integer","title":"Count","description":"Number of hosts required with this team/role","default":1}},"type":"object","title":"RequiredHost"},"RoleNew":{"properties":{"name":{"type":"string","title":"Name","description":"The role's name. Must be unique"},"color":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Color","description":"The role's color. HEX format"},"person_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Person Ids","description":"List of person IDs with the role"},"license_type_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"License Type Ids","description":"List of license IDs that are required for the role"},"team_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Team Ids","description":"List of team IDs"}},"type":"object","required":["name"],"title":"RoleNew"},"RoleRead":{"properties":{"id":{"type":"integer","title":"Id","description":"The role's primary ID which is generated when the role is created"},"name":{"type":"string","title":"Name","description":"The role's name. Must be unique"},"color":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Color","description":"The role's color. HEX format"}},"type":"object","required":["id","name"],"title":"RoleRead"},"RoleReponse":{"properties":{"id":{"type":"integer","title":"Id"},"name":{"type":"string","title":"Name"},"color":{"type":"string","title":"Color"}},"type":"object","required":["id","name","color"],"title":"RoleReponse"},"Rule":{"properties":{"rule_type":{"$ref":"#/components/schemas/RuleType"},"rule_action":{"anyOf":[{"$ref":"#/components/schemas/RuleAction"},{"type":"null"}]},"rule_secondary_action":{"anyOf":[{"$ref":"#/components/schemas/RuleAction"},{"type":"null"}]},"value":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Value"},"unit":{"anyOf":[{"$ref":"#/components/schemas/RuleUnit"},{"type":"null"}]},"unavailability_type_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Unavailability Type Ids","default":[]},"secondary_unavailability_type_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Secondary Unavailability Type Ids","default":[]},"datastream_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Datastream Ids","default":[]},"trigger":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Trigger"},"rrule":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Rrule"},"parameters":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Parameters"},"value_2":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Value 2"},"id":{"type":"integer","title":"Id"},"time_created":{"type":"string","format":"date-time","title":"Time Created"},"time_updated":{"type":"string","format":"date-time","title":"Time Updated"},"ruleset_id":{"type":"integer","title":"Ruleset Id"},"unavailability_types":{"anyOf":[{"items":{"$ref":"#/components/schemas/UnavailabilityTypeLazyRead"},"type":"array"},{"type":"null"}],"title":"Unavailability Types"},"secondary_unavailability_types":{"anyOf":[{"items":{"$ref":"#/components/schemas/UnavailabilityTypeLazyRead"},"type":"array"},{"type":"null"}],"title":"Secondary Unavailability Types"},"datastreams":{"anyOf":[{"items":{"$ref":"#/components/schemas/Datastream"},"type":"array"},{"type":"null"}],"title":"Datastreams"}},"type":"object","required":["rule_type","id","time_created","time_updated","ruleset_id"],"title":"Rule"},"RuleAction":{"type":"string","enum":["reject","review_and_add_hidden_3_occurrences","review_and_add_hidden_2_occurrences","review_and_add_hidden_occurrence","review_and_add_3_occurrences","review_and_add_2_occurrences","review_and_add_occurrence","notify_manager","review","notify","approve","callout"],"title":"RuleAction"},"RuleNew":{"properties":{"rule_type":{"$ref":"#/components/schemas/RuleType"},"rule_action":{"anyOf":[{"$ref":"#/components/schemas/RuleAction"},{"type":"null"}]},"rule_secondary_action":{"anyOf":[{"$ref":"#/components/schemas/RuleAction"},{"type":"null"}]},"value":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Value"},"unit":{"anyOf":[{"$ref":"#/components/schemas/RuleUnit"},{"type":"null"}]},"unavailability_type_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Unavailability Type Ids","default":[]},"secondary_unavailability_type_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Secondary Unavailability Type Ids","default":[]},"datastream_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Datastream Ids","default":[]},"trigger":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Trigger"},"rrule":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Rrule"},"parameters":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Parameters"},"value_2":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Value 2"}},"type":"object","required":["rule_type"],"title":"RuleNew"},"RuleType":{"type":"string","enum":["default_action","make_up_time","advance_notice","min_length","date_restrictions","self_scheduling","self_scheduling_modify","self_scheduling_delete","self_scheduling_activities","contracted_hours","min_hours_day","max_hours_day","required_hours","required_time_off_hours","min_shift_length","max_shift_length","submit_schedule_notification","admin_submit_schedule_notification","shift_reminder","clock_in_out","clock_in_reminder","clock_out_reminder","cancel_time_off","take_a_break","pending_request_reminder","restrict_past_pay_run","restrict_past_pay_periods","last_resort","block_after_date","min_monthly_weekend_hours","create_shifts_via_timesheets","edit_timesheet_clock_times","edit_timesheet_activities","claimed_shift_notification","preferred_work_hours_notification","manual_publishing_required","max_consecutive_hours","overnight_recovery_period","max_overnight","submit_in_advance","time_off_notification","exclusive_claims","limit_claims","swap_eligibility","trade_eligibility","min_days_in_set","restricted_shift_hours","out_of_adherence_notification","out_of_adherence_manager_notification","recurring_schedule_notice"],"title":"RuleType"},"RuleUnit":{"type":"string","enum":["hours","days","weeks","months","years","holidays","weekends","holidays_and_weekends","voice_call","sms","email","slack","push_notification","auto_clock_out"],"title":"RuleUnit"},"RulesetJoinNew":{"properties":{"team_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Team Id"},"role_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Role Id"},"custom_option_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Custom Option Id"}},"type":"object","title":"RulesetJoinNew"},"RulesetNew":{"properties":{"name":{"type":"string","title":"Name"},"rules":{"anyOf":[{"items":{"$ref":"#/components/schemas/RuleNew"},"type":"array"},{"type":"null"}],"title":"Rules","default":[]},"ruleset_joins":{"anyOf":[{"items":{"$ref":"#/components/schemas/RulesetJoinNew"},"type":"array"},{"type":"null"}],"title":"Ruleset Joins","default":[]},"enabled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Enabled","default":true}},"type":"object","required":["name"],"title":"RulesetNew"},"RulesetOut":{"properties":{"name":{"type":"string","title":"Name"},"rules":{"anyOf":[{"items":{"$ref":"#/components/schemas/Rule"},"type":"array"},{"type":"null"}],"title":"Rules"},"ruleset_joins":{"anyOf":[{"items":{"$ref":"#/components/schemas/RulesetJoinNew"},"type":"array"},{"type":"null"}],"title":"Ruleset Joins","default":[]},"enabled":{"type":"boolean","title":"Enabled","default":true},"id":{"type":"integer","title":"Id"},"time_created":{"type":"string","format":"date-time","title":"Time Created"},"time_updated":{"type":"string","format":"date-time","title":"Time Updated"},"organisation_id":{"type":"integer","title":"Organisation Id"},"archived":{"type":"boolean","title":"Archived","default":false},"applicable_person_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Applicable Person Ids"}},"type":"object","required":["name","id","time_created","time_updated","organisation_id"],"title":"RulesetOut","description":"Response shape for GET /api/v1/rulesets.\n\napplicable_person_ids is set on the ORM object only when\ninclude_applicable_person_ids=True was requested; response_model_exclude_unset\non the route means the key is omitted entirely when it was never set, and\npresent (possibly null, for org-wide rulesets) when it was."},"ScheduledTriggerRequest":{"properties":{"thread_id":{"type":"integer","title":"Thread Id"},"goal":{"type":"string","title":"Goal"},"job_id":{"type":"string","title":"Job Id"}},"type":"object","required":["thread_id","goal","job_id"],"title":"ScheduledTriggerRequest"},"ScorePersonInput":{"properties":{"person_id":{"type":"integer","title":"Person Id"}},"type":"object","required":["person_id"],"title":"ScorePersonInput"},"SegmentWhen":{"properties":{"booking_time":{"items":{"type":"string"},"type":"array","title":"Booking Time"}},"additionalProperties":false,"type":"object","required":["booking_time"],"title":"SegmentWhen","description":"Version 1 only allows a booking-time window. Extra keys are rejected."},"SendInviteEmailAPI":{"properties":{"person_id":{"type":"integer","title":"Person Id"},"expires_in_hours":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Expires In Hours","default":2160}},"type":"object","required":["person_id"],"title":"SendInviteEmailAPI"},"SendOutboundMessageInput":{"properties":{"channel":{"type":"string","enum":["sms","email"],"title":"Channel"},"message":{"type":"string","title":"Message"},"recipient_ids":{"items":{"type":"integer"},"type":"array","title":"Recipient Ids"},"thread_id":{"type":"integer","title":"Thread Id"},"subject":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Subject"},"attachment_file_keys":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Attachment File Keys"}},"type":"object","required":["channel","message","recipient_ids","thread_id"],"title":"SendOutboundMessageInput"},"ShiftActivity":{"properties":{"id":{"anyOf":[{"type":"integer"},{"type":"string"},{"type":"null"}],"title":"Id","description":"The unique ID of the activity"},"activity_type_id":{"type":"integer","title":"Activity Type Id","description":"The ID of the activity type"},"start":{"type":"string","format":"date-time","title":"Start","description":"The start time (UTC) of the activity e.g 2023-07-27 06:30:00+00"},"end":{"type":"string","format":"date-time","title":"End","description":"The end time (UTC) of the activity e.g 2023-07-27 06:30:00+00"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes","description":"Notes for the activity"},"recurrence_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Recurrence Id","description":"The recurrence ID for the activity"},"shift_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Shift Ids","description":"List of shift IDs to which the activity is joined"}},"type":"object","required":["activity_type_id","start","end"],"title":"ShiftActivity"},"ShiftNew":{"properties":{"start":{"type":"string","format":"date-time","title":"Start","description":"The start time (UTC) of the shift e.g 2023-07-27 06:30:00+00"},"end":{"type":"string","format":"date-time","title":"End","description":"The end time (UTC) of the shift e.g 2023-07-27 06:30:00+00"},"team_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Team Id","description":"The ID of the team the shift belongs to (if any)"},"role_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Role Id","description":"The ID of the role the shift belongs to (if any)"},"shift_type_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Shift Type Id","description":"The ID of the shift type"},"recurrence_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Recurrence Id","description":"The ID of the recurrence the shift belongs to"},"person_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Person Id","description":"The ID of the person assigned to the shift (if any)"},"payment_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Payment Id","description":"The ID of the payment associated with the shift"},"people_required":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"People Required","description":"The number of people required for the shift if unassigned"},"needs_publishing_calendar":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Needs Publishing Calendar","description":"Whether the shift needs syncing to the user's calendar","default":false},"needs_publishing_slack":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Needs Publishing Slack","description":"Whether the shift needs publishing on slack","default":false},"is_publishing_calendar":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Publishing Calendar","description":"Whether the shift is re-syncing to the user's calendar","default":false},"is_publishing_slack":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Publishing Slack","description":"Whether the shift is re-publishing on slack","default":false},"needs_publishing_email":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Needs Publishing Email","description":"Whether the shift needs re-sending email to the user","default":false},"is_publishing_email":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Publishing Email","description":"Whether the shift is re-sending email to the user","default":false},"needs_publishing_sms":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Needs Publishing Sms","description":"Whether the shift needs re-sending sms to the user","default":false},"is_publishing_sms":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Publishing Sms","description":"Whether the shift is re-sending sms to the user","default":false},"time_published":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Time Published","description":"When shift was last published"},"auto_approve_changes":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Auto Approve Changes","description":"Whether shift change requests should be approved automatically","default":false},"allow_alternative_times":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Allow Alternative Times","description":"Whether person can request changes to the timing of their shift","default":false},"published_detail":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Published Detail","description":"Details the shift that was published"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes","description":"Any notes about the shift"},"created_at_clock_in":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Created At Clock In","description":"Whether shift was created as a result of clocking-in","default":false},"approved":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Approved","description":"Whether timesheet associated with the shift has been approved","default":false},"license_type_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"License Type Ids","description":"List of license types IDs required for shift"},"client_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Client Ids","description":"List of client IDs required for shift"},"flex_hours":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Flex Hours","description":"Whether the shift has flexible hours","default":false},"recurrence_details":{"anyOf":[{"$ref":"#/components/schemas/RecurrenceNew"},{"type":"null"}],"description":"The recurrence details for the shift"},"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status","description":"The status of the shift","default":"approved"},"archived":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Archived","description":"Whether shift has been archived","default":false},"cascade_":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Cascade","description":"Whether to update joined objects that are linked to the shift","default":false},"clock_in_time":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Clock In Time","description":"The time when the person clocked in (UTC)"},"clock_out_time":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Clock Out Time","description":"The time when the person clocked out (UTC)"},"activities":{"anyOf":[{"items":{"$ref":"#/components/schemas/ShiftActivity"},"type":"array"},{"type":"null"}],"title":"Activities","description":"The activities that are linked to the shift"}},"type":"object","required":["start","end"],"title":"ShiftNew"},"ShiftOpportunity":{"properties":{"id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Id","description":"The shift this opportunity comes from"},"start":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Start","description":"When the opportunity starts (UTC)"},"end":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"End","description":"When the opportunity ends (UTC)"},"team_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Team Id","description":"Team the shift belongs to"},"role_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Role Id","description":"Role the shift belongs to"},"shift_type_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Shift Type Id","description":"Shift type, sometimes called a shift tag"},"person_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Person Id","description":"Person who currently holds the shift. Null when it is unassigned"},"people_required":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"People Required","description":"How many people an unassigned shift still needs"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes","description":"Notes on the shift"},"activities":{"anyOf":[{"items":{"$ref":"#/components/schemas/DynamicActivityOut"},"type":"array"},{"type":"null"}],"title":"Activities"},"shift_type":{"anyOf":[{"$ref":"#/components/schemas/ShiftTypeRead"},{"type":"null"}]},"clients":{"anyOf":[{"items":{"$ref":"#/components/schemas/ClientRead"},"type":"array"},{"type":"null"}],"title":"Clients"},"license_types":{"anyOf":[{"items":{"$ref":"#/components/schemas/LicenseTypeRead"},"type":"array"},{"type":"null"}],"title":"License Types"},"eligible_people":{"anyOf":[{"items":{"$ref":"#/components/schemas/EligiblePerson"},"type":"array"},{"type":"null"}],"title":"Eligible People"},"requested_shifts":{"anyOf":[{"items":{"$ref":"#/components/schemas/ShiftOpportunityRequestedShift"},"type":"array"},{"type":"null"}],"title":"Requested Shifts","description":"For shift trades, this represents the list of shifts the releaser would accept in exchange. The same id can appear more than once, once per part of that shift. Null when this opportunity is an unassigned shift or a release with nothing asked in return."}},"type":"object","title":"ShiftOpportunity","description":"One opening from GET /shifts/vacant. It is one of:\n\n- An unassigned shift. Nobody holds it, so person_id is null and requested_shifts is null. start and end are the shift.\n- A swap. A person still holds the shift and is giving up some or all of it, with nothing asked in return. person_id is that person. start and end are the window they are giving up, which can be shorter than the shift. requested_shifts is null.\n- A trade. A release where that person will only give up the window in exchange for one of requested_shifts. Each entry there is a shift they would accept in return, and the part of it they want. The same shift can appear more than once, once per part."},"ShiftOpportunityRequestedShift":{"properties":{"id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Id","description":"The shift the releaser would accept in return"},"start":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Start","description":"Start of the part of that shift they want (UTC)"},"end":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"End","description":"End of the part of that shift they want (UTC)"}},"type":"object","title":"ShiftOpportunityRequestedShift","description":"For opportunities as part of a shift trade, \nrepresents a shift the releaser would accept in return.\n\nid is that shift. start and end are the segment of the shift they want.\nThe same id can appear more than once, once per segment."},"ShiftOptional":{"properties":{"id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Id","description":"The unique ID of the shift"},"start":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Start","description":"The start time (UTC) of the shift e.g 2023-07-27 06:30:00+00"},"end":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"End","description":"The end time (UTC) of the shift e.g 2024-07-27 06:30:00+00"},"team_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Team Id","description":"The ID of the team the shift belongs to"},"role_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Role Id","description":"The ID of the role the shift belongs to"},"person_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Person Id","description":"The ID of the person assigned to the shift (if any)"},"payment_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Payment Id","description":"The ID of the payment associated with the shift"},"people_required":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"People Required","description":"The number of people required for the shift if unassigned"},"rrule":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Rrule","description":"The recurrence rule for the shift"},"recurrence_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Recurrence Id","description":"The recurrence ID for the shift"},"shift_type_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Shift Type Id","description":"The ID of the shift type"},"approved":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Approved","description":"Whether timesheet associated with the shift has been approved","default":false},"needs_publishing_calendar":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Needs Publishing Calendar","description":"Whether the shift needs re-syncing to the user's calendar","default":false},"needs_publishing_slack":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Needs Publishing Slack","description":"Whether the shift needs re-publishing on slack","default":false},"needs_publishing_email":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Needs Publishing Email","description":"Whether the shift needs re-sending email to the user","default":false},"needs_publishing_sms":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Needs Publishing Sms","description":"Whether the shift needs re-sending sms to the user","default":false},"is_publishing_calendar":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Publishing Calendar","description":"Whether the shift is re-syncing to the user's calendar","default":false},"is_publishing_slack":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Publishing Slack","description":"Whether the shift is re-publishing on slack","default":false},"is_publishing_email":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Publishing Email","description":"Whether the shift is re-sending email to the user","default":false},"is_publishing_sms":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Publishing Sms","description":"Whether the shift is re-sending sms to the user","default":false},"time_published":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Time Published","description":"When shift was last published"},"auto_approve_changes":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Auto Approve Changes","description":"Whether shift change requests should be approved automatically","default":false},"allow_alternative_times":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Allow Alternative Times","description":"Whether person can request changes to the timing of their shift","default":false},"published_detail":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Published Detail","description":"Details the shift that was published"},"gcal_event_ids":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Gcal Event Ids","description":"Google event id if the person assigned the shift has GCal integration set-up"},"ehr_block_ids":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Ehr Block Ids","description":"EHR appointment IDs for blocking appointments in external systems like Athena"},"slack_broadcast_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Slack Broadcast Id","description":"Links to Slack announcements where shift is posted"},"last_reminder_sent":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Last Reminder Sent","description":"The last time a reminder was sent for the shift"},"is_sending_reminder":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Sending Reminder","description":"Whether a reminder is being sent to the user","default":false},"organisation_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Organisation Id","description":"The ID of the organisation the shift belongs to"},"time_created":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Time Created","description":"The time (UTC) when the shift was created"},"time_updated":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Time Updated","description":"The time (UTC) when the shift was last updated"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes","description":"Any notes about the shift"},"created_at_clock_in":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Created At Clock In","description":"Whether shift was created as a result of clocking-in","default":false},"flex_hours":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Flex Hours","description":"Whether the shift has flexible hours","default":false},"license_type_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"License Type Ids","description":"List of license types IDs required for shift"},"client_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Client Ids","description":"List of client IDs required for shift"},"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status","description":"The status of the shift","default":"approved"},"archived":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Archived","description":"Whether shift has been archived","default":false}},"type":"object","title":"ShiftOptional"},"ShiftOutExternalAPI":{"properties":{"id":{"type":"integer","title":"Id","description":"The unique ID of the shift"},"organisation_id":{"type":"integer","title":"Organisation Id","description":"The ID of the organisation the shift belongs to"},"start":{"type":"string","format":"date-time","title":"Start","description":"The start time (UTC) of the shift e.g 2023-07-27 06:30:00+00"},"end":{"type":"string","format":"date-time","title":"End","description":"The end time (UTC) of the shift e.g 2023-07-27 06:30:00+00"},"team_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Team Id","description":"The ID of the team the shift belongs to"},"role_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Role Id","description":"The ID of the role the shift belongs to"},"shift_type_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Shift Type Id","description":"The ID of the shift type"},"person_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Person Id","description":"The ID of the person assigned to the shift (if any)"},"payment_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Payment Id","description":"The ID of the payment associated with the shift"},"people_required":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"People Required","description":"The number of people required for the shift if unassigned"},"rrule":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Rrule","description":"The recurrence rule for the shift"},"recurrence_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Recurrence Id","description":"The recurrence ID for the shift"},"needs_publishing_calendar":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Needs Publishing Calendar","description":"Whether the shift needs re-syncing to the user's calendar","default":false},"needs_publishing_slack":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Needs Publishing Slack","description":"Whether the shift needs re-publishing on slack","default":false},"is_publishing_calendar":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Publishing Calendar","description":"Whether the shift is re-syncing to the user's calendar","default":false},"is_publishing_slack":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Publishing Slack","description":"Whether the shift is re-publishing on slack","default":false},"needs_publishing_email":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Needs Publishing Email","description":"Whether the shift needs re-sending email to the user","default":false},"needs_publishing_sms":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Needs Publishing Sms","description":"Whether the shift needs re-sending sms to the user","default":false},"is_publishing_email":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Publishing Email","description":"Whether the shift is re-sending email to the user","default":false},"is_publishing_sms":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Publishing Sms","description":"Whether the shift is re-sending sms to the user","default":false},"approved":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Approved","description":"Whether timesheet associated with the shift has been approved","default":false},"time_published":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Time Published","description":"When shift was last published"},"auto_approve_changes":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Auto Approve Changes","description":"Whether shift change requests should be approved automatically","default":false},"allow_alternative_times":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Allow Alternative Times","description":"Whether person can request changes to the timing of their shift","default":false},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes","description":"Any notes about the shift"},"created_at_clock_in":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Created At Clock In","description":"Whether shift was created as a result of clocking-in","default":false},"flex_hours":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Flex Hours","description":"Whether the shift has flexible hours","default":false},"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status","description":"The status of the shift","default":"approved"},"archived":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Archived","description":"Whether shift has been archived","default":false},"timecard":{"anyOf":[{"$ref":"#/components/schemas/Timesheet"},{"type":"null"}],"description":"Calculated timecard based on actual clock in/out times"},"scheduled_timecard":{"anyOf":[{"$ref":"#/components/schemas/Timesheet"},{"type":"null"}],"description":"Calculated timecard based on scheduled shift times"},"time_created":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Time Created","description":"The time (UTC) when the shift was created"},"time_updated":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Time Updated","description":"The time (UTC) when the shift was last updated"},"published_detail":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Published Detail","description":"Details the shift that was published"},"activities":{"anyOf":[{"items":{"$ref":"#/components/schemas/ActivityRead"},"type":"array"},{"type":"null"}],"title":"Activities"},"person":{"anyOf":[{"$ref":"#/components/schemas/PersonRead"},{"type":"null"}]},"team":{"anyOf":[{"$ref":"#/components/schemas/TeamRead"},{"type":"null"}]},"role":{"anyOf":[{"$ref":"#/components/schemas/RoleRead"},{"type":"null"}]},"license_types":{"anyOf":[{"items":{"$ref":"#/components/schemas/LicenseTypeRead"},"type":"array"},{"type":"null"}],"title":"License Types"},"shift_type":{"anyOf":[{"$ref":"#/components/schemas/ShiftTypeRead"},{"type":"null"}]},"actions":{"anyOf":[{"items":{"$ref":"#/components/schemas/ActionReadAPI"},"type":"array"},{"type":"null"}],"title":"Actions"},"clients":{"anyOf":[{"items":{"$ref":"#/components/schemas/ClientRead"},"type":"array"},{"type":"null"}],"title":"Clients"},"eligible_person_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Eligible Person Ids"}},"type":"object","required":["id","organisation_id","start","end"],"title":"ShiftOutExternalAPI"},"ShiftRead":{"properties":{"id":{"type":"integer","title":"Id","description":"The unique ID of the shift"},"organisation_id":{"type":"integer","title":"Organisation Id","description":"The ID of the organisation the shift belongs to"},"start":{"type":"string","format":"date-time","title":"Start","description":"The start time (UTC) of the shift e.g 2023-07-27 06:30:00+00"},"end":{"type":"string","format":"date-time","title":"End","description":"The end time (UTC) of the shift e.g 2023-07-27 06:30:00+00"},"team_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Team Id","description":"The ID of the team the shift belongs to"},"role_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Role Id","description":"The ID of the role the shift belongs to"},"shift_type_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Shift Type Id","description":"The ID of the shift type"},"person_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Person Id","description":"The ID of the person assigned to the shift (if any)"},"payment_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Payment Id","description":"The ID of the payment associated with the shift"},"people_required":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"People Required","description":"The number of people required for the shift if unassigned"},"rrule":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Rrule","description":"The recurrence rule for the shift"},"recurrence_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Recurrence Id","description":"The recurrence ID for the shift"},"needs_publishing_calendar":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Needs Publishing Calendar","description":"Whether the shift needs re-syncing to the user's calendar","default":false},"needs_publishing_slack":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Needs Publishing Slack","description":"Whether the shift needs re-publishing on slack","default":false},"is_publishing_calendar":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Publishing Calendar","description":"Whether the shift is re-syncing to the user's calendar","default":false},"is_publishing_slack":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Publishing Slack","description":"Whether the shift is re-publishing on slack","default":false},"needs_publishing_email":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Needs Publishing Email","description":"Whether the shift needs re-sending email to the user","default":false},"needs_publishing_sms":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Needs Publishing Sms","description":"Whether the shift needs re-sending sms to the user","default":false},"is_publishing_email":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Publishing Email","description":"Whether the shift is re-sending email to the user","default":false},"is_publishing_sms":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Publishing Sms","description":"Whether the shift is re-sending sms to the user","default":false},"approved":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Approved","description":"Whether timesheet associated with the shift has been approved","default":false},"time_published":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Time Published","description":"When shift was last published"},"auto_approve_changes":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Auto Approve Changes","description":"Whether shift change requests should be approved automatically","default":false},"allow_alternative_times":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Allow Alternative Times","description":"Whether person can request changes to the timing of their shift","default":false},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes","description":"Any notes about the shift"},"created_at_clock_in":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Created At Clock In","description":"Whether shift was created as a result of clocking-in","default":false},"flex_hours":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Flex Hours","description":"Whether the shift has flexible hours","default":false},"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status","description":"The status of the shift","default":"approved"},"archived":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Archived","description":"Whether shift has been archived","default":false},"timecard":{"anyOf":[{"$ref":"#/components/schemas/Timesheet"},{"type":"null"}],"description":"Calculated timecard based on actual clock in/out times"},"scheduled_timecard":{"anyOf":[{"$ref":"#/components/schemas/Timesheet"},{"type":"null"}],"description":"Calculated timecard based on scheduled shift times"},"time_created":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Time Created","description":"The time (UTC) when the shift was created"},"time_updated":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Time Updated","description":"The time (UTC) when the shift was last updated"},"published_detail":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Published Detail","description":"Details the shift that was published"}},"type":"object","required":["id","organisation_id","start","end"],"title":"ShiftRead"},"ShiftTypeNew":{"properties":{"name":{"type":"string","title":"Name","description":"The name of the activity type"},"color":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Color","description":"The color of the activity type"},"enabled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Enabled","description":"Whether this shift type is enabled","default":true},"license_type_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"License Type Ids","description":"List of license type IDs that this activity type requires"},"team_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Team Ids","description":"List of teams that can perform this activity"},"role_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Role Ids","description":"List of roles that can perform this activity"},"person_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Person Ids","description":"List of people that can perform this activity"},"custom_option_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Custom Option Ids","description":"List of custom option IDs associated with the shift type"}},"type":"object","required":["name"],"title":"ShiftTypeNew"},"ShiftTypeRead":{"properties":{"id":{"type":"integer","title":"Id","description":"The unique ID of the activity type"},"name":{"type":"string","title":"Name","description":"The name of the activity type"},"color":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Color","description":"The color of the activity type"},"enabled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Enabled","description":"Whether this shift type is enabled","default":true},"custom_option_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Custom Option Ids","description":"List of custom option IDs associated with the shift type"},"archived":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Archived","description":"Whether this shift type is archived","default":false},"organisation_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Organisation Id","description":"The ID of the organisation the shift type belongs to"},"eligible_employment_classifications":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Eligible Employment Classifications","description":"Employment classifications eligible for this shift type"},"time_created":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Time Created","description":"The time (UTC) when the shift type was created"},"time_updated":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Time Updated","description":"The time (UTC) when the shift type was last updated"}},"type":"object","required":["id","name"],"title":"ShiftTypeRead"},"SlackPostPayload":{"properties":{"phone_number":{"type":"string","title":"Phone Number"},"message":{"type":"string","title":"Message"},"sender":{"type":"string","title":"Sender","default":"user"}},"type":"object","required":["phone_number","message"],"title":"SlackPostPayload"},"SlotAlert":{"properties":{"states":{"items":{"type":"string"},"type":"array","title":"States","description":"States the rule applies to (ANY or state codes e.g. CA, NY)","default":["ANY"]},"threshold":{"type":"number","title":"Threshold","description":"Alert when the next available slot is further out than this"},"threshold_unit":{"type":"string","enum":["days","hours"],"title":"Threshold Unit","description":"Unit for threshold (days | hours)","default":"days"},"channel":{"type":"string","enum":["slack","email"],"title":"Channel","description":"How the alert is delivered (slack | email)"},"recipients":{"items":{"type":"string","enum":["all_admins","all_managers","specific_people"]},"type":"array","title":"Recipients","description":"Who receives the alert"},"person_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Person Ids","description":"Recipient person IDs when recipients=specific_people"}},"type":"object","required":["threshold","channel","recipients"],"title":"SlotAlert"},"SlotGenerationMode":{"type":"string","enum":["default_available","availability_required"],"title":"SlotGenerationMode"},"StatusResponse":{"properties":{"current_shift":{"anyOf":[{"$ref":"#/components/schemas/ShiftRead"},{"type":"null"}]},"current_clock_in":{"anyOf":[{"$ref":"#/components/schemas/ActionRead"},{"type":"null"}]},"next_clock_in_from":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Next Clock In From"},"next_shift":{"anyOf":[{"$ref":"#/components/schemas/ShiftRead"},{"type":"null"}]}},"type":"object","title":"StatusResponse"},"TSRecord":{"properties":{"stat":{"type":"number","title":"Stat"},"time":{"type":"integer","title":"Time"}},"type":"object","required":["stat","time"],"title":"TSRecord"},"TeamNew":{"properties":{"name":{"type":"string","title":"Name","description":"The team's name. Must be unique"},"address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address","description":"The team's location"},"color":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Color","description":"The teams's color. HEX format"},"secondary_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Secondary Id","description":"The team's secondary ID"},"person_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Person Ids","description":"List of person IDs in the team"},"role_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Role Ids","description":"List of role IDs in the team"},"custom_fields":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Custom Fields","description":"Custom fields for this team (reference/joined-table fields not supported)"}},"type":"object","required":["name"],"title":"TeamNew"},"TeamRead":{"properties":{"id":{"type":"integer","title":"Id","description":"The team's primary ID which is generated when the team is created"},"name":{"type":"string","title":"Name","description":"The team's name. Must be unique"},"address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address","description":"The team's location"},"color":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Color","description":"The teams's color. HEX format"},"custom_fields":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Custom Fields","description":"Custom fields for this team"}},"type":"object","required":["id","name"],"title":"TeamRead"},"TeamReponse":{"properties":{"id":{"type":"integer","title":"Id"},"name":{"type":"string","title":"Name"},"color":{"type":"string","title":"Color"}},"type":"object","required":["id","name","color"],"title":"TeamReponse"},"ThreadAPIResponse":{"properties":{"id":{"type":"integer","title":"Id","description":"Unique identifier for the thread"},"time_created":{"type":"string","format":"date-time","title":"Time Created","description":"Timestamp of when the thread was created"},"time_updated":{"type":"string","format":"date-time","title":"Time Updated","description":"Timestamp of when the thread was last updated"},"organisation_id":{"type":"integer","title":"Organisation Id","description":"ID of the organisation the thread belongs to"},"person_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Person Id","description":"ID of the person who owns this thread"},"custom_component_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Custom Component Id","description":"ID of the custom component this thread belongs to"},"recipient_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Recipient Type","description":"Whether recipient_ids refer to people or patients. Null means people."},"channel":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Channel","description":"Channel of the thread"},"summary":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Summary","description":"For most channels, a concise thread summary; for email threads, the message subject line."},"slack_thread_ts":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Slack Thread Ts","description":"Thread timestamp id in slack that corresponds to this thread in planbase"},"last_message_at":{"type":"string","format":"date-time","title":"Last Message At","readOnly":true},"recipient_ids":{"items":{"type":"integer"},"type":"array","title":"Recipient Ids","readOnly":true},"is_read":{"type":"boolean","title":"Is Read","readOnly":true}},"type":"object","required":["id","time_created","time_updated","organisation_id","last_message_at","recipient_ids","is_read"],"title":"ThreadAPIResponse"},"ThreadNew":{"properties":{"person_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Person Id","description":"ID of the person who owns this thread"},"custom_component_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Custom Component Id","description":"ID of the custom component this thread belongs to"},"recipient_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Recipient Ids","description":"List of person IDs who are recipients of this thread"},"recipient_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Recipient Type","description":"Whether recipient_ids refer to people or patients. Null means people."},"channel":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Channel","description":"Channel of the thread"},"summary":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Summary","description":"Initial summary/subject for the thread"},"slack_thread_ts":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Slack Thread Ts","description":"Thread timestamp id in slack that corresponds to this thread in planbase"},"patient_recipient_ids":{"anyOf":[{"items":{"type":"integer"},"type":"array"},{"type":"null"}],"title":"Patient Recipient Ids","description":"List of patient IDs who are recipients of this thread"}},"type":"object","title":"ThreadNew"},"TicketCountPoint":{"properties":{"time":{"type":"string","title":"Time","description":"ISO datetime string"},"count":{"type":"number","title":"Count","description":"Ticket count for this period"}},"type":"object","required":["time","count"],"title":"TicketCountPoint"},"TicketInMetadata":{"properties":{"id":{"type":"integer","title":"Id","description":"Ticket ID"},"external_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"External Id","description":"External ticket ID (e.g., from Zendesk, Jira)"},"state":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"State","description":"Patient state for the encounter"},"payment_value":{"type":"number","title":"Payment Value","description":"Payment amount for this individual ticket"}},"type":"object","required":["id","payment_value"],"title":"TicketInMetadata","description":"Ticket data embedded in value_metadata for display purposes."},"TimeOffBalanceBatchRequest":{"properties":{"person_ids":{"items":{"type":"integer"},"type":"array","title":"Person Ids","description":"List of person IDs to calculate balances for"},"timezone":{"type":"string","title":"Timezone","description":"Timezone for calculations","default":"America/New_York"},"calculation_date":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Calculation Date","description":"Date to calculate balances for (defaults to today)"}},"type":"object","required":["person_ids"],"title":"TimeOffBalanceBatchRequest","description":"Request schema for batch time off balance calculation"},"TimeOffBalanceBatchResponse":{"properties":{"balances":{"items":{"$ref":"#/components/schemas/PersonBalances"},"type":"array","title":"Balances","description":"Balance information for each person"}},"type":"object","required":["balances"],"title":"TimeOffBalanceBatchResponse","description":"Response schema for batch time off balance calculation"},"TimeOffRequestValidationResponse":{"properties":{"validations":{"items":{"$ref":"#/components/schemas/RequestValidation"},"type":"array","title":"Validations"},"overall_status":{"type":"string","title":"Overall Status"},"balance_details":{"anyOf":[{"items":{"$ref":"#/components/schemas/BalanceDetail"},"type":"array"},{"type":"null"}],"title":"Balance Details","default":[]}},"type":"object","required":["validations","overall_status"],"title":"TimeOffRequestValidationResponse","description":"Response containing all validation results for a time off request","example":{"overall_status":"pending","validations":[{"approval_status":"MANAGER","entry":{"start":"2025-01-15T10:00:00Z","type_id":5},"is_hidden_occurrence":false,"message":"Vacation requests need at least 48 hours notice","occurrence":1}]}},"Timesheet":{"properties":{"value":{"type":"number","title":"Value","description":"Total calculated payment value"},"value_metadata":{"additionalProperties":{"$ref":"#/components/schemas/ValueMetadataItem"},"type":"object","title":"Value Metadata","description":"Dictionary where keys are pay rule names and values show duration/cost breakdown"},"approved":{"type":"boolean","title":"Approved","description":"Whether this timesheet has been approved","default":false}},"type":"object","required":["value","value_metadata"],"title":"Timesheet","description":"Calculated timesheet for a shift.\n\n- value: total payment amount for the shift\n- value_metadata: breakdown by pay rule name showing duration and cost\n- approved: whether this timesheet has been approved"},"TokenResponse":{"properties":{"access_token":{"type":"string","title":"Access Token"},"refresh_token":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Refresh Token"},"expires_in":{"type":"integer","title":"Expires In"}},"type":"object","required":["access_token","refresh_token","expires_in"],"title":"TokenResponse"},"USState":{"type":"string","enum":["AL","AK","AZ","AR","CA","CO","CT","DE","DC","FL","GA","HI","ID","IL","IN","IA","KS","KY","LA","ME","MD","MA","MI","MN","MS","MO","MT","NE","NV","NH","NJ","NM","NY","NC","ND","OH","OK","OR","PA","RI","SC","SD","TN","TX","UT","VT","VA","WA","WV","WI","WY"],"title":"USState"},"UnavailabilityAllowanceAPIResponse":{"properties":{"unavailability_type_id":{"type":"integer","title":"Unavailability Type Id"},"allowance":{"type":"number","title":"Allowance"}},"type":"object","required":["unavailability_type_id","allowance"],"title":"UnavailabilityAllowanceAPIResponse"},"UnavailabilityAllowanceNew":{"properties":{"allowance":{"type":"number","title":"Allowance","description":"Allowance in hours."},"unavailability_type_id":{"type":"integer","title":"Unavailability Type Id","description":"Unavailability Type."},"person_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Person Id","description":"Person id."}},"type":"object","required":["allowance","unavailability_type_id"],"title":"UnavailabilityAllowanceNew"},"UnavailabilityBalanceAPIResponse":{"properties":{"unavailability_type_id":{"type":"integer","title":"Unavailability Type Id"},"balance":{"type":"number","title":"Balance"}},"type":"object","required":["unavailability_type_id","balance"],"title":"UnavailabilityBalanceAPIResponse"},"UnavailabilityBalanceNew":{"properties":{"balance":{"type":"number","title":"Balance","description":"Balance in hours."},"unavailability_type_id":{"type":"integer","title":"Unavailability Type Id","description":"Unavailability Type."},"person_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Person Id","description":"Person id."}},"type":"object","required":["balance","unavailability_type_id"],"title":"UnavailabilityBalanceNew"},"UnavailabilityResponse":{"properties":{"end":{"type":"string","format":"date-time","title":"End","description":"The end time (UTC) of the unavailability e.g 2023-07-27 06:30:00+00"},"exported":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Exported","description":"Whether the unavailability has been exported to payroll"},"external_ids":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"External Ids","description":"External system IDs mapping (e.g. {'adp': '123', 'healthie': '456'})"},"is_publishing_calendar":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Publishing Calendar","description":"Whether the unavailability is publishing to the user's calendar","default":false},"make_up_time":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Make Up Time","description":"The time the unavailability needs to be worked at another time"},"needs_publishing_calendar":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Needs Publishing Calendar","description":"Indicates if the unavailability needs publishing","default":false},"organisation_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Organisation Id","description":"The ID of the organisation the unavailability belongs to"},"person_id":{"type":"integer","title":"Person Id","description":"The ID of the person the unavailability belongs to"},"start":{"type":"string","format":"date-time","title":"Start","description":"The start time (UTC) of the unavailability e.g 2023-07-27 06:30:00+00"},"unavailability_type_id":{"type":"integer","title":"Unavailability Type Id","description":"The ID of the unavailability type"},"status":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Status","description":"The status of the time off entry","default":"approved"},"archived":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Archived","description":"Whether time off entry has been archived","default":false},"id":{"type":"integer","title":"Id","description":"The ID of the unavailability"},"time_created":{"type":"string","format":"date-time","title":"Time Created","description":"The time (UTC) when the unavailability was created"},"time_updated":{"type":"string","format":"date-time","title":"Time Updated","description":"The time (UTC) when the unavailability was last updated"},"time_published":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Time Published","description":"Timestamp of when the unavailability was published"},"gcal_event_ids":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Gcal Event Ids","description":"Google Calendar event IDs associated with the unavailability"},"approved":{"type":"boolean","title":"Approved","readOnly":true}},"type":"object","required":["end","person_id","start","unavailability_type_id","id","time_created","time_updated","approved"],"title":"UnavailabilityResponse"},"UnavailabilityTypeLazyRead":{"properties":{"id":{"type":"integer","title":"Id","description":"The unavailability type id"},"name":{"type":"string","title":"Name","description":"Name of the leave type"},"external_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"External Id","description":"External ID for the leave type"},"has_allowance":{"type":"boolean","title":"Has Allowance","description":"Whether allowance is needed","default":false},"default_allowance":{"type":"number","title":"Default Allowance","description":"Default allowance for this leave type in hours","default":64},"included_in_hours":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Included In Hours","description":"Whether this unavailability type is included in hours","default":true},"enabled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Enabled","description":"Whether this unavailability type is enabled","default":true}},"type":"object","required":["id","name"],"title":"UnavailabilityTypeLazyRead"},"UploadTickets":{"properties":{"tickets":{"items":{"$ref":"#/components/schemas/BaseTicket"},"type":"array","title":"Tickets"},"train_model":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Train Model","default":true},"convert_to_timeseries":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Convert To Timeseries","default":true},"lookback_days":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Lookback Days","default":720}},"type":"object","required":["tickets"],"title":"UploadTickets"},"UserMessageInput":{"properties":{"content":{"type":"string","title":"Content"},"attachments":{"anyOf":[{"items":{"additionalProperties":true,"type":"object"},"type":"array"},{"type":"null"}],"title":"Attachments"},"thread_id":{"type":"integer","title":"Thread Id"},"model":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Model","default":"anthropic/claude-sonnet-4"},"agent_type":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Agent Type"},"view_context":{"anyOf":[{"$ref":"#/components/schemas/ViewContext"},{"type":"null"}]},"channel":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Channel"},"subject":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Subject"}},"type":"object","required":["content","thread_id"],"title":"UserMessageInput"},"ValidationError":{"properties":{"loc":{"items":{"anyOf":[{"type":"string"},{"type":"integer"}]},"type":"array","title":"Location"},"msg":{"type":"string","title":"Message"},"type":{"type":"string","title":"Error Type"},"input":{"title":"Input"},"ctx":{"type":"object","title":"Context"}},"type":"object","required":["loc","msg","type"],"title":"ValidationError"},"ValidationIn":{"properties":{"person_id":{"type":"integer","title":"Person Id"},"start":{"type":"string","format":"date-time","title":"Start"},"end":{"type":"string","format":"date-time","title":"End"},"shifts":{"anyOf":[{"items":{"$ref":"#/components/schemas/OverrideShift"},"type":"array"},{"type":"null"}],"title":"Shifts"},"unavailabilities":{"anyOf":[{"items":{"$ref":"#/components/schemas/OverrideTimeOff"},"type":"array"},{"type":"null"}],"title":"Unavailabilities","default":[]}},"type":"object","required":["person_id","start","end"],"title":"ValidationIn","description":"Shifts or unavailabilities to check between start and end.\n\nUnavailability checks always run. Omitting unavailabilities validates with no time off.\nSchedule checks run as well when shifts are sent and the person has self_scheduling\non an enabled ruleset."},"ValueMetadataItem":{"properties":{"duration":{"type":"number","title":"Duration","description":"Duration in hours that this pay rule applies to (e.g. shift hours or activity hours, depending on rule)"},"cost":{"type":"number","title":"Cost","description":"Cost/payment amount for this duration"},"count":{"type":"integer","title":"Count","description":"Number of tickets that apply to this shift for this pay rule","default":0},"tickets":{"anyOf":[{"items":{"$ref":"#/components/schemas/TicketInMetadata"},"type":"array"},{"type":"null"}],"title":"Tickets","description":"Full ticket objects with payment values (optional, for timesheets display)"},"start":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Start","description":"Start time of the period over which this rule was applied"},"end":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"End","description":"End time of the period over which this rule was applied"}},"type":"object","required":["duration","cost"],"title":"ValueMetadataItem","description":"Represents the contribution of a single pay rule to the total timesheet value."},"ViewContext":{"properties":{"timezone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Timezone"},"component_id":{"anyOf":[{"type":"string"},{"type":"integer"},{"type":"null"}],"title":"Component Id"},"active_filters":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Active Filters"}},"type":"object","title":"ViewContext","description":"Context information about the current view the user has open in the UI."},"Workflow":{"properties":{"name":{"type":"string","title":"Name","description":"Short label for the procedure"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"The procedure itself, as markdown; goes into the assistant's system prompt"},"access_levels":{"items":{"type":"string"},"type":"array","title":"Access Levels","description":"Access levels offered this workflow (admin | manager | staff | view_only); empty = nobody, i.e. still being built","default":[]},"enabled":{"type":"boolean","title":"Enabled","description":"Whether the assistant is offered this workflow at all","default":false},"id":{"type":"integer","title":"Id","description":"Unique identifier for the workflow"},"organisation_id":{"type":"integer","title":"Organisation Id","description":"ID of the organization this workflow belongs to"},"archived":{"type":"boolean","title":"Archived","description":"Whether this workflow is archived"},"is_default":{"type":"boolean","title":"Is Default","description":"The org's default procedure, followed when no other one matches; cannot be disabled or deleted","default":false},"tools":{"items":{"$ref":"#/components/schemas/WorkflowTool"},"type":"array","title":"Tools","description":"Tools this workflow adds to the assistant","default":[]},"time_created":{"type":"string","format":"date-time","title":"Time Created","description":"Timestamp of when the workflow was created"},"time_updated":{"type":"string","format":"date-time","title":"Time Updated","description":"Timestamp of when the workflow was last updated"}},"type":"object","required":["name","id","organisation_id","archived","time_created","time_updated"],"title":"Workflow"},"WorkflowNew":{"properties":{"name":{"type":"string","title":"Name","description":"Short label for the procedure"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"The procedure itself, as markdown; goes into the assistant's system prompt"},"access_levels":{"items":{"type":"string"},"type":"array","title":"Access Levels","description":"Access levels offered this workflow (admin | manager | staff | view_only); empty = nobody, i.e. still being built","default":[]},"enabled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Enabled","description":"Whether the assistant is offered this workflow at all","default":false}},"type":"object","required":["name"],"title":"WorkflowNew"},"WorkflowOptional":{"properties":{"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name","description":"Short label for the procedure"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"The procedure itself, as markdown; goes into the assistant's system prompt"},"access_levels":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Access Levels","description":"Access levels offered this workflow (admin | manager | staff | view_only); empty = nobody, i.e. still being built","default":[]},"enabled":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Enabled","description":"Whether the assistant is offered this workflow at all","default":false},"id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Id","description":"Unique identifier for the workflow"},"organisation_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Organisation Id","description":"ID of the organization this workflow belongs to"},"archived":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Archived","description":"Whether this workflow is archived"},"is_default":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Is Default","description":"The org's default procedure, followed when no other one matches; cannot be disabled or deleted","default":false},"tools":{"anyOf":[{"items":{"$ref":"#/components/schemas/WorkflowTool"},"type":"array"},{"type":"null"}],"title":"Tools","description":"Tools this workflow adds to the assistant","default":[]},"time_created":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Time Created","description":"Timestamp of when the workflow was created"},"time_updated":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Time Updated","description":"Timestamp of when the workflow was last updated"}},"type":"object","title":"WorkflowOptional"},"WorkflowRun":{"properties":{"workflow_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Workflow Id","description":"Workflow that described these messages; null if none did"},"thread_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Thread Id","description":"Thread this stretch began in; a stretch may span several"},"message_ids":{"items":{"type":"integer"},"type":"array","title":"Message Ids","description":"Messages assigned to this workflow, across whatever threads they arrived on","default":[]},"scored_through_message_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Scored Through Message Id","description":"Latest message considered when this was last scored"},"adherence":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Adherence","description":"How closely the procedure was followed, 1-10; null when no workflow matched"},"rationale":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Rationale","description":"Why the classifier gave that score"},"id":{"type":"integer","title":"Id","description":"Unique identifier for the run"},"organisation_id":{"type":"integer","title":"Organisation Id","description":"ID of the organization this run belongs to"},"person_id":{"type":"integer","title":"Person Id","description":"Person whose conversation this stretch belongs to"},"time_created":{"type":"string","format":"date-time","title":"Time Created","description":"Timestamp of when the run was recorded"},"time_updated":{"type":"string","format":"date-time","title":"Time Updated","description":"Timestamp of when the run was last updated"}},"type":"object","required":["id","organisation_id","person_id","time_created","time_updated"],"title":"WorkflowRun"},"WorkflowRunMessage":{"properties":{"id":{"type":"integer","title":"Id","description":"Message id, as it appears in the run's message_ids"},"role":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Role","description":"user or assistant"},"content":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Content","description":"Message text"},"thread_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Thread Id","description":"Thread this message arrived on"},"channel":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Channel","description":"chat, sms, email, slack"},"time_created":{"type":"string","format":"date-time","title":"Time Created","description":"When the message was sent"}},"type":"object","required":["id","time_created"],"title":"WorkflowRunMessage","description":"One message belonging to a run. A run can span threads and channels, so both are\non every line."},"WorkflowTool":{"properties":{"name":{"type":"string","title":"Name","description":"Tool name shown to the model; snake_case, unique within the org"},"description":{"type":"string","title":"Description","description":"What the tool does, as the model reads it"},"parameters":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Parameters","description":"JSON schema for the tool's arguments"},"code":{"type":"string","title":"Code","description":"Python run on the agent sandbox; sees each parameter as a variable and assigns `result`"},"id":{"type":"integer","title":"Id","description":"Unique identifier for the tool"},"workflow_id":{"type":"integer","title":"Workflow Id","description":"ID of the workflow that owns this tool"},"organisation_id":{"type":"integer","title":"Organisation Id","description":"ID of the organization this tool belongs to"},"archived":{"type":"boolean","title":"Archived","description":"Whether this tool is archived"},"time_created":{"type":"string","format":"date-time","title":"Time Created","description":"Timestamp of when the tool was created"},"time_updated":{"type":"string","format":"date-time","title":"Time Updated","description":"Timestamp of when the tool was last updated"}},"type":"object","required":["name","description","code","id","workflow_id","organisation_id","archived","time_created","time_updated"],"title":"WorkflowTool"},"WorkflowToolNew":{"properties":{"name":{"type":"string","title":"Name","description":"Tool name shown to the model; snake_case, unique within the org"},"description":{"type":"string","title":"Description","description":"What the tool does, as the model reads it"},"parameters":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Parameters","description":"JSON schema for the tool's arguments"},"code":{"type":"string","title":"Code","description":"Python run on the agent sandbox; sees each parameter as a variable and assigns `result`"}},"type":"object","required":["name","description","code"],"title":"WorkflowToolNew"},"WorkflowToolOptional":{"properties":{"name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Name","description":"Tool name shown to the model; snake_case, unique within the org"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"What the tool does, as the model reads it"},"parameters":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Parameters","description":"JSON schema for the tool's arguments"},"code":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Code","description":"Python run on the agent sandbox; sees each parameter as a variable and assigns `result`"},"id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Id","description":"Unique identifier for the tool"},"workflow_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Workflow Id","description":"ID of the workflow that owns this tool"},"organisation_id":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Organisation Id","description":"ID of the organization this tool belongs to"},"archived":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Archived","description":"Whether this tool is archived"},"time_created":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Time Created","description":"Timestamp of when the tool was created"},"time_updated":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Time Updated","description":"Timestamp of when the tool was last updated"}},"type":"object","title":"WorkflowToolOptional"}},"securitySchemes":{"HTTPBearer":{"type":"http","scheme":"bearer"}}}}