Project Survey History

Get a Project Survey's History

This endpoint retrieves a list of all logged updates to the Project Survey associated with the project with id "project_id".

GET /api/v2/projects/{project_id}/survey/history/

GET /api/v2/projects/1/survey/history/ HTTP/1.1
Accept: application/json
Authorization: Token "YOUR SDE ACCESS TOKEN"
HTTP/1.1 200 OK
Content-Type: application/json

{
    "results": [{
        "project": 1,
        "answer": "A1",
        "actor": 5,
        "draft": true,
        "transition": "select",
        "reason": "manual",
        "time_stamp": "2020-04-08T12:38:08.115521-04:00"
    }]
}

Query Parameters

The following parameters may be used to filter the project survey history log entries in the response:

Parameter Description
answer Returns history for specified answer. Supports multiple answers.
latest Returns only the most recent update for each answer.
draft If true, returns history for updates to project survey drafts only. If false, returns history for updates to project surveys only.

Expand Parameters

See the Expand Parameters section for more details.

Parameter Description
actor Actor field is expanded into id, first name, last name, email, role, active status, super user status, last login, date joined, and groups sub-fields.

GET /api/v2/projects/1/survey/history/?include=tags&expand=actor HTTP/1.1
Accept: application/json
Authorization: Token "YOUR SDE ACCESS TOKEN"
HTTP/1.1 200 OK
Content-Type: application/json

{
    "results": [{
        "project": 1,
        "answer": "A1",
        "actor": {
            "id": 5,
            "email": "hamish.stout@example.com",
            "first_name": "Hamish",
            "last_name": "Stout",
            "last_login": "2020-04-14T09:11:18.482369-04:00",
            "date_joined": "2011-05-25T11:37:55-04:00",
            "is_active": true,
            "is_superuser": false,
            "role": {
                "id": "UR1",
                "name": "User"
            },
            "groups": []
        },
        "draft": true,
        "transition": "select",
        "reason": "manual",
        "time_stamp": "2020-04-08T12:38:08.115521-04:00"
    }]
}

results matching ""

    No results matching ""