---
title: "Authenticate with password"
method: POST
path: "/accounts/auth-with-password"
tags: ["Authentication"]
---

# Authenticate with password

`POST /accounts/auth-with-password`

Authenticates a user with their email and password. If MFA is enabled, returns an MFA token that must be used with a subsequent authentication request.

## Request body

- AuthWithPasswordRequest
  - `account` string — Account name (optional). If not provided and the user is a root user, their root account will be used.
  - `email` string, email, required — User's email address
  - `password` string, password, required — User's password

## Response `200`

Authentication successful or MFA required

- object
  - `data` union, required
    - AuthResponse
      - `refresh_token` string — Refresh token
      - `auth_token` string — Authentication token
      - `passkey_enabled` boolean — Whether passkey authentication is enabled
      - `totp_enabled` boolean — Whether TOTP authentication is enabled
    - MfaRequiredResponse
      - `token` string — MFA token
      - `passkey_enabled` boolean — Whether passkey authentication is enabled
      - `totp_enabled` boolean — Whether TOTP authentication is enabled

## Other responses

- `401` — Authentication failed

---

[API](https://skmtc.net/quivaworks/apis/quiva-ai-gateway.md) · [All operations](https://skmtc.net/quivaworks/apis/quiva-ai-gateway/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/quivaworks/quiva-ai-gateway/revisions/771d118bd4d1/schema)
