Planissue-blueprints
POST/repositories/{repo_id}/issue-blueprints
Define a custom work-item type on a repository
create_repo_blueprint
issue_blueprint:manage
A token needs theissue_blueprint:managescope: Define and remove custom work-item types (blueprints)Granted bywrite_api,write_repository.Every operation this scope unlocksAudited · mutation
x-gitmoap-audit: {"kind":"audited","arg":"mutation"}
Quota · blueprints per scope
x-gitmoap-quota: {"kind":"enforced","arg":"blueprints_per_scope"}
Creates a blueprint: a named custom type built on one of the base work-item types, whose facets become acceptance criteria on every work item filed as that type. Its id is a slug, unique in the repository. Maintainers and above may define types, up to the repository's limit.
Parameters
Path
- repo_idRepositoryId (string · uuid)Repository ID
Request body
application/json- base_typeWorkItemTypeepicstorybugtaskspikechoreincidentsub_taskThe kind of work item. The type decides where an item may live (a group or a repository), which types it may have as children, and which fields it accepts.
- blueprint_idBlueprintId (string)The custom-type slug, unique within the scope.
- namestring
- descriptionstring or nulloptional
facetsarray of FacetTemplateoptional
- The FacetTemplate schema
- categoryFacetCategory (string)The facet's category — any value you choose. Facets with the same category are grouped together.
- keyFacetKey (string)The facet's identifier within the blueprint. It stays the same when the label changes, so a work item re-applying the blueprint updates the facet in place.
- labelstringThe facet's display name, such as "Observability".
- bindingFacetBindingTemplateoptionalHow the seeded criterion is bound. Defaults to a manual checkbox.
- hintstring or nulloptionalThe starter criterion's text. When absent the criterion is titled by the facet
label. - requiredbooleanoptionalWhether the facet's criterion must be satisfied before the work item can be closed or verified. Defaults to
true.
Request body exampleSynthesized example
{
"base_type": "epic",
"blueprint_id": "6cf13f49-48ed-48cb-ab1b-4670c0409272",
"name": "payments-api"
}
Responses
200The created blueprintapplication/json
- base_typeWorkItemTypeepicstorybugtaskspikechoreincidentsub_taskThe built-in type the custom type is based on, which decides where its items may live, their children and their fields. "API Feature" might be a
storywith a blueprint on top. - blueprint_idBlueprintId (string)The blueprint's slug, unique within its group or repository. It never changes.
- created_atstring
created_byActorSummaryWho created the blueprint, as they were when they created it.
- The ActorSummary schema
- emailstring
- idstring
- usernamestring
- avatar_urlstring or nulloptional
- namestringThe custom type's display name, such as "API Feature".
- scope_idstring
- scope_typeScopeTypegrouprepository
- updated_atstring
- archivedbooleanoptionalHidden from the type picker; items already filed keep their
type_profile. - descriptionstring or nulloptional
facetsarray of FacetTemplateoptionalThe blueprint's facets, in order.
- The FacetTemplate schema
- categoryFacetCategory (string)The facet's category — any value you choose. Facets with the same category are grouped together.
- keyFacetKey (string)The facet's identifier within the blueprint. It stays the same when the label changes, so a work item re-applying the blueprint updates the facet in place.
- labelstringThe facet's display name, such as "Observability".
- bindingFacetBindingTemplateoptionalHow the seeded criterion is bound. Defaults to a manual checkbox.
- hintstring or nulloptionalThe starter criterion's text. When absent the criterion is titled by the facet
label. - requiredbooleanoptionalWhether the facet's criterion must be satisfied before the work item can be closed or verified. Defaults to
true.
- versioninteger · int64optional0–∞The blueprint's revision, incremented on every change. An update must send the version it read, and is refused with a
409if the blueprint changed since.
200 exampleSynthesized example
{
"base_type": "epic",
"blueprint_id": "52cf5c72-d783-4326-a77b-88940ac8f6bc",
"created_at": "2026-10-15T09:16:27Z",
"created_by": {
"email": "mara@acme.example",
"id": "id-190e",
"username": "mara",
"avatar_url": "https://gitmoap.example/acme/cf8a3051"
},
"name": "payments-api",
"scope_id": "aa26b705-58a9-4799-83b7-179be0a35079",
"scope_type": "group",
"updated_at": "2026-10-09T19:20:40Z",
"archived": false,
"description": "Renders each region as density contours of its operations.",
"facets": [
{
"category": "category-017b",
"key": "key-aa62",
"label": "label-0579"
}
],
"version": 56
}
400Invalid facets, or a bound facet on a group-only base typeapplication/json
Error codes
- BAD_REQUESTThe request is malformed: a parameter or a body field is not a well-formed value of its type
errorErrorBody
- The ErrorBody schema
- codestringThe coarse category, tied to the status:
NOT_FOUND,CONFLICT,INSUFFICIENT_SCOPE. Every error has one; the API reference's error catalogue lists them all. - messagestringWhat went wrong, for a person. Written to be read, not parsed: match on
reasonorcode. - fieldstring or nulloptionalOn a
400that refused one field's value, the field, as its JSON path:email,items[0].name. Put the message under that input. Absent on every other error. - reasonstring or nulloptionalThe specific code, when the error has one:
LAST_ORGANIZATION_OWNER,BRANCH_PROTECTED. The message starts with it too. Match on this when it is present, and oncodeotherwise. - required_scopestring or nulloptionalThe scope the access token was missing, on
INSUFFICIENT_SCOPE. - violationsanyoptionalPresent on the structured-validation errors (
PROVIDER_VALIDATION_FAILEDper-node,PIPELINE_VALIDATION_FAILEDDAG): a JSON array of the offending elements, so a caller can fix every one in a single round-trip. Absent (omitted) on every other error.
400 exampleSynthesized example
{
"error": {
"code": "code-fbb1",
"message": "Draw the region map from operation density"
}
}
401Unauthenticated — no credential, or an invalid oneapplication/json
Error codes
- UNAUTHORIZEDNo credential was sent, or the one sent is invalid, expired or revoked
errorErrorBody
- The ErrorBody schema
- codestringThe coarse category, tied to the status:
NOT_FOUND,CONFLICT,INSUFFICIENT_SCOPE. Every error has one; the API reference's error catalogue lists them all. - messagestringWhat went wrong, for a person. Written to be read, not parsed: match on
reasonorcode. - fieldstring or nulloptionalOn a
400that refused one field's value, the field, as its JSON path:email,items[0].name. Put the message under that input. Absent on every other error. - reasonstring or nulloptionalThe specific code, when the error has one:
LAST_ORGANIZATION_OWNER,BRANCH_PROTECTED. The message starts with it too. Match on this when it is present, and oncodeotherwise. - required_scopestring or nulloptionalThe scope the access token was missing, on
INSUFFICIENT_SCOPE. - violationsanyoptionalPresent on the structured-validation errors (
PROVIDER_VALIDATION_FAILEDper-node,PIPELINE_VALIDATION_FAILEDDAG): a JSON array of the offending elements, so a caller can fix every one in a single round-trip. Absent (omitted) on every other error.
401 exampleSynthesized example
{
"error": {
"code": "code-e869",
"message": "Stream pipeline status into the run header"
}
}
403Forbidden — the caller's access level or token scope is insufficientapplication/json
Error codes
- FORBIDDENYou are signed in but may not do this here;
reasonnames the permission or the rule that refused it - INSUFFICIENT_SCOPEThe access token lacks the scope this operation needs;
required_scopenames it - PERMISSION_REQUIREDYou need a permission you do not hold here; the message names it
errorErrorBody
- The ErrorBody schema
- codestringThe coarse category, tied to the status:
NOT_FOUND,CONFLICT,INSUFFICIENT_SCOPE. Every error has one; the API reference's error catalogue lists them all. - messagestringWhat went wrong, for a person. Written to be read, not parsed: match on
reasonorcode. - fieldstring or nulloptionalOn a
400that refused one field's value, the field, as its JSON path:email,items[0].name. Put the message under that input. Absent on every other error. - reasonstring or nulloptionalThe specific code, when the error has one:
LAST_ORGANIZATION_OWNER,BRANCH_PROTECTED. The message starts with it too. Match on this when it is present, and oncodeotherwise. - required_scopestring or nulloptionalThe scope the access token was missing, on
INSUFFICIENT_SCOPE. - violationsanyoptionalPresent on the structured-validation errors (
PROVIDER_VALIDATION_FAILEDper-node,PIPELINE_VALIDATION_FAILEDDAG): a JSON array of the offending elements, so a caller can fix every one in a single round-trip. Absent (omitted) on every other error.
403 exampleSynthesized example
{
"error": {
"code": "code-23e3",
"message": "Draw the region map from operation density"
}
}
404Not found — or found and private, which is masked as absentapplication/json
Error codes
- NOT_FOUNDThe resource does not exist — or exists and you cannot see it: a private resource you have no access to answers exactly as an absent one does
errorErrorBody
- The ErrorBody schema
- codestringThe coarse category, tied to the status:
NOT_FOUND,CONFLICT,INSUFFICIENT_SCOPE. Every error has one; the API reference's error catalogue lists them all. - messagestringWhat went wrong, for a person. Written to be read, not parsed: match on
reasonorcode. - fieldstring or nulloptionalOn a
400that refused one field's value, the field, as its JSON path:email,items[0].name. Put the message under that input. Absent on every other error. - reasonstring or nulloptionalThe specific code, when the error has one:
LAST_ORGANIZATION_OWNER,BRANCH_PROTECTED. The message starts with it too. Match on this when it is present, and oncodeotherwise. - required_scopestring or nulloptionalThe scope the access token was missing, on
INSUFFICIENT_SCOPE. - violationsanyoptionalPresent on the structured-validation errors (
PROVIDER_VALIDATION_FAILEDper-node,PIPELINE_VALIDATION_FAILEDDAG): a JSON array of the offending elements, so a caller can fix every one in a single round-trip. Absent (omitted) on every other error.
404 exampleSynthesized example
{
"error": {
"code": "code-4443",
"message": "Pin a page's payload to the build that rendered it"
}
}
409A blueprint with this id already exists in the scopeapplication/json
Error codes
- CONFLICTThe request conflicts with the resource's current state;
reasonsays how - LEGAL_ACCEPTANCE_REQUIREDAccept the current Terms of Service before changing anything; reading stays open
errorErrorBody
- The ErrorBody schema
- codestringThe coarse category, tied to the status:
NOT_FOUND,CONFLICT,INSUFFICIENT_SCOPE. Every error has one; the API reference's error catalogue lists them all. - messagestringWhat went wrong, for a person. Written to be read, not parsed: match on
reasonorcode. - fieldstring or nulloptionalOn a
400that refused one field's value, the field, as its JSON path:email,items[0].name. Put the message under that input. Absent on every other error. - reasonstring or nulloptionalThe specific code, when the error has one:
LAST_ORGANIZATION_OWNER,BRANCH_PROTECTED. The message starts with it too. Match on this when it is present, and oncodeotherwise. - required_scopestring or nulloptionalThe scope the access token was missing, on
INSUFFICIENT_SCOPE. - violationsanyoptionalPresent on the structured-validation errors (
PROVIDER_VALIDATION_FAILEDper-node,PIPELINE_VALIDATION_FAILEDDAG): a JSON array of the offending elements, so a caller can fix every one in a single round-trip. Absent (omitted) on every other error.
409 exampleSynthesized example
{
"error": {
"code": "code-1a3d",
"message": "Label every synthesized example"
}
}
429Per-scope blueprint limit reachedapplication/json
Error codes
- TOO_MANY_REQUESTSRetryableA quota, a rate limit or a transfer budget is spent. When the response carries
Retry-After, retry after that many seconds
errorErrorBody
- The ErrorBody schema
- codestringThe coarse category, tied to the status:
NOT_FOUND,CONFLICT,INSUFFICIENT_SCOPE. Every error has one; the API reference's error catalogue lists them all. - messagestringWhat went wrong, for a person. Written to be read, not parsed: match on
reasonorcode. - fieldstring or nulloptionalOn a
400that refused one field's value, the field, as its JSON path:email,items[0].name. Put the message under that input. Absent on every other error. - reasonstring or nulloptionalThe specific code, when the error has one:
LAST_ORGANIZATION_OWNER,BRANCH_PROTECTED. The message starts with it too. Match on this when it is present, and oncodeotherwise. - required_scopestring or nulloptionalThe scope the access token was missing, on
INSUFFICIENT_SCOPE. - violationsanyoptionalPresent on the structured-validation errors (
PROVIDER_VALIDATION_FAILEDper-node,PIPELINE_VALIDATION_FAILEDDAG): a JSON array of the offending elements, so a caller can fix every one in a single round-trip. Absent (omitted) on every other error.
429 exampleSynthesized example
{
"error": {
"code": "code-c665",
"message": "Stream pipeline status into the run header"
}
}
CLI
gitmoap issue-blueprints create-repo-blueprint
- --repo-ididRepository ID (id or owner/repo path)
- --base-typeepic | story | bug | task | spike | chore | incident | sub_task
- --blueprint-idstringThe custom-type slug, unique within the scope.
- --descriptionstringoptional
- --facetsjsonoptional
- --namestring