Remove an origin pattern
POST
Removes one pattern from the project's origins. Requests from URLs only that pattern admitted are refused from then on; live previews and deployment history are untouched. Removing a pattern that is already absent is idempotent and answers 204.
header
AuthorizationBearer <token>Scope: origin.delete
project_id*stringThe unique identifier of the project.
Match
^[a-zA-Z0-9_-]+$application/json- body
pattern*stringThe origin pattern exactly as stored on the project (same string returned by create/get or addOrigin).
The pattern was removed.
Example Request
import { configureZitadel, getApi } from "@zitadel/api/config";import { setApiCsrfToken } from "@zitadel/api/runtime/auth";// In the browser, through the SDK proxy: the session cookie authenticates the call.const client = getApi(configureZitadel({ projectId: "proj_01KWH1P4MYS7F0N9WD3P2E4YM5" }));// A write the session cookie authenticates carries the session's CSRF token.setApiCsrfToken((await client.getMySessionCsrfToken()).csrf_token);await client.removeOrigin("proj_01KWH1P4MYS7F0N9WD3P2E4YM5", { pattern: "string" });Example Response
Empty
Was this helpful?