Skip to main content
Glama

describeDocProcessJob

Retrieve document conversion job results by providing the job ID to track processing status and access completed outputs.

Instructions

根据 jobid 查询指定的文档转码任务结果

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
jobIdYes要查询的任务ID,可通过提交文档任务的响应中获取。

Implementation Reference

  • Implementation of the describeDocProcessJob method in CIDocService, which queries the status of a document processing job using Tencent Cloud COS CI API.
    async describeDocProcessJob(jobId: string) {
      try {
        let host = this.bucket + '.ci.' + this.region + '.myqcloud.com';
        let url = 'https://' + host + '/doc_jobs/' + jobId;
        const result = await new Promise((resolve, reject) => {
          this.cos.request(
            {
              Bucket: this.bucket, // Bucket 格式:test-1250000000
              Region: this.region,
              Method: 'GET',
              Key: 'doc_jobs/' + jobId,
              Url: url,
            },
            function (error, data) {
              if (error) {
                // 处理请求失败
                reject(error);
              } else {
                // 处理请求成功
                resolve(data);
                //获取返回的jobid, 去调查询任务接口, 返回具体信息
              }
            },
          );
        });
    
        return {
          isSuccess: true,
          message: '文档转pdf成功',
          data: result,
        };
      } catch (error) {
        return {
          isSuccess: false,
          message: '文档转pdf失败',
          data: error,
        };
      }
    }
  • src/server.ts:551-570 (registration)
    MCP tool registration for 'describeDocProcessJob', defining input schema (jobId: string) and delegating to CIDocInstance.describeDocProcessJob.
    server.tool(
      'describeDocProcessJob',
      '根据 jobid 查询指定的文档转码任务结果',
      {
        jobId: z
          .string()
          .describe('要查询的任务ID,可通过提交文档任务的响应中获取。'),
      },
      async ({ jobId }) => {
        const res = await CIDocInstance.describeDocProcessJob(jobId);
        return {
          content: [
            {
              type: 'text',
              text: JSON.stringify(res.data, null, 2),
            },
          ],
          isError: !res.isSuccess,
        };
      },
  • Input schema for the tool: jobId as a string.
    jobId: z
      .string()
      .describe('要查询的任务ID,可通过提交文档任务的响应中获取。'),
Behavior2/5

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

No annotations are provided, so the description carries the full burden of behavioral disclosure. It states this is a query operation, implying it's read-only and non-destructive, but doesn't mention any behavioral traits such as authentication requirements, rate limits, error handling, or what the output looks like (e.g., job status, result data). For a tool with zero annotation coverage, this is a significant gap, though it's not contradictory.

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

Conciseness4/5

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

The description is a single, concise sentence that directly states the tool's purpose without unnecessary words. It's appropriately sized for a simple query tool, though it could be slightly more informative (e.g., by front-loading key details like output format). There's no wasted text, earning a high score for efficiency.

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

Completeness2/5

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

Given the tool's complexity (a query operation with one parameter), lack of annotations, and no output schema, the description is incomplete. It doesn't explain what the tool returns (e.g., job status, result data, error messages), which is critical for an agent to use it correctly. The description alone is insufficient for full contextual understanding, resulting in a low score.

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?

The input schema has 100% description coverage, with the parameter 'jobId' fully documented in the schema ('要查询的任务ID,可通过提交文档任务的响应中获取'). The description adds no additional parameter semantics beyond what the schema provides, such as format examples or constraints. With high schema coverage, the baseline score is 3, as the description doesn't compensate but doesn't detract either.

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

Purpose4/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: '根据 jobid 查询指定的文档转码任务结果' (Query the specified document transcoding task result based on jobid). It specifies the verb '查询' (query) and the resource '文档转码任务结果' (document transcoding task result). However, it doesn't explicitly differentiate from sibling tools like 'describeMediaJob' or 'createDocToPdfJob', which prevents a score of 5.

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

Usage Guidelines2/5

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

The description provides minimal usage guidance: it implies this tool is used after a job is submitted (via '可通过提交文档任务的响应中获取' in the schema). However, it doesn't specify when to use this tool versus alternatives like 'describeMediaJob' for media jobs or 'createDocToPdfJob' for creating jobs, nor does it mention prerequisites or exclusions. This lack of explicit context guidance results in a low score.

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/xiaomizhoubaobei/MCP'

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