Mixin for ViewSets to handle approval-gate exceptions raised from decorated serializers.
Intercepts ApprovalRequired (409) and PolicyConflict (400) raised by the @approval_gate decorator on serializer methods and converts them into the same responses the viewset path produces (see decorators._result_to_response), so both paths share one contract.
Request
- Base URL: https://us.posthog.com
- URL: https://us.posthog.com/api/projects/{project_id}/surveys/
- Auth: HTTP bearer
Path parameters
Project ID of the project you're trying to access. To find the ID of the project, make a call to /api/projects/.
Query parameters
Filter surveys by the ID of the user who created them.
Multiple values may be separated by commas.
Number of results to return per page.
The initial index from which to return the results.
Match against survey name and description. Returns exact (case-insensitive substring) matches only; if no exact match exists, returns similar (fuzzy trigram — typos, prefix-as-you-type) matches instead. Each result's search_match_type is exact or similar.
Filter surveys by their current status.
- draft - Draft
- running - Running
- complete - Complete
- popover - popover
- widget - widget
- external_survey - external survey
- api - api
Response
Example response
{
"count": 123,
"next": "http://api.example.org/accounts/?offset=400&limit=100",
"previous": "http://api.example.org/accounts/?offset=200&limit=100"
}Changes
No recorded changes to this operation across all 1 revision of this API.