delete_participants
Remove specific participants from a LimeSurvey survey by providing the survey ID and participant tokens. Simplifies participant management in survey administration.
Instructions
Delete participants from a LimeSurvey survey.
Args:
sid: The survey ID.
tokens: The participant tokens.
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| sid | Yes | ||
| tokens | Yes |
Implementation Reference
- main.py:572-582 (handler)The primary handler function for the 'delete_participants' MCP tool. It is decorated with @mcp.tool(), which handles registration and schema inference from type hints and docstring. The function creates a LimeSurvey client and calls its delete_participants method.@mcp.tool() def delete_participants(sid: int, tokens: list[str]) -> bool: """Delete participants from a LimeSurvey survey. Args: sid: The survey ID. tokens: The participant tokens. """ with get_client() as client: return client.delete_participants(sid, tokens)
- main.py:15-20 (helper)Helper function used by the tool handler to create a Citric LimeSurvey Client instance from environment variables.def get_client() -> Client: return Client( url=os.getenv("LIMESURVEY_URL"), username=os.getenv("LIMESURVEY_USERNAME"), password=os.getenv("LIMESURVEY_PASSWORD"), )