Skip to content
中文

Update a project

Code Mode: praxis.devops.projects.update

HTTP: PATCH /devops/v1/projects/{id}

Change a project’s name, description, labels or delivery settings. Send the new values inside project and name the fields to write in updateMask (name, description, labels, settings); a field not named is left alone, and a mask naming a field this operation cannot change is refused. settings is merged into the current settings rather than replacing them, so a body naming one setting leaves the others as they were. settings.executor decides who publishes the project: absent or mise reads as the Mise pipeline, and devops means that, once the merge is done, the DevOps pipeline releases it. Changing executor changes which pipeline the next release uses, not what already ran. A new name must be kebab-case and unused in the organization, otherwise PROJECT_NAME_TAKEN. Read the project first to know what you are leaving unchanged.

Signature

praxis.devops.projects.update(args:{path:{/** e.g. "dvp_01JQ8Z3M9K4V7B2N6C5X0YTRHW" */ id:string};body:{/** The new values. */ project:{/** New kebab-case name, unique within the organization. e.g. "praxis-platform" */ name?:string;/** New free-text description. e.g. "The platform monorepo." */ description?:string;/** New labels, replacing the current ones. */ labels?:{[key:string]:string};/** Delivery settings to merge into the current ones; absent keys keep their value. */ settings?:{/** New release schedule, or null to stop scheduled releases. */ releaseSchedule?:null|{/** Five-field cron expression, read in timeZone; it decides the release's start, not how long the release takes. e.g. "0 9 * * 1-5" */ cron:string;/** IANA zone the cron is read in, so a schedule does not move when the clocks do. e.g. "Asia/Shanghai" */ timeZone:string};/** Not read: the observation window of a promotion is the observeMinutes of the environment it deploys into (and only for a release-stage environment), so changing e.g. 60 */ observationWindowMinutes?:number;/** Whether merging promotes to the first environment by itself. e.g. true */ autoDeployOnMerge?:boolean;/** Whether a promotion may bypass upstream verification. e.g. false */ allowSkipUpstream?:boolean;/** Whether the merge gate is a required check on the git host. e.g. true */ requireGate?:boolean;gate?:{/** How the merge gate's tests check reads on this project. e.g. "evidence" */ tests?:"evidence"|"off";/** One rule per gate check: its mode (enforce counts it, evaluate shows it without counting, off hides it) and whether an unavailable check blocks. */ rules?:Array<{/** The gate check this rule governs. e.g. "lockfile" */ check:string;/** enforce counts the check toward the gate, evaluate records it without counting, off drops it. e.g. "enforce" */ mode:"enforce"|"evaluate"|"off";/** What an unavailable check does: fail-closed blocks the gate, fail-open shows it without blocking. e.g. "fail-closed" */ whenUnavailable:"fail-closed"|"fail-open";/** The check's own parameters; passed through unread. */ params?:{[key:string]:unknown}}>;/** Subjects allowed to bypass the gate, as agent:<id> or human:<id>. */ bypass?:Array<string>};/** Who publishes this project: mise (the default when absent) keeps the Mise pipeline; devops hands releases to the DevOps pipeline once the merge is done. e.g. "devops" */ executor?:"mise"|"devops"}};/** Which project fields to write, by name: name, description, labels, settings. e.g. ["settings"] */ updateMask?:Array<string>}}):Promise<{/** Project identifier used by every other operation of this domain, so it is the first thing to read from this answer. e.g. "dvp_01JQ8Z3M9K4V7B2N6C5X0YTRHW" */ id:string;/** The resource type of this answer, always project; it lets a caller tell answers of different kinds apart. */ object:"project";/** RFC 3339 UTC time the project was created; the project list is ordered by it, newest first. e.g. "2026-10-20T04:00:00Z" */ createTime:string;/** RFC 3339 UTC time the project or one of its settings last changed. e.g. "2026-11-03T09:15:00Z" */ updateTime:string;/** Canonical Console link for this project, for putting a human-readable reference in a card or a message. e.g. "https://console.deepraxis.com/devops/projects/dvp_01JQ8Z3M9K4V7B2N6C5X0YTRHW" */ viewerUrl:string;/** Short kebab-case name unique inside the organization, used to tell projects apart in conversation. e.g. "praxis" */ name:string;/** What this project is for, in the author's own words; absent when none was given. e.g. "The Praxis monorepo's delivery line." */ description?:string;/** The repository this project deploys from, or null when no repository is bound yet — a project without one can hold flags but cannot release or read targets. */ repository:null|{/** The git host serving this repository; the value decides how fullName is read. e.g. "github" */ provider:"github"|"platform";/** Owner and repository name as the git host spells them, which is what a person sees in a clone URL. e.g. "deepractice/praxis" */ fullName:string;/** The branch releases are built from and behindMain is measured against, usually main. e.g. "main" */ defaultBranch:string;/** The git host connection that authorizes reads of this repository; null for a repository on our own Git, which needs none. e.g. "con_01JQ8Z3M9K4V7B2N6C5X0YTRHW" */ connection:(string)|null;/** Whether the repository is private; a private one is only readable through its connection, never anonymously. e.g. true */ private:boolean;mirror:{/** Where the mirror stands; a failed mirror still lets releases run, because a release reads the git host directly. e.g. "fresh" */ state:"syncing"|"fresh"|"stale"|"failed";/** The commit the mirror held when it was last read; absent before the first read finished. e.g. "4f2a9c1d8e7b6a5c4d3e2f1a0b9c8d7e6f5a4b3c" */ headSha?:string;/** RFC 3339 UTC time of that last read; absent before the first read finished. e.g. "2026-11-03T09:14:30Z" */ syncTime?:string;/** Why the last read failed, present only while state is failed; it names the git host's own message rather than a summary. e.g. "GitHub returned 403 for this installation." */ error?:string}};settings:{/** The cron that cuts a release on its own, or null for a project that only releases when a person asks. */ releaseSchedule:null|{/** Five-field cron expression, read in timeZone; it decides the release's start, not how long the release takes. e.g. "0 9 * * 1-5" */ cron:string;/** IANA zone the cron is read in, so a schedule does not move when the clocks do. e.g. "Asia/Shanghai" */ timeZone:string};/** Not read, kept for old records: the observation window is the observeMinutes of the environment a promotion deploys into, which wins over this value. e.g. 60 */ observationWindowMinutes:number;/** Whether merging into the default branch promotes to the first environment by itself; false means every promotion is asked for explicitly. e.g. true */ autoDeployOnMerge:boolean;/** Whether this project accepts a bypass that skips upstream verification. e.g. false */ allowSkipUpstream:boolean;/** Whether the merge gate is registered with the git host as a required check; true means the host itself blocks a merge the gate has not passed. e.g. true */ requireGate:boolean;gate?:{/** How the merge gate's tests check reads on this project. e.g. "evidence" */ tests?:"evidence"|"off";/** One rule per gate check: its mode (enforce counts it, evaluate shows it without counting, off hides it) and whether an unavailable check blocks. */ rules?:Array<{/** The gate check this rule governs. e.g. "lockfile" */ check:string;/** enforce counts the check toward the gate, evaluate records it without counting, off drops it. e.g. "enforce" */ mode:"enforce"|"evaluate"|"off";/** What an unavailable check does: fail-closed blocks the gate, fail-open shows it without blocking. e.g. "fail-closed" */ whenUnavailable:"fail-closed"|"fail-open";/** The check's own parameters; passed through unread. */ params?:{[key:string]:unknown}}>;/** Subjects allowed to bypass the gate, as agent:<id> or human:<id>. */ bypass?:Array<string>};retention?:{/** Delete a pull request's branch as soon as it merges, as GitHub's automatic head-branch deletion does. e.g. true */ deleteMergedBranch?:boolean;/** Days a stopped unit whose change is still open is kept before it is deleted (the unit pushes its work to a WIP ref first and is kept when it cannot). e.g. 30 */ stoppedUnitDays?:number;/** Days test evidence rows are kept. e.g. 90 */ evidenceDays?:number;/** How many ready prebuilds each workspace keeps, newest first; older ones are archived and their snapshots deleted. e.g. 2 */ prebuildVersions?:number};deploy?:{/** Which version of the deploy engine (the published @deepraxis/cli, which carries praxis devops deploy, the OpenTofu orchestration and the built-in cloudflare and e.g. "latest" */ engine?:string;/** Which machine a promotion is built on. e.g. "spot" */ builder?:"slim"|"spot"};release?:{/** Which engine runs a promotion of this project. e.g. "queue" */ engine?:"queue"|"workflow"}};/** Free-form key and value pairs on the project, for grouping and for a caller's own bookkeeping; empty when none were set. e.g. {"team":"platform"} */ labels:{[key:string]:string}}>;

Parameters

NameInTypeRequiredDescription
idpathstringyesThe project identifier returned by the project list, not the project’s display name or its repository name.

Request body

RequiredContent typesDescription
yesapplication/jsonA patch whose project object holds only the fields to change, plus the update mask naming them.

Responses

StatusContent typesDescription
200application/jsonThe project after the patch, with its update time advanced.
400application/jsonINVALID_PARAMS or INVALID_ARGUMENT means a field, query value or identifier violates the documented format or range — an unknown enum value, a pageSize outside 1..100, an unsupported filter or orderBy field, or an id with the wrong prefix. Correct the named input; nothing was read or written.
401application/jsonThe API key is missing or invalid; send a valid Praxis API key in the Authorization header before retrying.
403application/jsonThe credential carries no organization, or that organization cannot reach this project; use a key belonging to the project’s organization. No cross-organization read is possible.
404application/jsonPROJECT_NOT_FOUND means no project with that id is visible to this organization; list the projects and use an id from that answer.
409application/jsonPROJECT_NAME_TAKEN means another project in this organization already uses that name; choose a different one.
500application/jsonINTERNAL means the service could not complete the request; retry once, and if it repeats report the request id. A read is safe to repeat; a write that failed this way should be re-read before it is sent again.