---
title: "Create a new capacity provider account group."
method: POST
path: "/api/v4/capacityprovideraccountgroups"
tags: ["Capacity Provider Account Group Management"]
---

# Create a new capacity provider account group.

`POST /api/v4/capacityprovideraccountgroups`

## Request

- Base URL: `https://na12.api.project44.com`
- URL: `https://na12.api.project44.com/api/v4/capacityprovideraccountgroups`
- Auth: OAuth 2
  - Client credentials
  - Token URL: `/api/v4/oauth2/token`
- TypeScript: <https://skmtc.dev/project44/apis/project44-rest-api/docs/api/v4/capacityprovideraccountgroups/post.ts> (a function with typed inputs; its response is checked against the schema)

The capacity provider account group requires a unique code and may use an optional name. The response will include a unique id that can be used to reference the capacity provider account group in other APIs.  

<br/><h4><b>Required Fields</h4></b>
<ul><li> name </li><li> code </li></ul>

## Request body

- CapacityProviderAccountGroupInfo: The details necessary to get or instantiate a new capacity provider group.
  - `code` string: The unique, user-provided code used to identify this account group. Typically, an account group will correspond to a single customer or a single customer location. Account group codes are provided in shipment lifecycle APIs to identify a particular account. This field may be provided when creating an account group but is not required when creating or updating a set of capacity provider accounts in the capacity provider account management API.
  - `id` integer: The project44-generated id of the capacity provider account group. This id may not be provided when creating a capacity provider account group, but it is required when updating one or when creating or updating a capacity provider account set.
  - `name` string: The user-provided name to be assigned to this group. This field may be provided when creating an account group but is not required when creating or updating a set of capacity provider accounts in the capacity provider account management API.

## Response `201`

Created

- CapacityProviderAccountGroupInfo: The details necessary to get or instantiate a new capacity provider group.
  - `code` string: The unique, user-provided code used to identify this account group. Typically, an account group will correspond to a single customer or a single customer location. Account group codes are provided in shipment lifecycle APIs to identify a particular account. This field may be provided when creating an account group but is not required when creating or updating a set of capacity provider accounts in the capacity provider account management API.
  - `id` integer: The project44-generated id of the capacity provider account group. This id may not be provided when creating a capacity provider account group, but it is required when updating one or when creating or updating a capacity provider account set.
  - `name` string: The user-provided name to be assigned to this group. This field may be provided when creating an account group but is not required when creating or updating a set of capacity provider accounts in the capacity provider account management API.

## Other responses

- `400`: Invalid request
- `401`: Invalid or missing credentials
- `403`: User not authorized to perform this operation

---

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