Note: This release is in preview. Features described here don’t become generally available until the latest general availability date that Salesforce announces for this release. Before then, and where features are noted as beta, pilot, or developer preview, we can’t guarantee general availability within any particular time frame or at all. Make your purchase decisions only on the basis of generally available products and features.

Cost Calculation

Output representation details of the cost calculation.
JSON example
Here's a sample success response.
1{
2  "isSuccess":true,
3  "errors":[],
4  "policy": {
5    "id": "p111",
6    "premiumAmountWithFrequency": {
7      "Annually": "xxx.xx",
8      "Monthly": "xxx.xxx",
9      "Quarterly": "xx.xxx"
10    },
11    "premiumEqvAmountWithFrequency": {
12      "Annually": "xx.xx",
13      "Monthly": "xx.xx",
14      "Quarterly": "xxx.xxx"
15    },
16    "feeAmountWithFrequency": {
17      "Annually": "xx.xx",
18      "Monthly": "xx.xx",
19      "Quarterly": "xxx.xxx"
20    },
21    "coverages": [
22      {
23        "id": "pc111",
24        "premiumAmountWithFrequency": {
25          "Annually": "xxx.xx",
26          "Monthly": "xxx.xxx",
27          "Quarterly": "xx.xxx"
28        },
29        "premiumEqvAmountWithFrequency": {
30          "Annually": "xx.xx",
31          "Monthly": "xx.xx",
32          "Quarterly": "xxx.xxx"
33        },
34        "feeAmountWithFrequency": {
35          "Annually": "xx.xx",
36          "Monthly": "xx.xx",
37          "Quarterly": "xxx.xxx"
38        },
39        "ratePlans": [
40          {
41            "id": "rp11",
42            "totalPremiumAmount": 350,
43            "totalFeeAmount": "xyz",
44            "totalPremiumEqvAmount": "xyz",
45            "ratePlanLineItems": [
46              {
47                "id": "rpli111",
48                "premiumAmount": 100
49              },
50              {
51                "id": "rpli112",
52                "premiumAmount": 150
53              }
54            ]
55          },
56          {
57            "id": "rp12",
58            "totalPremiumAmount": 580,
59            "ratePlanLineItems": [
60              {
61                "id": "rpli121",
62                "premiumAmount": 80
63              },
64              {
65                "id": "rpli122",
66                "premiumAmount": 200
67              },
68              {
69                "id": "rpli123",
70                "premiumAmount": 300
71              }
72            ]
73          }
74        ]
75      }
76    ]
77  }
78}
This request shows a sample error response.
1{
2    "isSuccess":true,
3    "errors" : [
4        {
5            "code":INVALID_INPUT,
6            "message": "Specify a valid ratePlanId."
7        }
8    ]
9}
Property Name Type Description Filter Group and Version Available Version
errors Error Response List of errors encountered during the processing of the API request. Small, 63.0 63.0
isSuccess Boolean Indicates whether the API request is successful ( true) or not ( false). Small, 63.0 63.0
policy Map<String, Object> Map of policy and cost calculation details from policy to ratePlanLineItems. Small, 63.0 63.0