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

# Invite a candidate

> Invites a candidate to a job, as the dashboard's manual invite does. The candidate's live, undecided application on the job is reused; if their last one has concluded, rejected included, a new application is created and the candidate is invited again. There is no cooldown between invitations. Returns `201` when a new application was created, `200` otherwise. A job with no rounds yet returns `409` `job_not_ready`.

## Which application

An invitation reuses the candidate's application to the job only when it is undecided: not withdrawn or deleted, with no stage or a `not_started` stage, and no completed interview. Otherwise a new application is created, even when the existing one is in an `in_progress` stage, so a candidate can be invited again at once. There is no cooldown.

The response is `201` when a new application was created and `200` when an existing one was used.

A candidate whose last application to the job was rejected is invited again, on a new application. Your settings on whether rejected candidates may apply again only cover candidates who come back on their own, never an invitation you send.

A job with no rounds yet can't take invitations: the request returns `409` `job_not_ready`. Retry once the job has rounds. A closed job returns `409` `job_closed`.

## When nothing is sent

`invite_sent: false` means Alex didn't send an invitation. `skipped_reason` says why:

| `skipped_reason` | Meaning |
| - | - |
| `do_not_contact` | The candidate opted out. `application` is their live application, or `null`. |
| `already_in_progress` | The application's outreach from an earlier invitation is still running. |
| `workflow_not_started` | The job's workflow didn't start. |
| `job_not_invitable` | The job stopped taking invitations while the request ran. |
| `job_not_ready` | The job's rounds were removed while the request ran. |

`duplicate_auto_invite`, `rejected_no_reapply` and `ats_reopen_unavailable` are listed in the schema because invitations Alex starts on its own share it. An invitation sent here never returns them.

## Identifying the candidate

Send `candidate.id` for a candidate Alex already has; an email or phone in `contact` then replaces theirs. A candidate deleted in your ATS can't be invited by `id`: it returns `404`. Otherwise send `first_name`, `last_name` and, optionally, `external_id`, with an email or phone in `contact`; Alex finds the candidate by `external_id` or contact details, or creates one.

`contact.phone` must have 10 to 15 digits; any other number returns `400` `parameter_invalid`, where the earlier API dropped it. An optional field sent as `null` or a blank string, such as `contact.email: ""` or `candidate.external_id: ""`, counts as not sent.

Name the job with `job_id` or `job_external_id`, not both. `round_number` starts the candidate at that round; leave it out to start at the first.


## API Specification

The full API specification for this endpoint is available in the [documentation index](https://docs.alex.com/llms.txt).


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.