Skip to main content
GET
/
v1
/
surveys
Retrieve Surveys
curl --request GET \
  --url https://api.sprig.com/v1/surveys \
  --header 'Authorization: <authorization>'
{
  "cursor": "Y3JlYXRlZEF0OjE1NTMyMDAxNTMwMTk=",
  "data": [
    {
      "completedAt": "2019-06-12T19:23:35.522Z",
      "constraints": [
        {
          "comparisonType": "gte",
          "event": null,
          "type": "SESSION_COUNT",
          "value": 1
        },
        {
          "comparisonType": "eq",
          "event": null,
          "type": "TIME_ON_PAGE_DELAY",
          "value": 2
        }
      ],
      "createdAt": "2018-07-18T08:02:09.858Z",
      "id": 12,
      "launchedAt": null,
      "name": "Understand Appeal",
      "platform": "web",
      "questions": [
        {
          "id": 118,
          "options": [],
          "optionsProperties": {
            "introText": "Thanks for using Sprig. Tell us about your experience.",
            "labels": {
              "left": "Not at all interested",
              "right": "Extremely interested"
            }
          },
          "questionText": "How interested are you in using Sprig?",
          "routingOptions": null,
          "type": "LIKERT"
        },
        {
          "id": 105,
          "options": [],
          "optionsProperties": null,
          "questionText": "What aspect of Sprig is most appealing?",
          "routingOptions": null,
          "type": "OPEN"
        }
      ],
      "status": "COMPLETED",
      "totalResponseLimit": null,
      "type": "CONTINUOUS",
      "updatedAt": "2019-06-12T19:23:35.522Z"
    }
  ]
}

Documentation Index

Fetch the complete documentation index at: https://docs.sprig.com/llms.txt

Use this file to discover all available pages before exploring further.

Headers

Authorization
string
required

Bearer YOUR_API_KEY

Query Parameters

start
integer

The earliest creation data for a generated theme to return, represented as milliseconds from epoch time

end
integer

The latest creation date for a generated theme to return, represented as milleseconds from epoch time

cursor
string

A Base64 encoded string representing an opaque cursor position

status
enum<string>[]

One or many of (IN_PROGRESS, PAUSED, COMPLETED, DRAFT, ARCHIVED, NEW). Can be passed as ?status=PAUSED,COMPLETED, ?status[]=PAUSED&status[]=COMPLETED or ?status=PAUSED&status=COMPLETED

Available options:
IN_PROGRESS,
PAUSED,
COMPLETED,
DRAFT,
ARCHIVED,
NEW
limit
integer

Specific number of results to return

Required range: 1 <= x <= 1000

Response

OK

cursor
string
Minimum string length: 1
data
object[]
Minimum array length: 1