coolify_list_teams
Retrieve a complete list of all teams managed within the Coolify infrastructure platform for team operations and access management.
Instructions
List all teams
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||
Implementation Reference
- src/tools.ts:22-40 (schema)Tool schema for 'coolify_teams' which includes 'list' action to list all teams.{ name: 'coolify_teams', description: 'Complete team management - list teams, get current team, get team details, and list team members', inputSchema: { type: 'object', properties: { action: { type: 'string', enum: ['list', 'current', 'get', 'members'], description: 'Action to perform: list (list all teams), current (get current team), get (get specific team), members (list team members)' }, team_id: { type: 'string', description: 'Team ID (required for get and members actions, optional for others)' }, }, required: ['action'], }, },
- src/handlers.ts:32-51 (handler)The 'teams' handler method implements all actions for coolify_teams tool. The 'list' case (lines 34-36) fetches and returns the list of teams from the Coolify API endpoint '/teams'.async teams(action: string, teamId?: string) { switch (action) { case 'list': const response = await this.apiClient.get('/teams'); return { content: [{ type: 'text', text: JSON.stringify(response.data, null, 2) }] }; case 'current': const currentResponse = await this.apiClient.get('/teams/current'); return { content: [{ type: 'text', text: JSON.stringify(currentResponse.data, null, 2) }] }; case 'get': if (!teamId) throw new Error('Team ID is required for get action'); const getResponse = await this.apiClient.get(`/teams/${teamId}`); return { content: [{ type: 'text', text: JSON.stringify(getResponse.data, null, 2) }] }; case 'members': const endpoint = teamId ? `/teams/${teamId}/members` : '/teams/current/members'; const membersResponse = await this.apiClient.get(endpoint); return { content: [{ type: 'text', text: JSON.stringify(membersResponse.data, null, 2) }] }; default: throw new Error(`Unknown teams action: ${action}`); } }
- src/index.ts:92-94 (registration)Registration of the 'coolify_teams' tool in the main tool call handler switch statement, dispatching to handlers.teams() method.case 'coolify_teams': return await this.handlers.teams(args.action, args.team_id);
- src/api-client.ts:67-76 (helper)The CoolifyAPIClient.get() method used by the teams handler to fetch the list of teams from '/teams' endpoint.async get<T = any>(endpoint: string, params?: Record<string, any>): Promise<CoolifyResponse<T>> { const response = await this.getInstance().get(endpoint, { params }); return { data: response.data, status: response.status, statusText: response.statusText, }; } async post<T = any>(endpoint: string, data?: any): Promise<CoolifyResponse<T>> {