Skip to main content
Glama
jfrog

JFrog MCP Server

Official
by jfrog

jfrog_check_availability

Verify the operational status of the JFrog platform to ensure it is ready and functioning correctly.

Instructions

Check if JFrog platform is ready and functioning or not

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • Core implementation of the JFrog platform availability check: sends GET request to /artifactory/api/v1/system/readiness and parses response with schema.
    export async function checkPlatformReadiness() { const response = await jfrogRequest("/artifactory/api/v1/system/readiness", { method: "GET", }); return JFrogPlatformReadinessSchema.parse(response); }
  • Tool registration object defining name, description, input schema (empty), and thin handler wrapper calling checkPlatformReadiness.
    const checkJfrogAvailabilityTool = { name: "jfrog_check_availability", description: "Check if JFrog platform is ready and functioning or not", inputSchema: zodToJsonSchema(z.object({})), //outputSchema: zodToJsonSchema(JFrogPlatformReadinessSchema), handler: async () => { return await checkPlatformReadiness(); } };
  • Zod schema for parsing the JFrog platform readiness API response (output schema).
    export const JFrogPlatformReadinessSchema= z.object({ code: z.string() }); export type JFrogPlatformReadinessSchema = z.infer<typeof JFrogPlatformReadinessSchema>;
  • Export of RepositoryTools array registering the jfrog_check_availability tool among repository tools.
    export const RepositoryTools =[ checkJfrogAvailabilityTool, createLocalRepositoryTool, createRemoteRepositoryTool, createVirtualRepositoryTool, setFolderPropertyTool, listRepositoriesTool ];
  • HTTP request utility jfrogRequest used by the handler to communicate with JFrog API, handling auth via env vars and errors.
    export async function jfrogRequest( urlPath: string, options: RequestOptions = {}, postProcess: (data: unknown) => unknown = (x) => x ): Promise<unknown> { const headers: Record<string, string> = { "Content-Type": "application/json", "User-Agent": USER_AGENT, ...options.headers, }; if (process.env.JFROG_ACCESS_TOKEN) { headers["Authorization"] = `Bearer ${process.env.JFROG_ACCESS_TOKEN}`; } const baseUrl = normalizeJFrogBaseUrl(process.env.JFROG_URL || ""); const path = urlPath.startsWith("/") ? urlPath.substring(1) : urlPath; const url = baseUrl ? `${baseUrl}${path}` : urlPath; try { const axiosConfig: AxiosRequestConfig = { method: options.method || "GET", url, headers, data: options.body, }; const response = await axios(axiosConfig); return postProcess(response.data); return response.data; } catch (error) { if (axios.isAxiosError(error) && error.response) { throw createJFrogError(error.response.status, error.response.data); } throw error; } }

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/jfrog/mcp-jfrog'

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