People

Search for a list of people

GETpeople/people

This endpoint gives you access to the powerful search and filtering abilities of GoSquared People.

Filters

You can filter the list of returned People using the filters parameter, giving you the ability to fine-tune your query based on the rich tracking information stored in GoSquared.

Results can be filtered on events (see Event Types) or properties (see Property Types).

The filters is somewhat complex so we advise that you look at an existing Smart Group to begin with to see how your pre-existing Smart Groups filter results. Using the Query Builder on the right you can graphically build up a filters object using any combination of filters. You can then see the Example Request below with the generated json query.

Query String Parameters

query

String

The query term you would you like to search for

filters

ObjectDefault Value: []

An array of filters to be applied to the GoSquared People query.

fields

String

A comma delimited list of fields to be returned. (e.g. id,email). See Property Types for available options.

sort

StringDefault Value: last.seen:desc

Which property to sort by followed by :desc or :asc for direction. See Property Types for available options.

presenter

StringDefault Value: plain

Accepted values: plain, csv

Modifies the response data structure

limit

StringDefault Value: 0,10

The maximum number of results e.g. 10 to return with an optional offset e.g. 5,10. You can request a maximum of 250 results

dateFormat

String

The format that any date parameters will be returned in. This takes any value permitted by Moment.

Run in PostmanPostman is a useful developer tool for experimenting with and managing APIs that you work with

Definition

GET https://api.gosquared.com/people/v1/people

Example Request

curl "https://api.gosquared.com/people/v1/people?api_key=demo&site_token=GSN-106863-S" 

Live Responseundefined undefined

Your API Key is not authorised for this endpoint

Please fill in the required fields in the Query Builder

Retrieve a person

GETpeople/people/{personID}

Retrieves a single person by their ID.

Path Parameters

personID

StringRequired

The ID of the person

Run in PostmanPostman is a useful developer tool for experimenting with and managing APIs that you work with

Definition

GET https://api.gosquared.com/people/v1/people/{personID}

Example Request

curl "https://api.gosquared.com/people/v1/people/{personID}?api_key=demo&site_token=GSN-106863-S" 

Live Responseundefined undefined

Your API Key is not authorised for this endpoint

Please fill in the required fields in the Query Builder

Retrieve a list of devices for a person

GETpeople/people/{personID}/devices

Retrieves a paginated list of devices that are associated with a tracked person.

Path Parameters

personID

StringRequired

The ID of the person

Query String Parameters

limit

StringDefault Value: 0,10

The maximum number of results e.g. 10 to return with an optional offset e.g. 5,10. You can request a maximum of 250 results

Run in PostmanPostman is a useful developer tool for experimenting with and managing APIs that you work with

Definition

GET https://api.gosquared.com/people/v1/people/{personID}/devices

Example Request

curl "https://api.gosquared.com/people/v1/people/{personID}/devices?api_key=demo&site_token=GSN-106863-S" 

Live Responseundefined undefined

Your API Key is not authorised for this endpoint

Please fill in the required fields in the Query Builder

Retrieve a feed of events for a person

GETpeople/people/{personID}/feed

Retrieves a list of tracked events associated with a Person in reverse chronological order. This list can be filtered based on the type for events, which are events that you have tracked, and sessionEvents - GoSquared tracking events such as pageviews and session beginning and endings. You can also specify a date range to filter for.

The query parameter allows you to search through a Person's event history based on the name of the event

Path Parameters

personID

StringRequired

The ID of the person

Query String Parameters

query

String

The query term you would you like to search for

sort

StringDefault Value: ts:desc

Which parameter to sort by

type

StringDefault Value: event,sessionEvent

limit

StringDefault Value: 0,10

The maximum number of results e.g. 10 to return with an optional offset e.g. 5,10. You can request a maximum of 250 results

from

String

The start date-time for the query

to

String

The end date-time for the query

Run in PostmanPostman is a useful developer tool for experimenting with and managing APIs that you work with

Definition

GET https://api.gosquared.com/people/v1/people/{personID}/feed

Example Request

curl "https://api.gosquared.com/people/v1/people/{personID}/feed?api_key=demo&site_token=GSN-106863-S" 

Live Responseundefined undefined

Your API Key is not authorised for this endpoint

Please fill in the required fields in the Query Builder