Documentation Sweet Pricing API

GET / segments / :segmentId

This endpoint provides a segment's name, and a series of filters that define the segment. Each filter has a type, field and one or more parameters.



Field Type Description
Authorization String

Header of form api-key <API key>

Authorization: api-key <API Key>


Field Type Description
:segmentId Number

Segment ID


Field Type Description
id Number

Segment ID

appId Number

App ID

name String

User-defined segment name

segmentfilters Object[]

Array of the filters that are applicable.

segmentfilters.isNegated Boolean

True if the filter is negated.

segmentfilters.filterfieldFiltertype Object String

Id of the filterfield-filtertype combination applied.

segmentfilters.filterfieldFiltertype.filtertype Object
segmentfilters.filterfieldFiltertype.filtertype.isStringExact Boolean

Is this string exactly matches filter?

segmentfilters.filterfieldFiltertype.filtertype.isStringContains Boolean

Is this string contains filter?

segmentfilters.filterfieldFiltertype.filtertype.isStringStartsWith Boolean

Is this string starts with filter?

segmentfilters.filterfieldFiltertype.filtertype.isStringEndsWith Boolean

Is this string ends with filter?

segmentfilters.filterfieldFiltertype.filtertype.isStringSet Boolean

Is this string contained in set filter?

segmentfilters.filterfieldFiltertype.filtertype.isIntEqual Boolean

Is this integer exactly equals filter?

segmentfilters.filterfieldFiltertype.filtertype.isIntGt Boolean

Is this integer greater than filter?

segmentfilters.filterfieldFiltertype.filtertype.isIntLt Boolean

Is this integer less than filter?

segmentfilters.filterfieldFiltertype.filterfield Object
segmentfilters.filterfieldFiltertype.filterfield.fieldName String

Name of the field that is used in the filter.

segmentfilters.params Object[]

Array of the parameters values to the filter. These are objects.

segmentfilters.params.value Mixed

Value of the parameter.

	"id": 2,
	"name": "Engagement > 80",
	"segmentfilters": [{
		"isNegated": false,
		"filterfieldFiltertype": {
			"id": 2,
			"filtertype": {
				"isStringExact": false,
				"isStringContains": false,
				"isStringStartsWith": false,
				"isStringEndsWith": false,
				"isStringSet": false,
				"isIntEqual": false,
				"isIntGt": true,
				"isIntLt": false
			"filterfield": {
				"fieldName": "engagement14"
		"params": [{
			"value": 80


Name Description

You are not authenticated to perform the request.


Name Description

You are not allowed to view/modify this resource.


Name Description

Resource not found.