---
title: "Update a draft private endpoint"
method: PATCH
path: "/private-endpoints/{id}"
tags: ["Private Endpoints"]
---

# Update a draft private endpoint

`PATCH /private-endpoints/{id}`

Replace a draft endpoint's upstream configuration: send `upstream_model_id`, and `base_url` to change it (an omitted `base_url` keeps the stored one). Omitted data-policy declarations are kept while the upstream is unchanged and cleared when it changes. Any change clears earlier validation. Active endpoints return 409; delete and re-create them instead. [Management key](/docs/guides/overview/auth/management-api-keys) required.

## Path parameters

- `id` string, uuid, required — Stable identifier of the private endpoint.

## Request body

- UpdatePrivateEndpointRequest
  - `base_url` string — HTTPS base URL of your deployment. Required unless the provider derives its URL from the BYOK credential (Azure, Amazon Bedrock, Google Vertex).
  - `declared_region` 'global' | 'europe' | 'us' | 'null', nullable — Attest where this deployment processes data.
  - `declared_zdr` boolean, nullable — Attest that this deployment retains no prompt or completion data.
  - `upstream_model_id` string, required — Model or deployment identifier sent to the upstream provider.

## Response `200`

The updated endpoint

- PrivateEndpointResponse
  - `data` PrivateEndpoint, required
    - `base_url` string, nullable, required — HTTPS base URL of your deployment, or `null` for providers whose URL is derived from the BYOK credential (Azure, Amazon Bedrock, Google Vertex).
    - `declared_region` 'global' | 'europe' | 'us' | 'null', nullable, required — Where you attest this deployment processes data. `global` means not regional; `null` means undeclared.
    - `declared_zdr` boolean, nullable, required — Whether you attest this deployment retains no prompt or completion data. `null` means undeclared.
    - `id` string, uuid, required — Stable identifier of the private endpoint.
    - `model_name` string, nullable, required — Display name of the model, or `null` when the model is no longer listed.
    - `model_permaslug` string, required — Permanent slug of the model this endpoint serves.
    - `model_slug` string, nullable, required — Public model slug, or `null` when the model is no longer listed.
    - `pricing` PrivateEndpointPricing, required — Negotiated per-token rates reported for requests routed to this endpoint.
      - `completion` string, required — USD per completion token, as a decimal string.
      - `prompt` string, required — USD per prompt token, as a decimal string.
    - `provider_name` string, required — Display name of the upstream provider.
    - `provider_slug` string, nullable, required — Slug of the upstream provider, or `null` when the provider is no longer listed.
    - `status` 'draft' | 'active' | 'disabled', required — Lifecycle state. `draft` endpoints are not routable until validated and activated; `disabled` endpoints are activated but temporarily not routable.
    - `upstream_model_id` string, required — Model or deployment identifier sent to the upstream provider.

## Other responses

- `400` — Bad Request - Invalid request parameters or malformed input
- `401` — Unauthorized - Authentication required or invalid credentials
- `403` — Forbidden - Authentication successful but insufficient permissions
- `404` — Not Found - Resource does not exist
- `408` — Request Timeout - Operation exceeded time limit
- `409` — Conflict - Resource conflict or concurrent modification
- `422` — Unprocessable Entity - Semantic validation failure
- `500` — Internal Server Error - Unexpected server error
- `502` — Bad Gateway - Provider/upstream API failure

## Changes

- **2026-09-28** `057102d53272` — 1 info
  - endpoint added

[Change history](https://skmtc.dev/openrouterteam/apis/openrouter-api/changes/private-endpoints/:id/patch.md)

---

[API](https://skmtc.dev/openrouterteam/apis/openrouter-api.md) · [All operations](https://skmtc.dev/openrouterteam/apis/openrouter-api/llms.txt) · [OpenAPI document](https://skmtc.dev/openrouterteam/apis/openrouter-api/revisions/ae97b5c6983d?raw)
