---
title: "Create an end-user account"
method: POST
path: "/v2/{tenant_slug}/enduseraccounts"
tags: ["End User Accounts"]
---

# Create an end-user account

`POST /v2/{tenant_slug}/enduseraccounts`

## Request

- Base URL: `https://api.demo-retail.urbanfox.io`
- URL: `https://api.demo-retail.urbanfox.io/v2/{tenant_slug}/enduseraccounts`
- Auth: OAuth 2
  - Client credentials
  - Token URL: `https://api.demo-retail.urbanfox.io/v2/oauth/token` scopes: `create:enduseraccount`
- TypeScript: <https://skmtc.dev/urbanfox/apis/urbanfox-customer-api/docs/v2/:tenant_slug/enduseraccounts/post.ts> (a function with typed inputs; its response is checked against the schema)

Create an end-user account for a tenant.

## Path parameters

- `tenant_slug` string, required: Tenant DNS slug (lowercase letters, digits, and hyphens; 3-100 characters).

## Request body

- EndUserAccountPostRequestModel
  - `tenant_id` string, uuid, required: Identifier of the tenant that owns this account
  - `website_account_id` string: Identifier of the end user's website account; defaults to `UNKNOWN` when the account cannot be resolved
  - `crm_account_id` string, nullable: Optional identifier linking this account to a record in the tenant's CRM system
  - `is_blocked` boolean: True when the account is blocked from accessing services
  - `is_quarantined` boolean: True when the account is quarantined pending manual review
  - `is_fraudulent` boolean: True when the account has been confirmed as fraudulent
  - `last_session_updated_on` string, date-time, nullable: Time the most recent session for this account was updated (RFC 3339 / ISO 8601 UTC)

## Response `201`

Created

- APIResponseEndUserAccountResponse
  - `data` EndUserAccountResponse, required
    - `tenant_id` string, uuid, required: Identifier of the tenant that owns this account
    - `website_account_id` string, required: Identifier of the end user's website account
    - `crm_account_id` string, nullable: Optional identifier linking this account to a record in the tenant's CRM system
    - `is_blocked` boolean, required: True when the account is blocked from accessing services
    - `is_quarantined` boolean: True when the account is quarantined pending manual review
    - `is_fraudulent` boolean: True when the account has been confirmed as fraudulent
    - `last_session_updated_on` string, date-time, nullable: Time the most recent session for this account was updated (RFC 3339 / ISO 8601 UTC)

## Other responses

- `400`: Bad Request
- `401`: Unauthorized
- `403`: Forbidden
- `409`: Conflict
- `422`: Request Validation Failed
- `500`: Internal Server Error

---

[API](https://skmtc.dev/urbanfox/apis/urbanfox-customer-api.md) - [All operations](https://skmtc.dev/urbanfox/apis/urbanfox-customer-api/llms.txt) - [OpenAPI document](https://skmtc.dev/urbanfox/apis/urbanfox-customer-api/revisions/2850fb315db8?raw)
