---
title: Create Security Check
description: "Runs a DeepSec Security Check of your v0 app. To check an app that isn't in v0 yet, pass its GitHub repository or Vercel project, and v0 imports it into a new private chat. Poll GET /chats/:chatId/security-checks/:checkId for the result. Requires a user API key."
docs_index: /docs/llms.txt
lastUpdated: 2026-11-27
badge: "POST"
---

> For an index of all documentation, see [/docs/llms.txt](/docs/llms.txt).

Runs a DeepSec Security Check of your v0 app. To check an app that isn't in v0 yet, pass its GitHub repository or Vercel project, and v0 imports it into a new private chat. Poll GET /chats/:chatId/security-checks/:checkId for the result. Requires a user API key.

#### `POST /v2/security-checks/`

## Usage

```typescript
import { v0 } from 'v0'

const result = await v0.securityChecks.create({
  scope: 'project',
})

console.log(result)
```

```bash
curl -X POST "https://api.v0.dev/v2/security-checks/"   -H "Authorization: Bearer $V0_API_KEY"   -H "Content-Type: application/json"   -d '{"scope":"project"}'
```

## API Signature

### Request

#### Request Body

- `scope: 'project' | 'changes'` `changes`: what changed in the chat. `project`: the riskiest files across the app.
- `chatId?: string` The v0 chat to check.
  - **Minimum length:** 1
- `repo?: object` A GitHub repository to import and check. Requires scope `project`.
  - `url: string` GitHub repository URL, for example [https://github.com/vercel/next.js](https://github.com/vercel/next.js).
    - **Minimum length:** 1
  - `branch?: string` Branch to import. If omitted, v0 uses the repository default branch.
    - **Maximum length:** 250
- `vercelProjectId?: string` A Vercel project to import and check. Requires scope `project`.
  - **Minimum length:** 32
  - **Maximum length:** 32
- `baseBranch?: string` Base branch for a GitHub-linked project. Defaults to the repository default branch. Ignored for projects without a GitHub link.
  - **Minimum length:** 1
  - **Maximum length:** 250

### Response

- `id: string` The Security Check ID. Poll GET /chats/:chatId/security-checks/:checkId for its status and findings.
- `object: 'security_check'`
- `chatId: string`
- `scope: 'project' | 'changes'` `changes`: what changed in the chat. `project`: the riskiest files across the app.
- `status: 'running'`

---

For a semantic overview of all documentation, see [/docs/sitemap.md](/docs/sitemap.md)

For an index of all available documentation, see [/docs/llms.txt](/docs/llms.txt)

For agent-facing discovery, including API and MCP surfaces, see [/docs/agents.md](/docs/agents.md)