Skip to main content
Glama

create_object

Create and organize tasks, projects, epics, or features within the Task Trellis system. Define hierarchies, set priorities, statuses, and prerequisites to manage work items effectively.

Instructions

Creates a new object in the task trellis system

Use this tool to create new objects such as tasks, projects, or other work items within the task management hierarchy. Objects can have parent-child relationships and dependencies through prerequisites.

Available object types and hierarchy requirements:

  • 'project': Top-level containers, cannot have a parent

  • 'epic': Can have no parent or a project as a parent

  • 'feature': Can have no parent or an epic as a parent

  • 'task': Can have no parent or a feature as a parent

Supported hierarchy structures:

  • Full hierarchy: project → epic → feature → task

  • Simplified: epic → feature → task

  • Simplified: feature → task

  • Standalone: epic

  • Standalone: task

Available status values:

  • 'draft': Initial state for new objects

  • 'open': Ready to begin work (default)

  • 'open': Ready to begin work

  • 'in-progress': Currently being worked on

  • 'done': Completed successfully

  • 'wont-do': Cancelled or decided against

Available priority values:

  • 'high': Critical or urgent work

  • 'medium': Standard priority (default)

  • 'low': Nice-to-have or future work

Key aspects:

  • Objects support hierarchical organization via parent relationships

  • Prerequisites define execution order dependencies between objects

  • Parent-child relationships must follow the hierarchy rules above

  • The system validates parent types during creation

Best practices:

  • Use descriptive titles that clearly indicate the work to be done

  • Follow the hierarchy constraints for proper organization

  • Set appropriate status based on current work state

  • Define prerequisites to ensure proper task ordering

  • Include detailed descriptions to provide context for the work

Input Schema

NameRequiredDescriptionDefault
descriptionNoDescription of the object
parentNoParent object ID (optional)
prerequisitesNoArray of prerequisite object IDs (defaults to empty array)
priorityNoPriority level (defaults to 'medium')medium
statusNoStatus of the object (defaults to 'open')open
titleYesTitle of the object
typeYesType of object to create

Input Schema (JSON Schema)

{ "properties": { "description": { "description": "Description of the object", "type": "string" }, "parent": { "description": "Parent object ID (optional)", "type": "string" }, "prerequisites": { "default": [], "description": "Array of prerequisite object IDs (defaults to empty array)", "items": { "type": "string" }, "type": "array" }, "priority": { "default": "medium", "description": "Priority level (defaults to 'medium')", "type": "string" }, "status": { "default": "open", "description": "Status of the object (defaults to 'open')", "type": "string" }, "title": { "description": "Title of the object", "type": "string" }, "type": { "description": "Type of object to create", "type": "string" } }, "required": [ "type", "title" ], "type": "object" }

Implementation Reference

  • Handler function that executes the create object logic for the MCP tool 'create_issue' by parsing arguments and delegating to TaskTrellisService.createObject
    export async function handleCreateObject( service: TaskTrellisService, repository: Repository, args: unknown, ) { const { type, title, parent, priority = "medium", status = "open", prerequisites = [], description = "", } = args as { type: string; title: string; parent?: string; priority?: string; status?: string; prerequisites?: string[]; description?: string; }; // Delegate to service layer return service.createObject( repository, type as TrellisObjectType, title, parent, priority as TrellisObjectPriority, status as TrellisObjectStatus, prerequisites, description, ); }
  • Tool definition for 'create_issue' (create_object functionality) including name, description, and input schema for validation
    export const createObjectTool = { name: "create_issue", description: `Creates a new issue in the task trellis system Use this tool to create new issues such as tasks, projects, or other work items within the task management hierarchy. Issues can have parent-child relationships and dependencies through prerequisites. Available issue types and hierarchy requirements: - 'project': Top-level containers, cannot have a parent - 'epic': Can have no parent or a project as a parent - 'feature': Can have no parent or an epic as a parent - 'task': Can have no parent or a feature as a parent Supported hierarchy structures: - Full hierarchy: project → epic → feature → task - Simplified: epic → feature → task - Simplified: feature → task - Standalone: epic - Standalone: task Available status values: - 'draft': Initial state for new issues - 'open': Ready to begin work (default) - 'open': Ready to begin work - 'in-progress': Currently being worked on - 'done': Completed successfully - 'wont-do': Cancelled or decided against Available priority values: - 'high': Critical or urgent work - 'medium': Standard priority (default) - 'low': Nice-to-have or future work Key aspects: - Issues support hierarchical organization via parent relationships - Prerequisites define execution order dependencies between issues - Parent-child relationships must follow the hierarchy rules above - The system validates parent types during creation Best practices: - Use descriptive titles that clearly indicate the work to be done - Follow the hierarchy constraints for proper organization - Set appropriate status based on current work state - Define prerequisites to ensure proper task ordering - Include detailed descriptions to provide context for the work`, inputSchema: { type: "object", properties: { type: { type: "string", description: "Type of issue to create", }, title: { type: "string", description: "Title of the issue", }, parent: { type: "string", description: "Parent issue ID (optional)", }, priority: { type: "string", description: "Priority level (defaults to 'medium')", default: "medium", }, status: { type: "string", description: "Status of the issue (defaults to 'open')", default: "open", }, prerequisites: { type: "array", items: { type: "string", }, description: "Array of prerequisite issue IDs (defaults to empty array)", default: [], }, description: { type: "string", description: "Description of the issue", }, }, required: ["type", "title"], }, } as const;
  • src/server.ts:256-257 (registration)
    Tool registration in server request handler: maps 'create_issue' tool calls to handleCreateObject
    case "create_issue": return handleCreateObject(_getService(), repository, args);
  • src/server.ts:178-178 (registration)
    Registration of createObjectTool in the list of available tools returned by ListToolsRequest
    createObjectTool,
  • Core helper function implementing the createObject logic: ID generation, object creation, validation, and persistence
    export async function createObject( repository: Repository, type: TrellisObjectType, title: string, parent: string | null = null, priority: TrellisObjectPriority = TrellisObjectPriority.MEDIUM, status: TrellisObjectStatus = TrellisObjectStatus.OPEN, prerequisites: string[] = [], description: string = "", ): Promise<{ content: Array<{ type: string; text: string }> }> { // Get existing objects to generate unique ID const existingObjects = await repository.getObjects(true); const existingIds = existingObjects.map((obj) => obj.id); // Generate unique ID const id = generateUniqueId(title, type, existingIds); // Create TrellisObject with current timestamp const now = new Date().toISOString(); const trellisObject: TrellisObject = { id, type, title, status, priority, parent, prerequisites, affectedFiles: new Map(), log: [], schema: "v1.0", childrenIds: [], created: now, updated: now, body: description, }; // Validate object before saving await validateObjectCreation(trellisObject, repository); // Save through repository await repository.saveObject(trellisObject); return { content: [ { type: "text", text: `Created object with ID: ${id}`, }, ], }; }

Other Tools

Related Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/langadventurellc/task-trellis-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server