Skip to main content
Glama
pixxelboy

IRCAM Amplify MCP Server

by pixxelboy

check_job_status

Monitor async audio processing job status and retrieve results. Track progress percentage and completion state for operations like stem separation and analysis.

Instructions

Check the status of an async processing job. Use this to monitor jobs returned by separate_stems and other async operations. Returns job status (pending, processing, completed, failed), progress percentage, and results when completed.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
job_idYesThe job ID returned by an async operation

Implementation Reference

  • The handler function that executes the core logic of the check_job_status tool: validates the job_id, queries the IRCAM API for status, formats the response with status, progress, results (for stem separation), or errors.
    export async function handleCheckJobStatus(
      args: Record<string, unknown>
    ): Promise<JobStatusOutput> {
      const jobId = args.job_id as string;
    
      // Validate input
      const validation = validateJobId(jobId);
      if (!validation.valid) {
        throw validation.error;
      }
    
      // Call IRCAM Job Status API
      const url = buildApiUrl(`${IRCAM_API_CONFIG.ENDPOINTS.JOB_STATUS}/${jobId}`);
      const response = await httpGet<IrcamJobStatusResponse>(url);
    
      if (!response.ok || !response.data) {
        throw response.error || formatError('JOB_NOT_FOUND', 'Job not found');
      }
    
      const job = response.data;
    
      // Build job state response
      const result: JobStatusOutput = {
        status: job.status,
        progress: job.progress,
      };
    
      // Add result if completed (assuming stem separation result)
      if (job.status === 'completed' && job.result) {
        const stemResult = job.result as {
          stems?: {
            vocals?: { url: string };
            drums?: { url: string };
            bass?: { url: string };
            other?: { url: string };
          };
        };
    
        if (stemResult.stems) {
          result.result = {
            vocals_url: stemResult.stems.vocals?.url || '',
            drums_url: stemResult.stems.drums?.url || '',
            bass_url: stemResult.stems.bass?.url || '',
            other_url: stemResult.stems.other?.url || '',
          } as StemSeparationResult;
        }
      }
    
      // Add error if failed
      if (job.status === 'failed' && job.error) {
        result.error = job.error;
      }
    
      return result;
    }
  • The Tool object definition for check_job_status, including name, description, and inputSchema for MCP tool listing and validation.
    export const checkJobStatusTool: Tool = {
      name: 'check_job_status',
      description:
        'Check the status of an async processing job. ' +
        'Use this to monitor jobs returned by separate_stems and other async operations. ' +
        'Returns job status (pending, processing, completed, failed), progress percentage, and results when completed.',
      inputSchema: {
        type: 'object',
        properties: {
          job_id: {
            type: 'string',
            description: 'The job ID returned by an async operation',
          },
        },
        required: ['job_id'],
      },
    };
  • src/index.ts:37-43 (registration)
    Registration of checkJobStatusTool in the TOOLS array, used by MCP server for listTools requests.
    const TOOLS = [
      analyzeMusicTool,
      separateStemsTool,
      detectAiMusicTool,
      analyzeLoudnessTool,
      checkJobStatusTool,
    ];
  • src/index.ts:48-54 (registration)
    Mapping of tool name 'check_job_status' to its handler function handleCheckJobStatus in the TOOL_HANDLERS object, used for tool call execution.
    const TOOL_HANDLERS: Record<string, (args: Record<string, unknown>) => Promise<unknown>> = {
      analyze_music: handleAnalyzeMusic,
      separate_stems: handleSeparateStems,
      detect_ai_music: handleDetectAiMusic,
      analyze_loudness: handleAnalyzeLoudness,
      check_job_status: handleCheckJobStatus,
    };
  • TypeScript type definitions for JobStatusInput and JobStatusOutput used in the check_job_status tool for input/output validation and typing.
    /**
     * Input pour vérification de statut
     */
    export interface JobStatusInput {
      /** ID du job à vérifier */
      job_id: string;
    }
    
    /**
     * Output de check_job_status
     * Le type du result dépend de l'opération originale
     */
    export type JobStatusOutput = JobState<StemSeparationResult>;
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations provided, the description carries the full burden. It discloses the tool's behavior by stating it returns job status, progress percentage, and results when completed, which is useful context. However, it lacks details on error handling, polling frequency, or timeouts, which are important for a monitoring tool.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is appropriately sized and front-loaded, with two sentences that efficiently convey purpose, usage, and return values without any wasted words. Every sentence earns its place by adding essential information.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the tool's moderate complexity (monitoring async jobs), no annotations, and no output schema, the description is fairly complete—it explains what the tool does, when to use it, and what it returns. However, it could benefit from more behavioral details like error cases or response structure to fully compensate for the lack of structured data.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, so the schema already documents the job_id parameter. The description adds minimal value by mentioning it's 'returned by an async operation,' but doesn't provide additional syntax or format details beyond what the schema implies, meeting the baseline for high coverage.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the tool's purpose with specific verb ('check') and resource ('status of an async processing job'), and distinguishes it from siblings by mentioning it monitors jobs returned by 'separate_stems' and other async operations, which are different from analysis/detection tools.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides clear context on when to use this tool ('to monitor jobs returned by separate_stems and other async operations'), but does not explicitly state when not to use it or name specific alternatives for job monitoring, leaving some guidance gaps.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other 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/pixxelboy/amplify-mcp'

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