---
title: "Manage the associations of an Office 365 instance"
method: POST
path: "/office365s/{office365_id}/associations"
tags: ["Graph", "Office 365"]
---

# Manage the associations of an Office 365 instance

`POST /office365s/{office365_id}/associations`

## Request

- Base URL: `https://console.jumpcloud.com/api/v2`
- URL: `https://console.jumpcloud.com/api/v2/office365s/{office365_id}/associations`
- Auth: API key in header `x-api-key`
- TypeScript: <https://skmtc.dev/jumpcloud/apis/jumpcloud-api-2/docs/office365s/:office365_id/associations/post.ts> (a function with typed inputs; its response is checked against the schema)

This endpoint allows you to manage the _direct_ associations of a Office 365 instance.

A direct association can be a non-homogeneous relationship between 2 different objects, for example Office 365 and Users.

#### Sample Request
```
curl -X POST https://console.jumpcloud.com/api/v2/office365s/{OFFICE365_ID}/associations \
  -H 'Accept: application/json' \
  -H 'Content-Type: application/json' \
  -H 'x-api-key: {API_KEY}' \
  -d '{
    "op": "add",
    "type": "user_group",
    "id": "{Group_ID}"
  }'
```

## Headers

- `x-org-id` string

## Request body

- GraphOperationOffice365
  - `id` string, required: The ObjectID of graph object being added or removed as an association.
  - `op` 'add' | 'remove' | 'update', required: How to modify the graph connection.
  - `attributes` GraphAttributes, nullable: The graph attributes.
  - `type` 'user' | 'user_group', required: Targets which a "office_365" can be associated to.

## Response `204`

OK

---

[API](https://skmtc.dev/jumpcloud/apis/jumpcloud-api-2.md) - [All operations](https://skmtc.dev/jumpcloud/apis/jumpcloud-api-2/llms.txt) - [OpenAPI document](https://skmtc.dev/jumpcloud/apis/jumpcloud-api-2/revisions/3f09fe63caaa?raw)
