---
title: "Create a new subaccount for an entity"
method: POST
path: "/v1/{id}/accounts"
tags: ["Entity Endpoints"]
---

# Create a new subaccount for an entity

`POST /v1/{id}/accounts`

## Request

- Base URL: `https://api.carbonregistry.com`
- URL: `https://api.carbonregistry.com/v1/{id}/accounts`
- Auth: HTTP bearer
- TypeScript: <https://skmtc.dev/carbonregistry/apis/carbonregistry-api/docs/v1/:id/accounts/post.ts> (a function with typed inputs; its response is checked against the schema)

## Path parameters

- `id` string, required

## Request body

- EntityCreateSubAccountRequestDto
  - `name` string, required: The name associated with this subaccount

## Response `200`

- EntityCreateSubAccountResponseDto
  - `account` SubAccountDto, required
    - `id` string, required: The id of this subaccount
    - `type` 'default' | 'subAccount', required: The type of subaccount
    - `name` string, required: The name of the subaccount
    - `address` string, required: The onchain address for this subaccount
    - `ownerId` string, required: The id of the entity that owns this subaccount

---

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