> ## Documentation Index
> Fetch the complete documentation index at: https://docs.bouncy.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Create Group

> Create a new group to organize your links

## Request

### Headers

<ParamField header="Content-Type" type="string" required>
  Must be `application/json`
</ParamField>

### Body

<ParamField body="name" type="string" required>
  Name of the group

  **Example:** `Summer Campaign 2026`
</ParamField>

## Response

<ResponseField name="id" type="string">
  Unique identifier for the group
</ResponseField>

<ResponseField name="name" type="string">
  Group name
</ResponseField>

<ResponseField name="linkCount" type="number">
  Number of links in this group (0 for new groups)
</ResponseField>

<ResponseField name="createdAt" type="string">
  ISO 8601 timestamp of creation
</ResponseField>

<RequestExample>
  ```bash cURL theme={null}
  curl -X POST https://api.bouncy.ai/v1/groups \
    -H "Authorization: Bearer bcy_live_pk_YOUR_API_KEY" \
    -H "Content-Type: application/json" \
    -d '{"name": "Summer Campaign 2026"}'
  ```

  ```javascript JavaScript theme={null}
  const response = await fetch('https://api.bouncy.ai/v1/groups', {
    method: 'POST',
    headers: {
      'Authorization': 'Bearer bcy_live_pk_YOUR_API_KEY',
      'Content-Type': 'application/json'
    },
    body: JSON.stringify({ name: 'Summer Campaign 2026' })
  });

  const group = await response.json();
  console.log(`Created group: ${group.id}`);
  ```

  ```python Python theme={null}
  import requests

  response = requests.post(
      'https://api.bouncy.ai/v1/groups',
      headers={
          'Authorization': 'Bearer bcy_live_pk_YOUR_API_KEY',
          'Content-Type': 'application/json'
      },
      json={'name': 'Summer Campaign 2026'}
  )

  group = response.json()
  print(f"Created group: {group['id']}")
  ```
</RequestExample>

<ResponseExample>
  ```json 201 Created theme={null}
  {
    "id": "grp_abc123xyz",
    "name": "Summer Campaign 2026",
    "linkCount": 0,
    "createdAt": "2026-02-06T12:00:00Z"
  }
  ```

  ```json 400 Bad Request theme={null}
  {
    "error": {
      "code": "missing_required_field",
      "message": "The name field is required",
      "field": "name"
    }
  }
  ```
</ResponseExample>
