# Update Workflow Sharing

> Enable or disable public sharing for a workflow

- **URL**: https://orshot.com/docs/api-reference/workflow-sharing-post

---

## Overview

Turn public sharing on or off for a workflow. Sharing publishes the workflow to a public page anyone can view and copy into their own workspace.

The share link is minted once and stays stable: turning sharing off and back on brings the same link back to life, so anything you already shared keeps working.```markdown tab="Endpoint"
https://api.orshot.com/v1/workflows/:id/share
```## Path Parameters

| Parameter | Type    | Required | Description                   |
| --------- | ------- | -------- | ----------------------------- |
| `id`      | Integer | Yes      | The unique ID of the workflow |

## Request Body

Both fields are optional. A field you leave out keeps its current value, so you can flip `includeTemplate` without touching the sharing state.

| Parameter         | Type    | Required | Description                                                       |
| ----------------- | ------- | -------- | ----------------------------------------------------------------- |
| `enabled`         | Boolean | No       | Turn public sharing on or off                                      |
| `includeTemplate` | Boolean | No       | Include the workflow's template when someone copies it             |

## Request```js
await fetch("https://api.orshot.com/v1/workflows/83/share", {
  method: "POST",
  headers: {
    "Content-Type": "application/json",
    Authorization: "Bearer <ORSHOT_API_KEY>",
  },
  body: JSON.stringify({
    enabled: true,
    includeTemplate: true, // Optional
  }),
});
```</Tab>```json
{
  "enabled": true,
  "slug": "Xk2mPq9zLb4R",
  "includeTemplate": true,
  "url": "https://orshot.com/workflows/shared/Xk2mPq9zLb4R",
  "embed_url": "https://orshot.com/workflows/shared/Xk2mPq9zLb4R/embed"
}
```</Tab>
</Tabs>

## Error Responses

### Workflow Not Found (404)```json
{
  "error": "Not found"
}
```### Failed to Update (500)```json
{
  "error": "Failed to update sharing"
}
```## Notes

- Disabling sharing makes the public page return a 404, but keeps the slug. Re-enabling restores the exact same URLs.
- Sharing state cannot be set through the general workflow update endpoint; this endpoint is the only way to change it.

## Rate Limits

- 60 requests per minute per workspace