import_question
Add questions to LimeSurvey surveys by importing question files into specific survey groups.
Instructions
Import a question to a LimeSurvey survey.
Args:
sid: The survey ID.
gid: The group ID.
question_file: The question file content (base64 encoded).
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| sid | Yes | ||
| gid | Yes | ||
| question_file | Yes |
Implementation Reference
- main.py:509-520 (handler)The handler function for the 'import_question' MCP tool. It is decorated with @mcp.tool(), defining the tool schema via type hints and docstring, and implements the logic by calling the LimeSurvey client's import_question method.@mcp.tool() def import_question(sid: int, gid: int, question_file: str) -> int: """Import a question to a LimeSurvey survey. Args: sid: The survey ID. gid: The group ID. question_file: The question file content (base64 encoded). """ with get_client() as client: return client.import_question(sid, gid, question_file)