Get list of roles for a specific segment by policy Id and segment Id

get

/PASService/rest/services/v1/policies/{policyId}/segments/{segmentId}/roles

Gets a list of roles associated to a segment based on the specified segment Id

Request

Path Parameters

There's no request body for this operation.

Back to Top

Response

Supported Media Types

200 Response

This operation fetches list of roles for a specific segment by policy Id and segment Id successfully.
Back to Top

Examples

This example describes how to get a list of roles associated to a segment based on the specified segment Id.

Example cURL Command

Use the following cURL command to submit a request on the REST resource:

curl \ 
    -X GET \ 
    -H "Content-Type: application/json" \   
    -u 'Authorization: Basic dXNlcm5hbWU6cGFzc3dvcmQ=' \  
	-L "http://server:port/PASService/rest/services/v1/policies/989BB237-1C7C-4BE1-A746-F945C236B3F1
	/segments/DFF67AC3-D712-4ED4-9AF2-C2AA58C3F0F0/roles"

Note:

The response example given below is of dynamic nature and depends on the configuration.

Example Response Body

The following shows an example of the response body in JSON format.

{
    "count": 1,
    "offset": 0,
    "limit": 100,
    "roles": [
        {
            "links": [
                {
                    "href": "http://server:port/PASService/rest/services/v1/roles/0CA1DDA5-7683-42DA-837F-1EE0E45D05B4",
                    "rel": "self",
                    "mediaType": "application/json",
                    "method": "GET"
                },
                {
                    "href": "http://server:port/PASService/rest/services/v1/codes?codeName=PercentDollar&codeValue=C",
                    "rel": "codes/percentDollar",
                    "mediaType": "application/json",
                    "method": "GET"
                },
                {
                    "href": "http://server:port/PASService/rest/services/v1/codes?codeName=Role&codeValue=72",
                    "rel": "codes/role",
                    "mediaType": "application/json",
                    "method": "GET"
                },
                {
                    "href": "http://server:port/PASService/rest/services/v1/codes?codeName=State&codeValue=CA",
                    "rel": "codes/stateCode",
                    "mediaType": "application/json",
                    "method": "GET"
                },
                {
                    "href": "http://server:port/PASService/rest/services/v1/codes?codeName=RoleStatus&codeValue=01",
                    "rel": "codes/status",
                    "mediaType": "application/json",
                    "method": "GET"
                }
            ],
            "multiFields": {},
            "roleAmount": 12.0,
            "rolePercent": 100.0,
            "stateCode": "CA",
            "roleId": "0CA1DDA5-7683-42DA-837F-1EE0E45D05B4",
            "clientId": "37D2EEE3-8624-48C6-981F-2B2891CDB852",
            "externalclientId": "280D55E1-4BC6-4CA0-9AD2-BE6761DB55FC",
            "companyId": "7560150B-BA78-45EF-8747-209DCB9BB94D",
            "percentDollar": "C",
            "policyId": "F8CC7B38-95F9-4240-A528-B890AF87188C",
            "role": "72",
            "segmentId": "D01AA0A5-D21E-44ED-8035-D3CBB276F883",
            "status": "01"
        }
    ]
}

Back to Top