Get policies created for your customers
GET/v1/policies
This endpoint allows you to get a listing of the policies that were created as a result of successfully proccessed orders made for your customers.
Request
Query Parameters
Default value: 1
The page of results.
Default value: 15
The maximum number of results per page.
Filter policies by customer ref
Possible values: [health
, comprehensive_auto
, 3rd_party_auto
, life
, marine
, git
, credit_life
, fire_burglary
, gadget
, job_loss
]
Filter policies by insurance type
Possible values: [0
, 1
]
Returns only the count of the policies
Responses
- 200
- 422
OK
- application/json
- Schema
- Example (from schema)
Schema
- Array [
- ]
data object[]
The unique ID of the policy
The policy number
The description of the policy
The start date of the coverage
The end date of the coverage
Current status of the policy
A url to download the polic document.
customer object
The the customer's information
Unique identifier for the customer on your system
The customer's email address
insurer object
An insurance provider
The unique code of the insurer
The name of the insurer
A link to the Insurer's logo
Insurer's terms and conditions
order object
An order for an insurance product
The unique ID of the order.
the current status of the order.
the amount due for payment by partner, excluding the partner's commission
The date when the policy coverage is due to start
An optional identifier for the asset the insurance covers. You may set this to a value that uniquley identifies the asset on your database.
The currency of all monetary parameters.
The channel through which the order was made.
product object
An individual insurance product or plan
The name of the product
The unique identifier for technical purposes
Unique Id of the product.
insurer object
An insurance provider
The unique code of the insurer
The name of the insurer
A link to the Insurer's logo
Insurer's terms and conditions
product type object
A major category of insurance e.g Health, Automobile, Life, Gadget, Goods in transit, etc
The generally accepted human friendly name
The unique identifier for technical purposes
list of the nefits covered.
Date of product creation
Price of product
Define the product premium tier.
Possible values: [monthly
, quarterly
, annually
]
Default value: annually
customer object
The the customer's information
Unique identifier for the customer on your system
The customer's email address
The policy for which the order was made.
links object
meta object
{
"data": [
{
"id": 8,
"number": "PH-34243TF",
"description": "Lorem ipsum...",
"start_date": "2022-03-24",
"end_date": "2023-03-24",
"status": "active",
"document_url": "https://grow-api.test/api/v1/policies/1/doc",
"customer": {
"ref": "string",
"email": "string",
"phone": "408-867-5309",
"first_name": "Jane",
"last_name": "Doe"
},
"insurer": {
"code": "AXA",
"name": "Axa Mansard",
"logo_url": null,
"terms_conditions": null
},
"order": {
"id": 2,
"status": "paid",
"amount_due": 1470,
"policy_start_date": "2022-04-06T00:00:00.000000Z",
"asset_ref": "T2354354",
"currency": "GHS",
"channel": "API",
"created_at": "2022-04-06T10:34:20.000000Z",
"product": {
"title": "Comprehensive Car Plan XYZ",
"code": "auto-com-xyz",
"id": 1,
"insurer": {
"code": "AXA",
"name": "Axa Mansard",
"logo_url": null,
"terms_conditions": null
},
"product type": {
"name": "Goods in Transit",
"slug": "GIT"
},
"cover-benefits": {},
"created-at": "string",
"price": 0,
"premium-type": "string",
"premium-rate-unit": 0,
"premium-rate": 0,
"premium": 0,
"partner-commision-rate": 0,
"min-premium": "string",
"premium-rules": "string",
"premium_frequency": "annually"
},
"customer": {
"ref": "string",
"email": "string",
"phone": "408-867-5309",
"first_name": "Jane",
"last_name": "Doe"
},
"policy": null
}
}
],
"links": {
"first": "https://api.grow.curacel.co/policies?page=1",
"last": "https://api.grow.curacel.co/policies?page=3",
"prev": "https://api.grow.curacel.co/policies?page=1",
"next": "https://api.grow.curacel.co/policies?page=3"
},
"meta": {
"current_page": 2,
"from": 1,
"total": 3
}
}
Unprocessable Content
- application/json
- Schema
- Example (from schema)
Schema
errors object
{
"message": "The given data was invalid",
"errors": {
"customer_ref": [
"The selected customer ref is invalid"
],
"...": [
"..."
]
}
}