Policy
Initiate Group Life Policy
This endpoint initiates a group life policy with a post request
POST
https://sandbox.insurpass.com/api/merchant/group-life/policy/initiate-group-life-policy
Successful initiation of policy generates a token that would be used to verify a transaction
Headers
Authorization*
String
Bearer {$secret-key}/{$api-key}
Content-Type*
String
application/json
Request Body
email*
Principal Customer's email address -email@domain.com
first_name*
String
Principal Customer's first name - Favour
surname*
String
Principal Customer's surname - Ezedibia
phone_no*
numeric|digits:11numeric|digits:11
Principal Customer's phone number - 08102223475 (digits:11)
gender*
String
Principal Customer's gender - female, male
dob*
String
Principal Customer's date of birth. yy-mm-dd
product_id*
String
The unique number that identifies Group insurance product you're purchasig - 3
group_name*
String
Name of the group purchasing the plan
group_type*
String
Type of group purchasing the plan
first_person_name*
String
The name of the first person of contact for the group
group_contact_address*
String
The address information of the group
first_person_phone*
numeric|digits:11
The phone number of the first person of contact for the group
second_person_name*
String
The name of the second person of contact for the group
second_person_phone*
numeric|digits:11
The phone number of the second person of contact for the group
status*
String
members*
String
the details of each group member
{
"success": true,
"response_message": "Group life policy verified successfully",
"response_code": 200,
"data": {
"token": "GLP163879198612409044"
}
}
Verify Group Life Policy
This endpoint verifies the token which was generated during the initiation of the policy.
POST
https://sandbox.insurpass.com/api/merchant/group-life/policy/verify-group-life-policy
Note that the token expires after a certain duration
Headers
Authorization*
String
Bearer {$secret-key}/{$api-key}
Content-Type*
String
application/json
Request Body
token*
String
Note that after 15 minutes, the token expires and you will need to reinitiate
{
"success": false,
"response_message": "Token has expired",
"response_code": 400,
"data": {
"error": [
"Token has expired"
]
}
}
Get Merchant Group Life Policy
This endpoint returns all the policies created by the merchant
GET
https://sandbox.insurpass.com/api/merchant/group-life/policy/merchant-group-life-policies
Headers
Authorization*
String
Bearer {$secret-key}/{$api-key}
Content-Type*
String
application/json
{
"success": true,
"response_message": "Group Life Policies retrieved successfully",
"response_code": 200,
"data": {
"current_page": 5,
"data": [
{
"id": 55,
"user_id": 12,
"product_id": 2,
"merchant_id": 1,
"policy_number": "IN32349098",
"group_name": "group life policy group",
"group_type": "User",
"group_contact_address": "rojojo store makurdi",
"first_person_name": "John",
"first_person_phone": "2636373737",
"second_person_name": "Peter",
"second_person_phone": null,
"start_date": null,
"end_date": null,
"status": true,
"deleted_at": null,
"created_at": "2021-12-03T22:13:02.000000Z",
"updated_at": "2021-12-03T22:13:02.000000Z",
"user": {
"id": 12,
"first_name": "John",
"middle_name": null,
"surname": "Doe",
"phone_no": "08135540787",
"email": "johndoed21393@gmail.com",
"address": null,
"gender": "Male",
"created_at": "2021-11-26T15:48:01.000000Z",
"updated_at": "2021-11-26T15:48:01.000000Z",
},
"product": {
"id": 2,
"name": "Malaria Care Plan Plus",
"details": "some details",
"beneficiaries": true,
"max_beneficiaries": 3,
"created_at": "2021-11-23T17:20:38.000000Z",
"updated_at": "2021-11-23T17:20:38.000000Z",
"service_id": 2,
"product_class_id": 2
},
"group_life_members": [
{
"id": 11,
"policy_id": 55,
"full_name": "Lasisi Modupela",
"gender": "male",
"occupation": "software Engineer",
"date_of_birth": "2021-01-12T00:00:00.000000Z",
"next_of_kiln": "Oson",
"phone_number": "08135540787",
"policy_type": "group-life",
"deleted_at": null,
"created_at": "2021-12-03T22:13:02.000000Z",
"updated_at": "2021-12-03T22:13:02.000000Z"
},
{
"id": 12,
"policy_id": 55,
"full_name": "Adebayo Ademola",
"gender": "male",
"occupation": "software Engineer",
"date_of_birth": "2021-01-12T00:00:00.000000Z",
"next_of_kiln": "shimi",
"phone_number": "08135540787",
"policy_type": "group-life",
"deleted_at": null,
"created_at": "2021-12-03T22:13:02.000000Z",
"updated_at": "2021-12-03T22:13:02.000000Z"
}
]
},
Group Life Policy Details
This endpoint returns the merchant policy details.
POST
https://sandbox.insurpass.com/api/merchant/group-life/policy/group-life-policy-details
The developer needs to provide the policy number for the policy details to display.
Headers
Authorization*
String
Bearer {$secret-key}/{$api-key}
Content-Type*
String
application/json
Request Body
Policy_number*
String
The unique number that identifies the purchased insurance policy - IN98570819
{
"success": true,
"response_message": "Group life Policy initiated successfully",
"response_code": 200,
"data": {
"id": 57,
"user_id": 12,
"product_id": 2,
"merchant_id": 1,
"policy_number": "IN93809537",
"group_name": "group life policy group",
"group_type": "User",
"group_contact_address": "rojojo store makurdi",
"first_person_name": "John",
"first_person_phone": "2636373737",
"second_person_name": "Peter",
"second_person_phone": null,
"start_date": null,
"end_date": null,
"status": true,
"deleted_at": null,
"created_at": "2021-12-03T22:24:44.000000Z",
"updated_at": "2021-12-03T22:24:44.000000Z",
"user": {
"id": 12,
"first_name": "John",
"middle_name": null,
"surname": "Doe",
"phone_no": "08135540787",
"email": "johndoed21393@gmail.com",
"address": null,
"gender": "Male",
"date_of_birth": "2021-02-12T00:00:00.000000Z",
"password": null,
"policy_no": "1234567",
"have_beneficiaries": false,
"enable": true,
"next_of_kin_full_name": null,
"merchant_user_id": null,
"user_type": "user",
"created_at": "2021-11-26T15:48:01.000000Z",
"updated_at": "2021-11-26T15:48:01.000000Z",
"principal_policy_no": null,
"nin_number": null,
"id_url": null,
"profile_url": null,
"company_id": null,
"verify_phone": 0,
"verify_email": 0,
"town": null,
"state_of_residence": null,
"transaction_pin": null,
"occupation": null
},
"product": {
"id": 2,
"name": "Malaria Care Plan Plus",
"details": "some details",
"beneficiaries": true,
"max_beneficiaries": 3,
"provider_id": 1,
"logo_url": "logo.png",
"enable": true,
"created_at": "2021-11-23T17:20:38.000000Z",
"updated_at": "2021-11-23T17:20:38.000000Z",
"service_id": 2,
"product_class_id": 2
},
"group_life_members": [
{
"id": 15,
"policy_id": 57,
"full_name": "Lasisi Modupela",
"gender": "male",
"occupation": "software Engineer",
"date_of_birth": "2021-01-12T00:00:00.000000Z",
"next_of_kiln": "Oson",
"phone_number": "08135540787",
"policy_type": "group-life",
"deleted_at": null,
"created_at": "2021-12-03T22:24:44.000000Z",
"updated_at": "2021-12-03T22:24:44.000000Z"
},
{
"id": 16,
"policy_id": 57,
"full_name": "Adebayo Ademola",
"gender": "male",
"occupation": "software Engineer",
"date_of_birth": "2021-01-12T00:00:00.000000Z",
"next_of_kiln": "shimi",
"phone_number": "08135540787",
"policy_type": "group-life",
"deleted_at": null,
"created_at": "2021-12-03T22:24:44.000000Z",
"updated_at": "2021-12-03T22:24:44.000000Z"
}
]
}
}
Last updated
Was this helpful?