# Publish generated docs to a Sourced-managed subpath
POST /api/runs/{runId}/docs-preview/publish
Creates or reuses a Sourced-hosted docs URL from the generated docs preview. This is an internal Sourced subpath publication, not a registry write or custom-domain cutover, and it stays noindex until production indexability is approved.
## Request
```bash
curl -X POST 'https://sourced.sh/api/runs/{runId}/docs-preview/publish' \
  -H 'Authorization: Bearer $SOURCED_API_KEY'
```
## Parameters

- runId (path, required): Run identifier.

## Responses

### 201

Sourced-managed docs publication created or reused.
### 401


### 402


### 403


### 404


### 410

The docs-preview artifact expired.
### 422

The run is not ready to publish as a Sourced docs subpath.
