linear_assignIssue
Assign or unassign an issue to a specific user in the Linear project management system. Provide the issue ID and assignee ID to manage task ownership efficiently.
Instructions
Assign an issue to a user
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| assigneeId | Yes | ID of the user to assign the issue to, or null to unassign | |
| issueId | Yes | ID or identifier of the issue to assign (e.g., ABC-123) |
Implementation Reference
- Handler function that implements the core logic for the linear_assignIssue tool, validating arguments with isAssignIssueArgs and calling linearService.assignIssue.export function handleAssignIssue(linearService: LinearService) { return async (args: unknown) => { try { if (!isAssignIssueArgs(args)) { throw new Error('Invalid arguments for assignIssue'); } return await linearService.assignIssue(args.issueId, args.assigneeId); } catch (error) { logError('Error assigning issue', error); throw error; } }; }
- Tool definition (schema) for linear_assignIssue, specifying input parameters (issueId, assigneeId) and output structure.export const assignIssueToolDefinition: MCPToolDefinition = { name: 'linear_assignIssue', description: 'Assign an issue to a user', input_schema: { type: 'object', properties: { issueId: { type: 'string', description: 'ID or identifier of the issue to assign (e.g., ABC-123)', }, assigneeId: { type: 'string', description: 'ID of the user to assign the issue to, or null to unassign', }, }, required: ['issueId', 'assigneeId'], }, output_schema: { type: 'object', properties: { success: { type: 'boolean' }, issue: { type: 'object', properties: { id: { type: 'string' }, identifier: { type: 'string' }, title: { type: 'string' }, assignee: { type: 'object' }, url: { type: 'string' }, }, }, }, }, };
- src/tools/handlers/index.ts:113-113 (registration)Registration of the linear_assignIssue tool handler in the registerToolHandlers function.linear_assignIssue: handleAssignIssue(linearService),
- src/tools/type-guards.ts:260-272 (helper)Type guard function used in the handler to validate input arguments for linear_assignIssue.export function isAssignIssueArgs(args: unknown): args is { issueId: string; assigneeId: string; } { return ( typeof args === 'object' && args !== null && 'issueId' in args && typeof (args as { issueId: string }).issueId === 'string' && 'assigneeId' in args && typeof (args as { assigneeId: string }).assigneeId === 'string' ); }