---
title: "Update the access control for a Message Share Link."
method: PUT
path: "/message-sharelinks/{share_link_id}/access"
tags: ["Message Share Links"]
---

# Update the access control for a Message Share Link.

`PUT /message-sharelinks/{share_link_id}/access`

## Request

- Base URL: `https://api.carbonvoice.app`
- URL: `https://api.carbonvoice.app/message-sharelinks/{share_link_id}/access`
- Auth: one of:
  - API key in header `pxtoken`
  - OAuth 2 (implicit, authorization URL `https://api.carbonvoice.app/oauth/authorize`)

Update AccessType (public, specified) and SpecifiedAccessType. Only possible when ShareType of Shared Message is (link).

## Path parameters

- `share_link_id` string, required

## Request body

- UpdateAccessPayload
  - `access_type` 'specified' | 'public', required: What is the access type for the MessageShareLink
  - `specified_access` SpecifiedAccess[], nullable: List of Specified Access for the MessageShareLink
    - `type` 'channel' | 'workspace' | 'workspace_group' | 'user', required: What is the Specified access type for the MessageShareLink
    - `ids` string[], required: List of IDs that have access to the MessageShareLink
  - `end_access_at` string, date-time, nullable: Date when the access to MessageShareLink ends
  - `reply_type` 'shared' | 'private_only', nullable: How replies to this share link behave. Switching to private_only stops new members from joining the reply conversation; an already-created conversation is kept.

## Response `200`

- MessageShareLink
  - `_id` string, required: Unique Identifier of share link
  - `created_by` string, required: Identifier of the User who created the share/forward
  - `channel_id` string, nullable: Channel ID where forwarded message was sent to
  - `message_id` string, nullable: Message ID that has the share_link_id attached to
  - `created_at` number, required
  - `last_updated_at` number, required
  - `end_access_at` number, nullable: Date when the access to shared message ends
  - `revoked_at` number, nullable
  - `revoked_by` string, nullable
  - `share_type` 'forward' | 'link', required: What is the ShareType of the MessageShareLink
  - `access_type` 'public' | 'specified' | 'forward', required: What is the access type for the MessageShareLink
  - `specified_access` SpecifiedAccess[]: List of Specified Access for the MessageShareLink
    - `type` 'channel' | 'workspace' | 'workspace_group' | 'user', required: What is the Specified access type for the MessageShareLink
    - `ids` string[], required: List of IDs that have access to the MessageShareLink
  - `reply_type` 'shared' | 'private_only', required: How replies to this share link behave. Legacy links without the field are private_only.
  - `reply_conversation_id` string, nullable: Conversation holding the shared replies to this link, if one was already created

## Other responses

- `403`
- `404`

---

[API](https://skmtc.dev/carbonvoice/apis/carbon-voice-api.md) · [All operations](https://skmtc.dev/carbonvoice/apis/carbon-voice-api/llms.txt) · [OpenAPI document](https://skmtc.dev/carbonvoice/apis/carbon-voice-api/revisions/b91c5c845122?raw)
