---
title: "Update Attack Challenge mode"
method: POST
path: "/v1/security/attack-mode"
tags: ["security"]
---

# Update Attack Challenge mode

`POST /v1/security/attack-mode`

## Request

- Base URL: `https://api.vercel.com`
- URL: `https://api.vercel.com/v1/security/attack-mode`
- Auth: HTTP bearer

Update the setting for determining if the project has Attack Challenge mode enabled.

## Query parameters

- `teamId` string
- `slug` string

## Request body

- union
  - object
    - `projectId` string, required
    - `attackModeEnabled` boolean, required
    - `attackModeActiveUntil` number, required
  - object
    - `projectId` string, required
    - `attackModeEnabled` boolean, required

## Response `200`

- object
  - `attackModeEnabled` false | true, required
  - `attackModeUpdatedAt` number, required

## Other responses

- `400`: One of the provided values in the request body is invalid.
- `401`: The request is not authorized.
- `403`: You do not have permission to access this resource.
- `404`
- `410`

## Changes

- **2026-07-21** `2ae10ee9d21c`: 1 info
  - added the non-success response with the status `410`
- **2026-01-22** `c12186034433`: 1 breaking, 5 warning, 1 info
  - request body became required
  - removed the request property `attackModeActiveUntil`
  - removed the request property `attackModeEnabled`
  - removed the request property `projectId`
  - …3 more
- **2025-03-19** `37b482c58c92`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/vercel/apis/vercel-api/changes/v1/security/attack-mode/post.md)

---

[API](https://skmtc.dev/vercel/apis/vercel-api.md) - [All operations](https://skmtc.dev/vercel/apis/vercel-api/llms.txt) - [OpenAPI document](https://skmtc.dev/vercel/apis/vercel-api/revisions/60686c0e1f6a?raw)
