Unify and manage your data

Get count of profiles in segment

Learn more about the Segmentation Api to find out the total number of profiles in a segment.

Use the Segments to return the total number of profiles in a segment.

HTTP method and endpoint

Use the following HTTP method and endpoint path to retrieve the count of profiles in a segment.

GET {platformUrl}/api/{tenantId}/segments/{id}/entities/total

Replace {platformUrl} with your Reltio platform base URL and {tenantId} with your tenant ID.

The following table describes the endpoint path parameters.

ParameterTypeRequiredDescription
tenantIdStringYesUnique identifier of the tenant.
idStringYesUnique identifier of the segment.

Query parameters

The following table describes the query parameters and their values.

ParameterTypeRequiredDescriptionAccepted values / Default
returnPartialResultsBooleanNoWhen set to true and the segment's status is submitted or in_progress, the response returns the count that currently exists instead of returning the SEGMENT_NOT_EVALUATED error. When set to false or omitted, the response returns profiles only after the segment has finished evaluating.true, false; Default: false

Request headers

The following request headers must be included.

HeaderValueRequired
AuthorizationBearer <access_token>Yes
Content-Typeapplication/jsonYes

Request body

This operation does not require a request body.

Example request

Use the following example to retrieve the count of profiles in a segment. Replace the sample values with values from your environment.

GET {platformUrl}/api/ce5627DYnQ6abcD/segments/3prE0YZ/entities/total

Response body

The following table describes the field returned in the response body.

FieldTypeDescription
totalIntegerTotal number of profiles in the segment.

Example response

The following example shows a response with the total number of profiles in the segment.

{
  "total": 12345
}

The following table lists the possible error responses returned by this API.

HTTP statusError codeDescriptionRecommended action
400 Bad Request32006The segment has not finished evaluating and returnPartialResults was not set to true.Retry the request after the segment finishes evaluating, or resend the request with returnPartialResults set to true to receive the count that currently exists.