list-applications
Retrieve a comprehensive list of all applications managed by Coolify to monitor and manage deployments efficiently using the Coolify MCP Server interface.
Instructions
Fetch a list of all applications currently managed by Coolify. This provides an overview of all deployed applications.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||
Input Schema (JSON Schema)
{
"$schema": "http://json-schema.org/draft-07/schema#",
"additionalProperties": false,
"properties": {},
"type": "object"
}
Implementation Reference
- src/index.ts:159-167 (handler)Handler for the 'list-applications' tool. Fetches the list of applications from the Coolify API endpoint '/applications' and returns the JSON-formatted response as text content.case "list-applications": { const apps = await coolifyApiCall('/applications'); return { content: [{ type: "text", text: JSON.stringify(apps, null, 2) }] }; }
- src/index.ts:89-92 (registration)Registration of the 'list-applications' tool in the list of available tools, including its name, description, and empty input schema.name: "list-applications", description: "Fetch a list of all applications currently managed by Coolify. This provides an overview of all deployed applications.", inputSchema: zodToJsonSchema(z.object({})), },
- src/index.ts:24-47 (helper)Shared helper function used by the 'list-applications' handler (and others) to make authenticated API calls to the Coolify server.async function coolifyApiCall(endpoint: string, method: string = 'GET', body?: any): Promise<any> { const baseUrl = process.env.COOLIFY_BASE_URL?.replace(/\/$/, '') || 'https://coolify.stuartmason.co.uk'; const url = `${baseUrl}/api/v1${endpoint}`; const response = await fetch(url, { method, headers: { 'Authorization': `Bearer ${process.env.COOLIFY_ACCESS_TOKEN}`, 'Content-Type': 'application/json', }, body: body ? JSON.stringify(body) : undefined, }); if (!response.ok) { const errorBody = await response.json().catch(() => ({})); throw new Error(JSON.stringify({ error: `Coolify API error: ${response.status} ${response.statusText}`, status: response.status, details: errorBody })); } return await response.json(); }