Skip to main content
Glama

Convert a GitHub project draft into an issue

github_project_item_convert

Convert a draft project board item into a repository issue, preserving its board fields and applying kind, labels, and milestone.

Instructions

Turn a draft item into an issue of a repository the viewer may write to: the draft's title and body become the issue, and the item stays on the board with its field values. The viewer must also be able to update the board; both are checked before anything is written. An item that is not a draft is invalid_argument. Then settle the issue as github_issue_create does: kind (an Issue Type, else a type: label that is created when missing), labels and milestone. A milestone that does not exist fails before the draft is converted unless create_milestone is true. Once the issue exists, a failed kind, labels or milestone step does not fail the call: it is listed in errors and the issue is still returned. An item is named by its node ID (PVTI_…), which also tells its board (a project given beside it must be that board), or by an issue or pull request (12, #12, owner/repo#12 or its URL) that is on the board the lookup finds. A draft can only be named by its ID. A board is named by project: its number, owner/number or its URL, used as it is; any other project is a title, and no project is Roadmap: the open board of that whole title is looked up, never guessed, in owner's boards if owner is given, else in the boards linked to repo, then its organization's, then the viewer's. Needs a token with the project scope; if GitHub reports missing scopes, run gh auth refresh -s project.

Input Schema

NameRequiredDescriptionDefault
itemYesThe draft item's node ID (PVTI_…); only a draft can be turned into an issue.
kindNoSuch as bug or feature: the organization's Issue Type of that name, else the type:<kind> label.
repoNoowner/name of the repository the issue is created in; defaults to the working tree's repository (its origin). Also where the board lookup starts.
ownerNoA user or organization login, or "@me": the owner of a numbered board, else the only owner searched for a title.
labelsNoLabels to add; they must exist.
projectNoThe board, as its number, owner/number or its URL (used as it is; a bare number takes owner, else the owner of repo or of the working tree's repository), or as its title, looked up among open boards (whole title, case-insensitive). Default: the title Roadmap.
milestoneNoA milestone title.
create_milestoneNoCreate the milestone when it does not exist; needs milestone.

Output Schema

NameRequiredDescriptionDefault
kindYesWhere the kind landed; null when none was given or its step failed.
repoYesowner/name of the repository the issue was created in.
issueYes
errorsYesFailed steps, keyed by step (fields.<Field name>, blocked_by, kind, labels, milestone); {} when none.
foreignYes
item_idYes
projectYes
milestoneYesThe milestone the call settled on; if errors.milestone is set it was not applied to the issue.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv0.7.0

TDQS

A4.5/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations only declare readOnly=false, openWorld=true, idempotent=false, destructive=false; the description goes well beyond them with pre-flight permission checks ('both are checked before anything is written'), partial-failure behavior ('a failed kind, labels or milestone step does not fail the call: it is listed in errors and the issue is still returned'), and the milestone pre-check ordering. It also names the required token scope and the exact remediation command, which no annotation conveys.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness3/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The main action is front-loaded and no sentence is off-topic, but the prose is two very long run-on sentences with dense parenthetical clauses that are hard to parse on a first read. Some of the project-naming detail restates the schema and could be tightened without losing meaning.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For an 8-parameter, non-idempotent write tool this covers the essential gaps: prerequisites, auth scopes, failure and partial-failure semantics, item naming constraints, and board resolution fallbacks. An output schema exists, so the description is not obligated to explain return values, and the 'errors' list behavior is covered anyway.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so the baseline would be 3, but the description adds real semantics beyond the schema: the accepted reference forms for 'item' (PVTI_…, 12, #12, owner/repo#12, URL) and the ordered lookup chain for a project given as a title. The default-board rule ('no project is Roadmap') and the cross-check that a project beside an item ID must match its board are constraints the schema does not state.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb and resource — 'Turn a draft item into an issue of a repository' — and clarifies the resulting state ('the item stays on the board with its field values'), which separates it from github_project_item_create and github_issue_create. An agent can distinguish it from all three sibling families without opening a schema.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Explicitly says an item that is not a draft is invalid_argument and that only drafts can be named by ID, which tells the agent when this tool will fail. It also routes the kind/labels/milestone semantics to github_issue_create ('settle the issue as github_issue_create does'). It never says what to use instead to create a plain issue without an existing draft, so it stops short of a full alternatives statement.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.