---
title: "Replace Organizations in a Group"
method: PATCH
path: "/api/v2/groups/{id}/relationships/organizations"
tags: ["Group"]
---

# Replace Organizations in a Group

`PATCH /api/v2/groups/{id}/relationships/organizations`

This endpoint replaces all organizations in an existing group with the newly supplied organizations. On a successful add, it returns a `201 Created` response with no body. This endpoint is only accessible to Global Admin Tool Organizations. <h3>Required Scope</h3>`groups:write`

## Path parameters

- `id` string, required

## Request body

- RelationshipsOrganizationsBody
  - `data` Apiv2groupsgroupIdrelationshipsorganizationsData[]
    - `type` string — Type of object that will be added as a relationship. Can only be `organizations`.
    - `id` string, required — Organization Code of the organization that will be added to the group.

## Response `201`

Success

## Other responses

- `400` — Bad Request

---

[API](https://skmtc.net/degreed/apis/degreed-api-web.md) · [All operations](https://skmtc.net/degreed/apis/degreed-api-web/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/degreed/degreed-api-web/revisions/4a22b709515c/schema)
