# Create user group

Creates a user group for the client account.

## Create user group

> Create user group.\
> Accepts account reference, name, optional description and logo, modules (at least one), and optional buyers and extensions.\
> Returns the created user group object with revision 1.

```json
{"openapi":"3.0.1","info":{"title":"Marketplace API","version":"5.0.5458-g265f20e8"},"servers":[{"url":"https://api.platform.softwareone.com"}],"paths":{"/public/v1/accounts/user-groups":{"post":{"tags":["UserGroups"],"summary":"Create user group","description":"Create user group.\nAccepts account reference, name, optional description and logo, modules (at least one), and optional buyers and extensions.\nReturns the created user group object with revision 1.","requestBody":{"description":"User group payload.","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/CreateUserGroupDto"}]}},"text/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/CreateUserGroupDto"}]}},"application/*+json":{"schema":{"allOf":[{"$ref":"#/components/schemas/CreateUserGroupDto"}]}}}},"responses":{"201":{"description":"Created","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserGroup"}}}},"400":{"description":"Bad Request","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProblemDetails"}}}}}}}},"components":{"schemas":{"CreateUserGroupDto":{"type":"object","properties":{"name":{"type":"string"},"description":{"type":"string","nullable":true},"logo":{"type":"string","nullable":true},"account":{"allOf":[{"$ref":"#/components/schemas/AccountDto"}]},"modules":{"type":"array","items":{"$ref":"#/components/schemas/ModuleDto"}},"buyers":{"type":"array","items":{"$ref":"#/components/schemas/BuyerDto"},"nullable":true},"extensions":{"type":"array","items":{"$ref":"#/components/schemas/ExtensionDto"},"nullable":true}},"additionalProperties":false},"AccountDto":{"type":"object","properties":{"id":{"type":"string","allOf":[{"pattern":"^ACC-\\d\\d\\d\\d-\\d\\d\\d\\d$"},{"pattern":"^ACC-\\d\\d\\d\\d-\\d\\d\\d\\d$"},{"pattern":"^ACC-\\d\\d\\d\\d-\\d\\d\\d\\d$"},{"pattern":"^ACC-\\d\\d\\d\\d-\\d\\d\\d\\d$"},{"pattern":"^ACC-\\d\\d\\d\\d-\\d\\d\\d\\d$"}]}},"additionalProperties":false},"ModuleDto":{"type":"object","properties":{"id":{"type":"string","allOf":[{"pattern":"^MOD-\\d\\d\\d\\d$"},{"pattern":"^MOD-\\d\\d\\d\\d$"}]}},"additionalProperties":false},"BuyerDto":{"type":"object","properties":{"id":{"pattern":"^BUY-\\d\\d\\d\\d-\\d\\d\\d\\d$","type":"string"}},"additionalProperties":false},"ExtensionDto":{"type":"object","properties":{"id":{"type":"string"}},"additionalProperties":false},"UserGroup":{"type":"object","properties":{"id":{"type":"string"},"audit":{"allOf":[{"$ref":"#/components/schemas/PlatformObjectAudit"}]},"$meta":{"allOf":[{"$ref":"#/components/schemas/PlatformMetadata"}],"nullable":true},"name":{"type":"string"},"revision":{"type":"integer","format":"int32"},"description":{"type":"string","nullable":true},"account":{"type":"object","allOf":[{"$ref":"#/components/schemas/AccountRef"}]},"modules":{"type":"array","items":{"$ref":"#/components/schemas/ModuleRef"}},"logo":{"type":"string","nullable":true},"isDefault":{"type":"boolean"},"users":{"type":"array","items":{"$ref":"#/components/schemas/UserRef"}},"extensions":{"type":"array","items":{"$ref":"#/components/schemas/PlatformObjectAuditPlatformExtension"},"nullable":true},"buyers":{"type":"array","items":{"$ref":"#/components/schemas/BuyerRef"},"nullable":true}},"additionalProperties":false},"PlatformObjectAudit":{"type":"object","properties":{"created":{"allOf":[{"$ref":"#/components/schemas/PlatformObjectEvent"}],"nullable":true},"updated":{"allOf":[{"$ref":"#/components/schemas/PlatformObjectEvent"}],"nullable":true}},"additionalProperties":false},"PlatformObjectEvent":{"type":"object","properties":{"at":{"type":"string","format":"date-time","nullable":true},"by":{"type":"object","allOf":[{"$ref":"#/components/schemas/PlatformIdentityRef"}]}},"additionalProperties":false},"PlatformIdentityRef":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"icon":{"type":"string","nullable":true},"revision":{"type":"integer","format":"int32"}},"additionalProperties":false},"PlatformMetadata":{"type":"object","properties":{"omitted":{"type":"array","items":{"type":"string"}}},"additionalProperties":false},"AccountRef":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"icon":{"type":"string","nullable":true},"revision":{"type":"integer","format":"int32"},"type":{"allOf":[{"$ref":"#/components/schemas/AccountType"}],"nullable":true},"status":{"allOf":[{"$ref":"#/components/schemas/AccountStatus"}],"nullable":true}},"additionalProperties":false},"AccountType":{"enum":["Client","Vendor","Operations"],"type":"string"},"AccountStatus":{"enum":["Active","Enabled","Disabled"],"type":"string"},"ModuleRef":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"revision":{"type":"integer","format":"int32"},"description":{"type":"string"},"filters":{"allOf":[{"$ref":"#/components/schemas/Filters"}],"nullable":true},"settings":{"allOf":[{"$ref":"#/components/schemas/ModuleSettings"}],"nullable":true}},"additionalProperties":false},"Filters":{"type":"object","properties":{"group.buyers":{"type":"array","items":{"type":"string"}}},"additionalProperties":false},"ModuleSettings":{"type":"object","properties":{"sharedAccount":{"type":"boolean","deprecated":true},"configurable":{"type":"boolean"},"default":{"type":"boolean"},"paid":{"type":"boolean"},"type":{"type":"array","items":{"type":"string"}},"obsolete":{"type":"boolean"},"eligibility":{"allOf":[{"$ref":"#/components/schemas/ModuleSettingsEligibility"}],"nullable":true}},"additionalProperties":false},"ModuleSettingsEligibility":{"type":"object","properties":{"multi":{"type":"boolean"},"single":{"type":"boolean"}},"additionalProperties":false},"UserRef":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"icon":{"type":"string","nullable":true},"revision":{"type":"integer","format":"int32"}},"additionalProperties":false},"PlatformObjectAuditPlatformExtension":{"type":"object","properties":{"id":{"type":"string"},"audit":{"allOf":[{"$ref":"#/components/schemas/PlatformObjectAudit"}],"nullable":true},"$meta":{"allOf":[{"$ref":"#/components/schemas/PlatformMetadata"}],"nullable":true},"name":{"type":"string"},"icon":{"type":"string","nullable":true},"revision":{"type":"integer","format":"int32"},"status":{"enum":["Draft","Private","Public","Deleted"],"type":"string"}},"additionalProperties":false},"BuyerRef":{"type":"object","properties":{"id":{"type":"string"},"name":{"type":"string"},"icon":{"type":"string","nullable":true},"revision":{"type":"integer","format":"int32"}},"additionalProperties":false},"ProblemDetails":{"type":"object","properties":{"type":{"type":"string","nullable":true},"title":{"type":"string","nullable":true},"status":{"type":"integer","format":"int32","nullable":true},"detail":{"type":"string","nullable":true},"instance":{"type":"string","nullable":true}},"additionalProperties":{}}}}}
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.platform.softwareone.com/developer-resources/rest-api/accounts-api/user-groups/create-user-group.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
