> ## Documentation Index
> Fetch the complete documentation index at: https://docs.carelane.io/llms.txt
> Use this file to discover all available pages before exploring further.

# Workflow Templates

> Design task sequence templates for site operations

Workflow templates define sequences of tasks for operational processes like site onboarding, capability assessments, and regulatory document collection.

## What are Workflow Templates?

Workflow templates are PlanDefinition resources that define:

* Action sequences
* Task types and configurations
* Grouping and ordering
* Trigger conditions

## Workflow Types

| Type                   | Code                              | Purpose                         |
| ---------------------- | --------------------------------- | ------------------------------- |
| **Capability Survey**  | `capability-workflow`             | Assess site capabilities        |
| **Feasibility Survey** | `feasibility-workflow`            | Assess enrollment potential     |
| **Combined Survey**    | `capability-feasibility-workflow` | Both capability and feasibility |
| **Onboarding**         | `onboarding`                      | Post-approval site setup        |
| **Outline**            | `outline`                         | General workflow structure      |

## Creating a Workflow Template

<Steps>
  <Step title="Navigate to Templates">
    Go to Organization > Templates > Workflows.
  </Step>

  <Step title="Create New">
    Click "Create Workflow Template".
  </Step>

  <Step title="Select Type">
    Choose the workflow type.
  </Step>

  <Step title="Enter Details">
    Provide name and description.
  </Step>

  <Step title="Build Structure">
    Add groups and actions.
  </Step>

  <Step title="Save">
    Save the template.
  </Step>
</Steps>

## Workflow Structure

### Groups

Organize actions into logical groups:

```
Onboarding Workflow
├── Regulatory Documents
│   ├── Upload IRB Approval
│   └── Upload Site Contract
├── Training
│   └── Complete Training
└── Team Setup
    └── Invite Site Personnel
```

### Adding Groups

<Steps>
  <Step title="Add Group">
    Click "Add Group" in the editor.
  </Step>

  <Step title="Name Group">
    Provide a descriptive title.
  </Step>

  <Step title="Order">
    Arrange groups in completion sequence.
  </Step>
</Steps>

## Action Types

### Questionnaire Action

Include a data collection form:

| Setting           | Description                        |
| ----------------- | ---------------------------------- |
| **Questionnaire** | Select or create the questionnaire |
| **Required**      | Whether completion is mandatory    |
| **Instructions**  | Additional guidance                |

### Document Upload Action

Require file uploads:

| Setting         | Description                 |
| --------------- | --------------------------- |
| **Title**       | Document name               |
| **Description** | What should be uploaded     |
| **File Types**  | Allowed file formats        |
| **Required**    | Whether upload is mandatory |

### Read Information Action

Require acknowledgment of information:

| Setting                 | Description            |
| ----------------------- | ---------------------- |
| **Content**             | Information to display |
| **Link**                | External document link |
| **Acknowledgment Text** | What users confirm     |

### Member Invitation Action

Enable team member invitations:

| Setting      | Description                  |
| ------------ | ---------------------------- |
| **Roles**    | Roles that can be assigned   |
| **Required** | Minimum invitations required |

### Service Provider Selection Action

Allow provider selection:

| Setting            | Description                       |
| ------------------ | --------------------------------- |
| **Provider Types** | Types of providers to select from |
| **Required**       | Whether selection is mandatory    |

### Signature Action

Require electronic signature:

| Setting          | Description                    |
| ---------------- | ------------------------------ |
| **Document**     | What is being signed           |
| **Jurisdiction** | Signature jurisdiction options |

## Adding Actions

<Steps>
  <Step title="Select Group">
    Choose the group for the action.
  </Step>

  <Step title="Add Action">
    Click "Add Action".
  </Step>

  <Step title="Select Type">
    Choose the action type.
  </Step>

  <Step title="Configure">
    Set action-specific options.
  </Step>

  <Step title="Order">
    Arrange actions in completion order.
  </Step>
</Steps>

## Action Configuration

### Common Settings

| Setting          | Description            |
| ---------------- | ---------------------- |
| **Title**        | Action display name    |
| **Description**  | What needs to be done  |
| **Instructions** | Detailed guidance      |
| **Required**     | Mandatory vs. optional |

### Allowed Actions by Workflow Type

| Workflow Type   | Allowed Actions  |
| --------------- | ---------------- |
| **Capability**  | Questionnaire    |
| **Feasibility** | Questionnaire    |
| **Combined**    | Questionnaire    |
| **Onboarding**  | All action types |
| **Outline**     | Questionnaire    |

## Review Configuration

Configure how completions are reviewed:

| Setting             | Options              |
| ------------------- | -------------------- |
| **Review Required** | Yes/No               |
| **Reviewers**       | Study team roles     |
| **Auto-approve**    | For low-risk actions |

## Triggers

Configure when workflows are assigned:

### Pre-Registration Trigger

Workflow assigned when site enters registration PIN:

* Used for capability/feasibility surveys
* Completed before registration approval

### Onboarding Trigger

Workflow assigned when site is approved:

* Used for post-approval setup
* Completed before enrollment begins

## Using in Studies

<Steps>
  <Step title="Open Study Settings">
    Navigate to Study Settings > Sites.
  </Step>

  <Step title="Configure Workflows">
    Assign pre-registration and onboarding workflows.
  </Step>

  <Step title="Select Templates">
    Choose the workflow templates.
  </Step>

  <Step title="Customize if Needed">
    Modify for study-specific needs.
  </Step>
</Steps>

## Best Practices

<AccordionGroup>
  <Accordion title="Logical Ordering">
    Order actions in the sequence they should be completed.
  </Accordion>

  <Accordion title="Clear Instructions">
    Provide detailed instructions for each action.
  </Accordion>

  <Accordion title="Appropriate Requirements">
    Mark only essential actions as required.
  </Accordion>

  <Accordion title="Group Meaningfully">
    Group related actions together.
  </Accordion>
</AccordionGroup>

## Related

<CardGroup cols={2}>
  <Card title="Workflows" icon="diagram-project" href="/data-collection/workflows">
    How workflows work in operations.
  </Card>

  <Card title="Site Pathway" icon="route" href="/sites-partners/site-pathway">
    Site onboarding workflows.
  </Card>
</CardGroup>
