v5

latestOpenAPI 3.1.02026-08-0456189324.9 KB
Use Cases

Upsert Group And Usecases

Create or update a UseCaseGroup and REPLACE its use-case configs with the provided list in one call.

  • If payload.group_id is provided, update the existing group; otherwise create a new one.
  • The set of configs under the group will be made to exactly match payload.use_cases. • If payload.use_cases is empty, all existing configs for the group are deleted.
post/integrations/v1/integrations/{integration}/use-case-groups

Path parameters

integration'microsoft' | 'google' required

Request body

namestring required

Human friendly group name

slugstring nullable

Optional explicit slug; if omitted will be generated

sheet_linkstring nullable

Associated sheet link for this group

assistant_idstring nullable

Assistant identifier bound to this group

timezonestring nullable

Timezone identifier e.g. America/Chicago

start_timestring time nullable

Time of day to run the use-case group (HH:MM:SS)

group_idstring nullable

If provided, updates the existing group; otherwise creates a new group

Example request

{
  "assistant_id": "68a8652f82513625d1c21a85",
  "name": "Appointment Reminders",
  "sheet_link": "https://1drv.ms/x/...",
  "start_time": "08:00:00",
  "timezone": "America/Chicago",
  "use_cases": [
    {
      "actions": [
        {
          "action_type": "SMS",
          "context": "reminder_7d",
          "day": 7,
          "template_name": "First SMS"
        },
        {
          "action_type": "CALL",
          "context": "reminder_1d",
          "day": 1,
          "template_name": "Day 1 Call"
        }
      ],
      "enabled": true,
      "use_case": "NEW_PATIENT_APPOINTMENT_REMINDER"
    },
    {
      "actions": [
        {
          "action_type": "SMS",
          "context": "lab_result_sms",
          "day": 0,
          "template_name": "Lab Result SMS"
        }
      ],
      "enabled": true,
      "use_case": "LAB_REMINDER"
    }
  ]
}

Response

Successful Response

{"stackTrail":"paths:/integrations/v1/integrations/{integration}/use-case-groups:post:responses:200:content:application/json:schema","oasType":"schema","type":"unknown"}