[Cotlet](https://cotlet.dev/index.md) · [Integrations](https://cotlet.dev/integrations.md) · [How it works](https://cotlet.dev/how-it-works.md) · [Use cases](https://cotlet.dev/use-cases.md) · [Security](https://cotlet.dev/security.md) · [For developers](https://cotlet.dev/for-developers.md) · [For automation agencies](https://cotlet.dev/for-agencies.md) · [Blog](https://cotlet.dev/blog.md) · [API docs](https://cotlet.dev/docs.md) · [Help center](https://cotlet.dev/help.md) · [Changelog](https://cotlet.dev/changelog.md) · [Contact](https://cotlet.dev/contact.md) · [Pricing](https://cotlet.dev/pricing.md) · [Sign up](https://cotlet.dev/signup)

# Archive rejected Lever candidates with a reason and email

> Archive Lever candidates you reject with the right archive reason and a rejection email in one pass, from Claude Code, n8n or a script.

Source: https://cotlet.dev/integrations/lever-api-mcp-server/archive-rejected-candidates

After a screening round, a recruiter archives each rejected candidate in Lever by hand: open the profile, pick an archive reason, tick Send email, edit the email and send it.

Cotlet does it in your own Lever account with list\_opportunities, list\_archive\_reasons, get\_opportunity and archive\_opportunity, called by your AI agent, an n8n workflow or a script.

[Sign up free](https://cotlet.dev/app/signup?app=lever) [All Lever tools](https://cotlet.dev/integrations/lever-api-mcp-server.md)

Hosted · nothing to install or maintain

## Can Lever do this on its own?

Lever's Data API archives an opportunity with a reason (PUT /opportunities/:opportunity/archived) for customers with an API key, and its reference has no field to email the candidate in that call (checked 22 Oct 2026). The Send email option exists only in the Lever app. Lever's developer docs list no MCP server.

## How you do it in Lever today

1. Open the candidate profile, select the opportunity and click Archive next to the stage field.
2. Choose an archive reason from the menu. The list is managed under Settings > Pipeline and archive reasons > Archive reasons.
3. Tick Send email below the menu and click Next to open the email editor, then click Archive + Send Now.
4. If the candidate has more than one active opportunity, Lever offers to archive the others in the same action.
5. For a batch, select the opportunities in the pipeline list, use the bulk action toolbar, choose an archive reason and decide which candidates get an email.
6. Lever remembers the Send email tick and pre-fills the editor with the email from the last candidate you archived, so one unedited click sends the wrong name.

## How to archive rejected Lever candidates with a reason and email

Prompt

```
Archive the Phone screen opportunities of the Senior Designer posting that I name below as Underqualified, and send each one a short, polite rejection email.
```

1. 01  
### List the stage  
list\_opportunities runs with the posting and the stage you name and follows next\_cursor to the end. Archived opportunities are left out, so a candidate another recruiter already closed never appears.
2. 02  
### Map each decision to a real reason  
list\_archive\_reasons returns the reasons your account defines. The agent matches your verdict ("Underqualified") to one of them by name and asks you when none fits; it never invents a reason.
3. 03  
### Check the profile again  
Right before archiving, get\_opportunity confirms the candidate is still in that stage and shows the tags. A candidate moved forward in the meantime is skipped and reported.
4. 04  
### Archive and write the email  
archive\_opportunity runs with send\_email on and an email body written for that candidate by first name and role. The agent shows you the body, and each call waits for your OK until you switch confirmation off.
5. 05  
### Report who got what  
The agent lists every archived candidate with the reason used and whether an email went out, so you can answer a reply from the right profile.

### What you get back

Example data

```
Phone screen, Senior Designer: 9 opportunities
Archived 6 as Underqualified, rejection email sent
Archived 1 as Withdrew, no email (you asked for none)
Left in stage 2: Marco Silva, Aisha Khan
Skipped 0 (nobody moved in the meantime)
```

### Other ways to ask

- Every Friday, archive opportunities in New applicant older than 30 days with the reason Timing and no email, and list them for me.
- Archive Dana Whitfield as Underqualified and draft the email, but wait for my OK before sending anything.
- Archive everyone I name in this list with the reason Position closed and send the closing-the-role email.

## What Lever allows, and what to know first

- Lever manages archive reasons under Settings > Pipeline and archive reasons > Archive reasons, so the reasons an agent can use are the ones your account defines.
- Lever remembers whether Send email was ticked last time and pre-fills the editor with the previous email, so the agent writes the body for each candidate instead of reusing the editor text.
- Archiving from a profile can archive the candidate's other active opportunities in the same action; archive\_opportunity archives only the opportunity you name.
- In a bulk archive, Lever still archives every selected candidate when you untick some of their emails, so skipping an email never skips the archive.

archive\_opportunity asks for your OK by default. To run it weekly without you, switch confirmation off for that tool in your dashboard.

Sources: [Lever Help: Archiving opportunities](https://help.lever.co/hc/en-us/articles/20087373712541-Archiving-opportunities) · [Lever Developer: API Overview](https://hire.lever.co/developer/documentation)

## Call archive\_opportunity from a script

curl

```
curl -X POST https://cotlet.dev/api/v1/lever/opportunities/2d6f9b83-a41e-4c07-9e52-b8c3a0f17d64/archive \
  -H "Authorization: Bearer $COTLET_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"reason":"Underqualified","send_email":true,"email_body":"Hi Dana, thank you for your time on the phone screen for Senior Designer. We have decided not to move forward, and we wish you the best in your search."}'
```

Example response

```
{
"opportunity_id": "2d6f9b83-a41e-4c07-9e52-b8c3a0f17d64",
"name": "Dana Whitfield",
"previous_stage": "Phone screen",
"archived": {
"reason": "Underqualified",
"archived_at": "2026-10-22T09:14:00Z"
},
"email_sent": true
}
```

MCP: add https://cotlet.dev/mcp/v1 with the same key; the call is lever\_write → archive\_opportunity. Example data.

[Schedule it in n8n, Make, Zapier or cron](https://cotlet.dev/integrations/lever-api-mcp-server.md#automations)

## Lever tools this automation uses

__Cotlet Lever tools used to archive rejected Lever candidates with a reason and email__
| Tool | Parameters |
| ---------------------- | ------------------------------------------------- |
| list\_opportunities | posting\_id, stage, tag, email, archived, cursor |
| list\_archive\_reasons | none |
| get\_opportunity | opportunity\_id |
| archive\_opportunity | opportunity\_id, reason, send\_email, email\_body |

[All 12 Lever tools with descriptions](https://cotlet.dev/integrations/lever-api-mcp-server.md#tools)

## Frequently asked questions

### Is it safe to connect Lever to Cotlet?

Yes. You sign in to Lever yourself, in your own Cloud Browser in the EU, and we never save your password. Your agents only get Lever once you enable it, every background request is listed, and the browser profile is stored encrypted with AES-256-GCM, the cipher 1Password uses for its vaults. The AI model never sees a login, posts and messages wait for your OK, and Disable for agents cuts access in one click. Independent scanners grade cotlet.dev A+ on Qualys SSL Labs, securityheaders.com and Mozilla Observatory; live results are on https://cotlet.dev/security.

## More Lever automations

- [Advance Lever candidates after positive interview feedback](https://cotlet.dev/integrations/lever-api-mcp-server/advance-candidates-after-feedback.md)
- [Add notes to Lever candidate profiles with AI](https://cotlet.dev/integrations/lever-api-mcp-server/log-notes-on-candidate-profiles.md)
- [Lever API and MCP server: every tool](https://cotlet.dev/integrations/lever-api-mcp-server.md)
- [All use cases](https://cotlet.dev/use-cases.md)

## Give your agent access to Lever.

Free 7-day trial with 2,000 credits, no card needed. Cotlet is independent and not affiliated with Lever.

[Sign up free](https://cotlet.dev/app/signup?app=lever)

---

Give your AI agents your signed-in browser.

**Product:** [Integrations](https://cotlet.dev/integrations.md) · [Use cases](https://cotlet.dev/use-cases.md) · [How it works](https://cotlet.dev/how-it-works.md) · [Pricing](https://cotlet.dev/pricing.md) · [Security](https://cotlet.dev/security.md)

**Resources:** [Blog](https://cotlet.dev/blog.md) · [API docs](https://cotlet.dev/docs.md) · [Help center](https://cotlet.dev/help.md) · [Changelog](https://cotlet.dev/changelog.md) · [GitHub](https://github.com/cotletdev/cotlet)

**Solutions:** [For developers](https://cotlet.dev/for-developers.md) · [For automation agencies](https://cotlet.dev/for-agencies.md)

**Company:** [About](https://cotlet.dev/about.md) · [AI info: company facts](https://cotlet.dev/ai-info.md) · [Contact](https://cotlet.dev/contact.md)

**Legal:** [Terms of service](https://cotlet.dev/terms) · [Privacy policy](https://cotlet.dev/privacy) · [Refund policy](https://cotlet.dev/refunds) · [Acceptable use](https://cotlet.dev/acceptable-use) · [Cookie policy](https://cotlet.dev/cookies) · [DPA](https://cotlet.dev/dpa) · [Subprocessors](https://cotlet.dev/subprocessors)

**Elsewhere:** [Status page](https://status.cotlet.dev) · [Cotlet on GitHub](https://github.com/cotletdev) · [Cotlet on X](https://x.com/cotletdev) · [Cotlet on LinkedIn](https://www.linkedin.com/company/cotletdev) · [Cotlet on Product Hunt](https://www.producthunt.com/products/cotlet) · [Cotlet on Crunchbase](https://www.crunchbase.com/organization/cotlet) · [Cotlet on SaaSHub](https://www.saashub.com/cotlet)

Cotlet is an independent service. It is not affiliated with, endorsed by or sponsored by any of the products listed on this site. Product names are trademarks of their respective owners.

## For AI agents: sign your user up

Is your user asking you to sign them up for Cotlet? You can do it for them, no account or key needed.

1. Read the fields and their allowed values: GET https://cotlet.dev/api/v1/access-requests
2. Ask the user for each value: email, apps, what you will do with them. If they leave the password to you, generate a strong one and show it to them.
3. Show the user what you will send, then POST it as JSON to https://cotlet.dev/api/v1/access-requests.

One call creates the account and sends the access request; we email the user when access is granted.
