import_cpdb_participants
Transfer participants from the central database to a specified LimeSurvey survey, filtering by specific attributes to streamline survey targeting.
Instructions
Import participants from the central participant database.
Args:
sid: The survey ID.
attributes: The attributes to filter participants.
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| attributes | Yes | ||
| sid | Yes |
Implementation Reference
- main.py:611-621 (handler)The handler function for the 'import_cpdb_participants' MCP tool. It is decorated with @mcp.tool() which handles registration and schema from the type annotations. The logic retrieves a client via get_client() and calls client.import_cpdb_participants(sid, attributes).@mcp.tool() def import_cpdb_participants(sid: int, attributes: dict[str, Any]) -> dict[str, Any]: """Import participants from the central participant database. Args: sid: The survey ID. attributes: The attributes to filter participants. """ with get_client() as client: return client.import_cpdb_participants(sid, attributes)