# Delete a project group

Deletes the Forge project group Forge knows by `client_id`. Call it when the group is deleted in Forge.

- **Groups inside it move up to its parent.** Each one's `parent_client_id` becomes the deleted group's parent (or `null` at the top), so what it inherits stays defined: a group that followed the deleted group's organization now follows its new parent's, or bills to no organization.
- **Spend already billed stays where it was billed.** It stays on the organization it was billed to and keeps showing the group's name on that organization's [usage report](/assets/get-usage-detail-report.45870ea5b94806d0570403fa53ae031e4b48417dddf0f27bd3aa2fc29b7ba55c.49b960d1.md). A server rented inside the group keeps naming it in `project_group` and stays billed to the organization it was rented in.
- **From now on the group is unknown.** It is left out of [List project groups](/docs/api-reference/forge-compute/list-project-groups), and a billable call that still names its `client_id` (renting a server, the git impact assessment) is treated as naming no group. [Registering](/docs/api-reference/forge-compute/put-project-group) the same `client_id` again brings it back, with what that call sends.


The answer is the whole list, exactly as [List project groups](/docs/api-reference/forge-compute/list-project-groups) returns it, so every group that moved shows its new parent and organization at once. It names no organization and requires a credential that acts for a person (a bearer token, or a key belonging to a person). Only your own groups can be deleted; anyone else's is not found.

#### Path Parameters

**`client_id`** string required

Forge's own id for the project group: 1 to 128 characters after surrounding spaces are removed, without control characters. An id that cannot be read is refused with `VALIDATION_ERROR` (`details.reason` `invalid_client_id`).

## Returns

The whole list, exactly as [List project groups](/docs/api-reference/forge-compute/list-project-groups#returns) returns it, without the deleted group. Here `grp-clients` was deleted: `Acme Shop`, which sat inside it and inherited its organization, moved to the top and now bills to no organization.


```json
{
  "title": "Bill to",
  "help": "Forge spend inside this group's projects is billed to this organization: rented servers and Forge's AI features. Groups inside it follow it unless they choose their own.",
  "unassigned_label": "Not billed to an organization",
  "organizations": [
    {
      "id": "org_3c1e9a7b5d2f4e8a9b0c6d1e2f3a4b5c",
      "name": "Acme Engineering",
      "logo_url": "https://cdn.example.com/logos/acme.png",
      "selectable": true,
      "reason": null,
      "order": 0
    }
  ],
  "groups": [
    {
      "id": "fpgrp_9d3a6e1c5b7f4a2e8c0d4b6f1a3e5c7d",
      "client_id": "grp-acme-shop",
      "name": "Acme Shop",
      "parent_id": null,
      "parent_client_id": null,
      "organization": null,
      "own_organization": null,
      "inherited": false,
      "inherited_from": null,
      "billing_label": "Not billed to an organization",
      "reason": null,
      "month_to_date_label": "CHF 3.10 this month",
      "created_at": "2026-10-09T08:12:04.902114Z",
      "updated_at": "2026-10-09T10:41:17.205583Z"
    }
  ]
}
```

## Errors

| Status | Code | When |
|  --- | --- | --- |
| 401 | `AUTHENTICATION_REQUIRED` | No valid credential. |
| 403 | `API_KEY_PERSON_REQUIRED` | An organization API key: it has no person of its own. |
| 404 | `FORGE_PROJECT_GROUP_NOT_FOUND` | You have no registered group with this `client_id`: it was never registered, it is already deleted, or it is someone else's. `details.client_id` is the id sent. |
| 422 | `VALIDATION_ERROR` | `client_id` cannot be read (`details.reason` `invalid_client_id`). |



```bash cURL
curl -X DELETE "https://api.aitronos.com/v1/forge/project-groups/grp-clients" \
  -H "Authorization: Bearer $ACCESS_TOKEN"
```


```python Python SDK
# pip install aitronos-sdk
#
# The Python SDK does not expose a typed `forge_project_groups` namespace yet, so
# call the endpoint directly with the same bearer token you would pass to `Aitronos(...)`.
import httpx

ACCESS_TOKEN = "your-access-token"

response = httpx.delete(
    "https://api.aitronos.com/v1/forge/project-groups/grp-clients",
    headers={"Authorization": f"Bearer {ACCESS_TOKEN}"},
)
if response.status_code == 404:
    print("Already gone:", response.json()["error"]["message"])
else:
    for group in response.json()["groups"]:
        print(group["name"], "-", group["billing_label"])
```


```python Python
import os
import requests

token = os.environ["AITRONOS_TOKEN"]
response = requests.delete(
    "https://api.aitronos.com/v1/forge/project-groups/grp-clients",
    headers={"Authorization": f"Bearer {token}"},
)
print(response.status_code, [g["client_id"] for g in response.json().get("groups", [])])
```


```javascript JavaScript
const response = await fetch("https://api.aitronos.com/v1/forge/project-groups/grp-clients", {
  method: "DELETE",
  headers: { Authorization: `Bearer ${process.env.AITRONOS_TOKEN}` },
});
const body = await response.json();
console.log(response.ok ? body.groups.map((g) => g.name) : body.error.message);
```

**Response:**

200 OK

```json
{
  "title": "Bill to",
  "help": "Forge spend inside this group's projects is billed to this organization: rented servers and Forge's AI features. Groups inside it follow it unless they choose their own.",
  "unassigned_label": "Not billed to an organization",
  "organizations": [
    {
      "id": "org_3c1e9a7b5d2f4e8a9b0c6d1e2f3a4b5c",
      "name": "Acme Engineering",
      "logo_url": "https://cdn.example.com/logos/acme.png",
      "selectable": true,
      "reason": null,
      "order": 0
    }
  ],
  "groups": [
    {
      "id": "fpgrp_9d3a6e1c5b7f4a2e8c0d4b6f1a3e5c7d",
      "client_id": "grp-acme-shop",
      "name": "Acme Shop",
      "parent_id": null,
      "parent_client_id": null,
      "organization": null,
      "own_organization": null,
      "inherited": false,
      "inherited_from": null,
      "billing_label": "Not billed to an organization",
      "reason": null,
      "month_to_date_label": "CHF 3.10 this month",
      "created_at": "2026-10-09T08:12:04.902114Z",
      "updated_at": "2026-10-09T10:41:17.205583Z"
    }
  ]
}
```

404 Not Found

```json
{
  "success": false,
  "error": {
    "code": "FORGE_PROJECT_GROUP_NOT_FOUND",
    "message": "This project group is not registered. Refresh Forge and try again.",
    "system_message": "Forge project group not found",
    "type": "client_error",
    "status": 404,
    "details": {"client_id": "grp-clients"},
    "trace_id": "3f1c9a52-7d4e-4b8a-9c21-6e0d5f7a8b34",
    "timestamp": "2026-10-09T10:41:17Z"
  }
}
```

## Related Resources

- [Forge cloud compute overview](/docs/api-reference/forge-compute/introduction)
- [List billing organizations](/docs/api-reference/forge-compute/list-billing-organizations)
- [Choose the default billing organization](/docs/api-reference/forge-compute/choose-billing-organization)
- [List project groups](/docs/api-reference/forge-compute/list-project-groups)
- [Register or update a project group](/docs/api-reference/forge-compute/put-project-group)
- [Delete a project group](/docs/api-reference/forge-compute/delete-project-group)
- [List compute offerings](/docs/api-reference/forge-compute/list-offerings)
- [Get offering options](/docs/api-reference/forge-compute/get-offering-options)
- [Resolve a free size](/docs/api-reference/forge-compute/resolve-offering-size)
- [List connected accounts](/docs/api-reference/forge-compute/list-credentials)
- [Connect a cloud account](/docs/api-reference/forge-compute/put-credential)
- [Disconnect a cloud account](/docs/api-reference/forge-compute/delete-credential)
- [Create a server](/docs/api-reference/forge-compute/create-host)
- [List servers](/docs/api-reference/forge-compute/list-hosts)
- [List your servers in every organization](/docs/api-reference/forge-compute/list-my-hosts)
- [Get a server](/docs/api-reference/forge-compute/get-host)
- [Get a server's daily cost and uptime](/docs/api-reference/forge-compute/get-host-usage)
- [List a server's running intervals](/docs/api-reference/forge-compute/list-host-intervals)
- [List a server's event history](/docs/api-reference/forge-compute/list-host-events)
- [Report a setup step](/docs/api-reference/forge-compute/report-progress)
- [Report the server's host key](/docs/api-reference/forge-compute/report-host-key)
- [Mark a server ready](/docs/api-reference/forge-compute/report-ready)
- [Report activity](/docs/api-reference/forge-compute/report-activity)
- [Park a server](/docs/api-reference/forge-compute/park-host)
- [Resume a server](/docs/api-reference/forge-compute/resume-host)
- [Delete a server](/docs/api-reference/forge-compute/delete-host)
- [Revoke a server](/docs/api-reference/forge-compute/revoke-host)
- [Get compute settings](/docs/api-reference/forge-compute/get-settings)
- [Update compute settings](/docs/api-reference/forge-compute/update-settings)
- [Get spend limits](/docs/api-reference/forge-compute/get-limits)
- [Change the organization's limits](/docs/api-reference/forge-compute/update-organization-limits)
- [Set your own limit](/docs/api-reference/forge-compute/update-my-limit)
- [List member limits](/docs/api-reference/forge-compute/list-member-limits)
- [Set a member's limit](/docs/api-reference/forge-compute/update-member-limit)
- [Delete a leftover resource](/docs/api-reference/forge-compute/delete-orphan)
- [Assess a working tree's impact](/assets/assess-git-impact.a7bae1761a3dd82a227de8c76df41608e7e238562f3d2f420b7b3eccb4ee1234.23c4b6e8.md)
- [Get usage detail report](/assets/get-usage-detail-report.45870ea5b94806d0570403fa53ae031e4b48417dddf0f27bd3aa2fc29b7ba55c.49b960d1.md)