Skip to main content
Glama

创建LMS单元

classin_create_unit

Creates a new LMS learning unit under a course. Provide course ID and unit name; optionally set content and publish status (draft or published).

Instructions

在课程下创建LMS学习单元。

注意: 使用 API v2,课程下不支持创建同名单元。

参数:

  • courseId: 课程ID

  • name: 单元名称(最长50字符)

  • content: 单元介绍(可选)

  • publishFlag: 发布状态 (0=草稿, 2=已发布,默认2)

返回:

  • 成功返回单元ID

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
nameYes单元名称,最长50字符,课程下不支持创建同名单元
contentNo单元介绍
courseIdYes课程ID,通过创建课程接口获得
publishFlagNo发布状态: 0=草稿, 2=已发布
response_formatNo输出格式: 'markdown' 人类可读格式 或 'json' 机器可读格式markdown
Behavior4/5

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

Annotations already indicate a write operation (readOnlyHint=false). The description adds valuable context: it uses API v2, enforces uniqueness of unit names under a course, and returns the unit ID on success. These details go beyond the annotation hints and help set expectations.

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

Conciseness3/5

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

The key information is front-loaded (purpose and unique constraint), but the '参数' section redundantly restates the schema details for every parameter. This makes the description longer than necessary and reduces conciseness.

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?

The tool has 5 parameters and no output schema, and the description covers the essential aspects: creation context, uniqueness constraint, return value, and the publishFlag semantics. It does not explain error behavior or response format details, but the schema covers all parameters, so the overall picture is reasonably complete.

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 fully documents all parameters. The description's parameter list largely repeats the schema definitions without adding new meaning. The only added context is the API v2 note, which is not parameter-specific, so a baseline score of 3 is appropriate.

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 '在课程下创建LMS学习单元' (create LMS unit under course), using a specific verb and resource. This distinguishes it from sibling tools like update_unit and delete_unit, which modify or remove units.

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 for when to use this tool (creating a unit under a course) and includes a constraint (no same-name units under a course). However, it does not explicitly mention alternatives or exclusions, so it stops short of a 5.

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/yuanlang12/classin-mcp-server'

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