Get list of segments for a policy
get
/PASService/rest/services/policies/{id}/segments
Gets a list of the latest 100 segments for a policy based on the specified policy Id
Request
Path Parameters
-
id: string
Pattern:
\{?[0-9A-F]{8}-[0-9A-F]{4}-[0-9A-F]{4}-[0-9A-F]{4}-[0-9A-F]{12}\}?
Policy Id
Query Parameters
-
expand(optional): string
codes
Response
Supported Media Types
- application/json
Default Response
successful operation
Examples
This example describes how to get a list of the latest 100 segments for a policy based on the specified policy Id.
Example cURL Command
Use the following cURL command to submit a request on the REST resource:
curl -X GET -H "Accept: application/json" -u username:password "server:port/PASService/rest/services/policies/B6780DC5-D0DE-431B-B049-82DBEE3C7D80/segments"
Example Response Body
The following shows an example of the response body in JSON format:
"{ "count": 1, "segments": [ { "links": [ { "href": "http://server:port/PASService/rest/services/policies/B6780DC5-D0DE-431B-B049-82DBEE3C7D80/segments/A3046709-CF2E-4AFF-A4B9-D65C4769F838", "rel": "self", "mediaType": "application/json", "method": "GET" }, { "href": "http://server:port/PASService/rest/services/codes?codeName=Status&codeValue=24", "rel": "codes/status", "mediaType": "application/json", "method": "GET" } ], "multiFields": {}, "effectiveDate": "2015-08-04T00:00:00Z", "roles": [], "segmentId": "A3046709-CF2E-4AFF-A4B9-D65C4769F838", "parentSegmentId": "A438DD29-16D8-4CEB-96B2-A44F8509A90E", "policyId": "B6780DC5-D0DE-431B-B049-82DBEE3C7D80", "segmentNameId": "8123E9B1-498C-4A06-A065-5A4D384C2167", "status": "24", "planSegmentNameId": "C438DD29-16D8-4CEB-96B2-A44F8509A90E", "segmentName": { "multiFields": {}, "segmentName": "Base Coverage", "activeFromDate": "2015-08-04T00:00:00Z", "activeToDate": "2020-08-04T00:00:00Z", "planSegmentName": "Test", "segmentNameId": "8123E9B1-498C-4A06-A065-5A4D384C2167", "planId": "C5EE0DA4-3003-42C1-9468-D91DA546B79F", "productId": "7FDC98E5-8B07-4A96-95D6-131727792021", "type": "04", "status": "01" }, "CopyBookRoutingNumber": "23", "RadioTest": { "textValue": "00", "optionText": "No" }, "ComboField": { "textValue": "01", "optionText": "Savings" }, "PolicyIntegField": 21, "CopyBookAccountNumber": 3432, "SegmentAmount": { "value": 23, "currency": "USD" } } ] } "