---
title: "Create a new app"
method: POST
path: "/api/v1/apps"
tags: ["Apps"]
---

# Create a new app

`POST /api/v1/apps`

Required scope - write_app. Assigning the root scope additionally requires the caller to hold the root scope.

## Request body

- PostAppReq
  - `name` string, required
  - `type` 'spa' | 's2s', required
  - `scopes` string[], required
  - `redirectUris` string[], required

## Response `201`

- object
  - `app` CreatedAppDetail
    - `id` number, required
    - `clientId` string, required
    - `name` string, required
    - `isActive` boolean, required
    - `type` 'spa' | 's2s', required
    - `redirectUris` string[], required
    - `useSystemMfaConfig` boolean, required
    - `requireEmailMfa` boolean, required
    - `requireOtpMfa` boolean, required
    - `requireSmsMfa` boolean, required
    - `allowEmailMfaAsBackup` boolean, required
    - `createdAt` string, required
    - `updatedAt` string, required
    - `deletedAt` string, nullable, required
    - `scopes` string[], required
    - `secret` string, required

## Changes

- **2025-08-13** `5ad1a47c235e` — 1 breaking, 3 info
  - removed the required property `app/allOf[subschema #2]/scopes` from the response with the `201` status
  - added `#/components/schemas/AppDetail` to the `app` response property `allOf` list for the response status `201`
  - removed `#/components/schemas/App` from the `app` response property `allOf` list for the response status `201`
  - added the required property `app/allOf[subschema #2]/secret` to the response with the `201` status
- **2025-05-07** `426c1916f602` — 5 info
  - added the required property `app/allOf[#/components/schemas/App]/allowEmailMfaAsBackup` to the response with the `201` status
  - added the required property `app/allOf[#/components/schemas/App]/requireEmailMfa` to the response with the `201` status
  - added the required property `app/allOf[#/components/schemas/App]/requireOtpMfa` to the response with the `201` status
  - added the required property `app/allOf[#/components/schemas/App]/requireSmsMfa` to the response with the `201` status
  - …1 more
- …earlier changes not shown

[Full history](https://skmtc.dev/valuemelody/apis/melody-auth-s2s-api/changes/api/v1/apps/post.md)

---

[API](https://skmtc.dev/valuemelody/apis/melody-auth-s2s-api.md) · [All operations](https://skmtc.dev/valuemelody/apis/melody-auth-s2s-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/valuemelody/melody-auth-s2s-api/revisions/2e1471620fd7/schema)
