Provision the Severity field on a triage board
Use this once per Projects v2 board, before calling set_severity against
any issue on it, to make sure the board has a Severity single-select
field with the canonical options.
-
Identify the board’s owner login, project number, and owner type (
organizationis the default if you omitprojectOwnerType). -
Call:
ensure_severity_field {projectOwnerLogin: "<org-or-user>",projectNumber: <n>,projectOwnerType: "organization"} -
Check the response:
created: true— the field did not exist; it was created with optionsCritical(red),High(orange),Medium(yellow),Low(green).created: false— the field already existed; it was returned as-is, with no mutation.optionsstill lists the current option IDs.
-
If the call instead fails with
field_type_conflict, a field namedSeverityalready exists on the board but is not a single-select field (for example, a text or number field). Rename or remove that field on the board before retrying — this tool will not overwrite it.
- This call is safe to run repeatedly (idempotent) and safe to include in setup automation without a pre-check.
- Projects v2 writes need the
projectOAuth scope on classic tokens (gh auth login --scopes project); a missing scope surfaces as amissing_scopeerror, not a silent failure.
See also
Section titled “See also”- how-to/set-severity.md — the next step, once the field exists.
- reference/tools.md — full input schema.