asana_get_project
Retrieve detailed information about a specific Asana project by providing its project ID, including optional fields for customized data.
Instructions
Get detailed information about a specific project
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| project_id | Yes | The project ID to retrieve | |
| opt_fields | No | Comma-separated list of optional fields to include |
Implementation Reference
- src/tool-handler.ts:198-204 (handler)The switch case handler that executes the "asana_get_project" tool by destructuring arguments, calling the AsanaClientWrapper.getProject method, and returning the JSON-stringified response.case "asana_get_project": { const { project_id, ...opts } = args; const response = await asanaClient.getProject(project_id, opts); return { content: [{ type: "text", text: JSON.stringify(response) }], }; }
- src/asana-client-wrapper.ts:424-429 (helper)Core implementation in AsanaClientWrapper that wraps the Asana SDK ProjectsApi.getProject call to fetch project details using the provided project ID and optional fields.async getProject(projectId: string, opts: any = {}) { // Only include opts if opt_fields was actually provided const options = opts.opt_fields ? opts : {}; const response = await this.projects.getProject(projectId, options); return response.data; }
- src/tools/project-tools.ts:45-62 (schema)Defines the Tool metadata including name, description, and inputSchema requiring 'project_id' for the asana_get_project tool.export const getProjectTool: Tool = { name: "asana_get_project", description: "Get detailed information about a specific project", inputSchema: { type: "object", properties: { project_id: { type: "string", description: "The project ID to retrieve" }, opt_fields: { type: "string", description: "Comma-separated list of optional fields to include" } }, required: ["project_id"] } };
- src/tool-handler.ts:61-103 (registration)Registers the getProjectTool (imported from project-tools.js) in the central tools array used for MCP tool discovery.export const tools: Tool[] = [ listWorkspacesTool, searchProjectsTool, getProjectTool, getProjectTaskCountsTool, getProjectSectionsTool, createSectionForProjectTool, createProjectForWorkspaceTool, updateProjectTool, reorderSectionsTool, getProjectStatusTool, getProjectStatusesForProjectTool, createProjectStatusTool, deleteProjectStatusTool, searchTasksTool, getTaskTool, createTaskTool, updateTaskTool, createSubtaskTool, getMultipleTasksByGidTool, addTaskToSectionTool, getTasksForSectionTool, getProjectHierarchyTool, getSubtasksForTaskTool, getTasksForProjectTool, getTasksForTagTool, getTagsForWorkspaceTool, addTagsToTaskTool, addTaskDependenciesTool, addTaskDependentsTool, setParentForTaskTool, addFollowersToTaskTool, getStoriesForTaskTool, createTaskStoryTool, getTeamsForUserTool, getTeamsForWorkspaceTool, addMembersForProjectTool, addFollowersForProjectTool, getUsersForWorkspaceTool, getAttachmentsForObjectTool, uploadAttachmentForObjectTool, downloadAttachmentTool ];