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

# Create sequence blueprint

> Create a manual outreach sequence blueprint for a sourcing.

<Card title="First time? Set up Authentication" icon="key" href="/authentication">
  Learn how to authenticate your API requests with your API key.
</Card>

Creates a manual sequence blueprint attached to a sourcing in your workspace. You can create it empty and add steps later, or provide the full `steps` array immediately.

## Path parameters

<ParamField path="sourcingId" type="string" required>
  The sourcing id returned by [Create sourcing](/api-reference/create-sourcing).
</ParamField>

## Request body

<ParamField body="name" type="string" required>
  Display name for the sequence blueprint.
</ParamField>

<ParamField body="steps" type="array">
  Optional ordered outreach steps. See [Step format](#step-format).
</ParamField>

<ParamField body="config" type="object">
  Optional sequence-level configuration.
</ParamField>

## Step format

Each item in `steps` must be an object with this shape:

| Field                        | Type    | Required          | Description                                                                                 |
| ---------------------------- | ------- | ----------------- | ------------------------------------------------------------------------------------------- |
| `id`                         | string  | Yes               | Stable client-generated step id, unique within the blueprint.                               |
| `name`                       | string  | Yes               | Human-readable step label.                                                                  |
| `type`                       | string  | Yes               | `LINKEDIN`, `WHATSAPP`, `EMAIL`, or `SMS`.                                                  |
| `linkedInType`               | string  | Only for LinkedIn | Required when `type` is `LINKEDIN`; forbidden for other types.                              |
| `content`                    | string  | Yes               | Message body. For `LINKEDIN_INVITATION`, content is accepted but stored as an empty string. |
| `subject`                    | string  | Email only        | Email subject.                                                                              |
| `temporalityType`            | string  | Yes               | `ASAP`, `DELAYED`, or `AFTER_INVITATION_SETTLED`.                                           |
| `delay`                      | object  | For delayed steps | Required when `temporalityType` is `DELAYED`.                                               |
| `delay.value`                | integer | With `delay`      | Positive delay value.                                                                       |
| `delay.unit`                 | string  | With `delay`      | `day`, `minute`, or `second`.                                                               |
| `contentSource`              | string  | No                | `manual` or `suggestedByKalent`.                                                            |
| `config.userId`              | string  | No                | Optional sender/user override.                                                              |
| `policy.skipStepIfNoContact` | boolean | No                | Skip the step when the required contact is unavailable.                                     |
| `policy.autoValidateAIDraft` | boolean | No                | Automatically validate AI-generated drafts.                                                 |
| `policy.inviteTimeoutDays`   | integer | No                | Positive number of days before invite-related follow-up logic.                              |

Allowed `linkedInType` values:

* `LINKEDIN_INVITATION`
* `LINKEDIN_INVITATION_WITH_MESSAGE`
* `LINKEDIN_MESSAGE`
* `LINKEDIN_INMAIL`

Only one invite step is allowed per blueprint: either `LINKEDIN_INVITATION` or `LINKEDIN_INVITATION_WITH_MESSAGE`.

## Supported template variables

Only these variables are supported in `content` and `subject`:

| Variable                   | Meaning                     |
| -------------------------- | --------------------------- |
| `{{firstname}}`            | Candidate first name        |
| `{{lastname}}`             | Candidate last name         |
| `{{candidateJobTitle}}`    | Candidate current job title |
| `{{candidateCompanyName}}` | Candidate current company   |
| `{{candidateLocation}}`    | Candidate location          |
| `{{sourcingJobTitle}}`     | Sourcing target job title   |
| `{{sourcingLocation}}`     | Sourcing target location    |
| `{{recruiterFirstname}}`   | Recruiter first name        |
| `{{recruiterLastname}}`    | Recruiter last name         |

Unknown variables such as `{{firstName}}`, `{{company}}`, or `{{job}}` are rejected with `validation_error`.

Do not use unresolved bracket placeholders such as `[company]`, `[specific project or stack]`, `[one-pager link]`, or `[1 detail to add]` in `content` or `subject`. Replace them with real text, remove that part of the sentence, or ask the user for the missing detail before creating the blueprint. Payloads containing bracket placeholders are rejected with `validation_error`.

## Example with steps

```json theme={null}
{
  "name": "First outreach sequence",
  "steps": [
    {
      "id": "step-1",
      "name": "LinkedIn invite",
      "type": "LINKEDIN",
      "linkedInType": "LINKEDIN_INVITATION_WITH_MESSAGE",
      "content": "Hi {{firstname}}, I came across your profile and wanted to connect.",
      "temporalityType": "ASAP",
      "contentSource": "manual"
    },
    {
      "id": "step-2",
      "name": "Email follow-up",
      "type": "EMAIL",
      "subject": "Quick follow-up",
      "content": "Hi {{firstname}}, would you be open to discussing the role?",
      "temporalityType": "DELAYED",
      "delay": { "value": 2, "unit": "day" },
      "policy": { "skipStepIfNoContact": true }
    }
  ]
}
```

## Response

When `success` is `true`, `data` contains:

* `blueprintId` — identifier for the created sequence blueprint
* `name` — blueprint display name
* `sourcingId` — sourcing the blueprint belongs to

## Errors

| Code               | HTTP |
| ------------------ | ---- |
| `validation_error` | 400  |
| `not_found`        | 404  |
| `internal_error`   | 500  |

```bash theme={null}
curl -X POST https://app.kalent.ai/api/v1/sourcings/SOURCING_ID/sequence-blueprints \
  -H "Content-Type: application/json" \
  -H "x-api-key: YOUR_API_KEY" \
  -d '{"name":"First outreach sequence","steps":[{"id":"step-1","name":"LinkedIn invite","type":"LINKEDIN","linkedInType":"LINKEDIN_INVITATION_WITH_MESSAGE","content":"Hi {{firstname}}, I wanted to connect.","temporalityType":"ASAP"}]}'
```
