set_survey_properties
Configure survey settings in LimeSurvey by updating properties like title, dates, or access rules for a specific survey ID.
Instructions
Set LimeSurvey survey properties.
Args:
sid: The survey ID.
properties: The properties to set.
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| sid | Yes | ||
| properties | Yes |
Implementation Reference
- main.py:425-434 (handler)The @mcp.tool()-decorated handler function implementing the set_survey_properties tool. It uses a LimeSurvey Client to set the specified properties for the given survey ID.@mcp.tool() def set_survey_properties(sid: int, properties: dict[str, Any]) -> bool: """Set LimeSurvey survey properties. Args: sid: The survey ID. properties: The properties to set. """ with get_client() as client: return client.set_survey_properties(sid, properties)
- main.py:425-425 (registration)The @mcp.tool() decorator registers the set_survey_properties function as an MCP tool.@mcp.tool()
- main.py:15-20 (helper)Helper function to create and return a LimeSurvey Client instance used by the tool handler.def get_client() -> Client: return Client( url=os.getenv("LIMESURVEY_URL"), username=os.getenv("LIMESURVEY_USERNAME"), password=os.getenv("LIMESURVEY_PASSWORD"), )