---
title: "Share component with user"
method: POST
path: "/{globalCompanyId}/componentmetadata/shares"
tags: ["Component Meta Data"]
---

# Share component with user

`POST /{globalCompanyId}/componentmetadata/shares`

Note that only the following component types are currently supported: "segment", "project"<br>There are three valid values for "shareToType":<br><b>"all"</b>: Shares the component to all users in the organization. For this operation, "shareToId" is not required (ignored if sent)<br><b>"user"</b>: Shares the component with a specific user. For this operation, "shareToId" (the loginId of the user to share to) is required.<br><b>"group"</b>: Shares the component with an entire custom user group as defined in the Admin Console. For this operation, "shareToId" (the groupId of the group to share to) is required.

## Path parameters

- `globalCompanyId` string, required

## Query parameters

- `locale` string

## Headers

- `Authorization` string, required
- `x-api-key` string, required

## Request body

- Share
  - `shareId` string
  - `imsOrgId` string
  - `shareToId` integer
  - `shareToImsId` string
  - `shareToType` string
  - `shareFromImsId` string
  - `componentType` string
  - `componentId` string
  - `shareToDisplayName` string
  - `shareToLogin` string
  - `accessLevel` string

## Response `200`

successful operation

- Share
  - `shareId` string
  - `imsOrgId` string
  - `shareToId` integer
  - `shareToImsId` string
  - `shareToType` string
  - `shareFromImsId` string
  - `componentType` string
  - `componentId` string
  - `shareToDisplayName` string
  - `shareToLogin` string
  - `accessLevel` string

## Other responses

- `400` — Invalid component type
- `403` — Permission error; user does not have access share the component
- `500` — Unable to share component

## Changes

- **2025-08-07** `f13c80692287` — 1 warning
  - deleted the `header` request parameter `x-gw-ims-org-id`
- **2025-08-06** `f49e893a6c2b` — 1 breaking
  - added the new required `header` request parameter `x-gw-ims-org-id`
- **2022-05-10** `dcd4514630c4` — 1 breaking
  - api path removed without deprecation

[Change history](https://skmtc.dev/adobe/apis/adobe-analytics-apis/changes/:globalCompanyId/componentmetadata/shares/post.md)

---

[API](https://skmtc.dev/adobe/apis/adobe-analytics-apis.md) · [All operations](https://skmtc.dev/adobe/apis/adobe-analytics-apis/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/adobe/adobe-analytics-apis/revisions/b2e01ce0f30a/schema)
