---
title: "Create Authentication Flow"
method: POST
path: "/v1/applications/{applicationId}/auth-flows"
tags: ["Applications"]
---

# Create Authentication Flow

`POST /v1/applications/{applicationId}/auth-flows`

## Request

- Base URL: `https://api.anchorbrowser.io`
- URL: `https://api.anchorbrowser.io/v1/applications/{applicationId}/auth-flows`
- Auth: API key in header `anchor-api-key`

Creates a new authentication flow for an application.

## Path parameters

- `applicationId` string, uuid, required

## Request body

- CreateAuthFlowRequest
  - `name` string, required: Name of the authentication flow
  - `description` string: Description of the authentication flow
  - `is_recommended` boolean: Whether this is the recommended authentication flow
  - `methods` string[], required: Authentication methods in this flow
  - `custom_fields` CustomFieldDefinition[]: Custom fields for this authentication flow
    - `name` string, required: Name of the custom field

## Response `201`

authentication flow created successfully

- CreateAuthFlowResponse
  - `id` string, uuid: Unique identifier for the authentication flow
  - `name` string: Name of the authentication flow
  - `description` string, nullable: Description of the authentication flow
  - `is_recommended` boolean: Whether this is the recommended authentication flow
  - `methods` string[]: Authentication methods in this flow
  - `custom_fields` CustomFieldDefinition[]: Custom fields for this authentication flow
    - `name` string, required: Name of the custom field
  - `created_at` string, date-time: Timestamp when the authentication flow was created
  - `updated_at` string, date-time: Timestamp when the authentication flow was last updated

## Other responses

- `400`: Invalid request parameters
- `500`: Failed to create authentication flow

---

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