Shop Insurance Policy
Initiate Shop Insurance Policy
This method initiates the creation of a Shop Insurance Policy.
POST
https://sandbox.insurpass.com/api/merchant/initiate_shop_insure_policies
Headers
Request Body
{
"success":true,
"data":{
"token":"SHIP1666260336382297565"
},
"response_message":"Shop Insure Policy initiated successfully",
"response_code":""
}
<?php
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => 'https://sandbox.insurpass.com/api/merchant/initiate_shop_insure_policies',
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => '',
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 0,
CURLOPT_FOLLOWLOCATION => true,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => 'POST',
CURLOPT_POSTFIELDS =>'{
"first_name":"JK",
"last_name":"Rollins",
"email":"jkrollins@gmail.com",
"gender":"Female",
"occupation":"Medcine",
"product_id":3,
"type_of_goods_sold":"Big",
"shop_duration":"4",
"number_of_staff":5,
"wall_construction_material":"Brick",
"roof_construction_material":"Sheet",
"shop_address":"12 Jk Rollins street",
"phone_number":"08088464988"
}',
CURLOPT_HTTPHEADER => array(
'Authorization: Bearer {{SECRETKEY}}',
'Content-Type: application/json'
),
));
$response = curl_exec($curl);
curl_close($curl);
echo $response;
var axios = require('axios');
var data = JSON.stringify({
"first_name": "JK",
"last_name": "Rollins",
"email": "jkrollins@gmail.com",
"gender": "Female",
"occupation": "Medcine",
"product_id": 3,
"type_of_goods_sold": "Big",
"shop_duration": "4",
"number_of_staff": 5,
"wall_construction_material": "Brick",
"roof_construction_material": "Sheet",
"shop_address": "12 Jk Rollins street",
"phone_number": "08088464988"
});
var config = {
method: 'post',
url: 'https://sandbox.insurpass.com/api/merchant/initiate_shop_insure_policies',
headers: {
'Authorization': 'Bearer {{SECRETKEY}}',
'Content-Type': 'application/json'
},
data: data
};
axios(config)
.then(function (response) {
console.log(JSON.stringify(response.data));
})
.catch(function (error) {
console.log(error);
});
curl --location --request POST https://sandbox.insurpass.com/api/merchant/initiate_shop_insure_policies' \
--header 'Authorization: Bearer {{SECRETKEY}}' \
--header 'Accept: application/json' \
--header 'Content-Type: application/json' \
--data-raw '{
"first_name": "JK",
"last_name": "Rollins",
"email": "jkrollins@gmail.com",
"gender": "Female",
"occupation": "Medicine",
"product_id": 3,
"type_of_goods_sold": "Big",
"shop_duration": "4",
"number_of_staff": 5,
"wall_construction_material": "Brick",
"roof_construction_material": "Sheet",
"shop_address": "12 Jk Rollins street",
"phone_number": "08088464988"
}'
Verify Shop Insurance Policy
This endpoints sends a token that verifies the creation of a Shop policy.
POST
https://sandbox.insurpass.com/api/merchant/verify_shop_insure_policies
Headers
Request Body
{
"success":true,
"response_message":"Shop Insure Policy verifed successfully",
"response_code":"",
"data":{
"product_id":3,
"policy_number":"UIC/RE/INP/SI/20102022/53687",
"type_of_goods_sold":null,
"shop_duration":3,
"number_of_staff":4,
"wall_construction_material":"BLOCK",
"roof_construction_material":"zINC",
"avg_value_shop":null,
"shop_address":"oJO",
"status":true,
"start_date":"2022-03-31T00:00:00.000000Z",
"end_date":"2022-03-31T00:00:00.000000Z",
"deleted_at":null,
"created_at":"2022-03-31T12:10:02.000000Z",
"updated_at":"2022-03-31T12:10:05.000000Z"
}
}
<?php
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => 'https://sandbox.insurpass.com/api/merchant/verify_shop_insure_policies',
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => '',
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 0,
CURLOPT_FOLLOWLOCATION => true,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => 'POST',
CURLOPT_POSTFIELDS =>'{"token":"SHIP1664573060382449756"}',
CURLOPT_HTTPHEADER => array(
'Authorization: Bearer {{SECRETKEY}}',
'Content-Type: application/json'
),
));
$response = curl_exec($curl);
curl_close($curl);
echo $response;
var axios = require('axios');
var data = JSON.stringify({
"token": "SHIP1664573060382449756"
});
var config = {
method: 'post',
url: 'https://sandbox.insurpass.com/api/merchant/verify_shop_insure_policies',
headers: {
'Authorization': 'Bearer {{SECRETKEY}}',
'Content-Type': 'application/json'
},
data: data
};
axios(config)
.then(function (response) {
console.log(JSON.stringify(response.data));
})
.catch(function (error) {
console.log(error);
});
curl --location --request POST https://sandbox.insurpass.com/api/merchant/verify_shop_insure_policies' \
--header 'Authorization: Bearer {{SECRETKEY}}' \
--header 'Accept: application/json' \
--header 'Content-Type: application/json' \
--data-raw '{
"token": "SHIP163438169412711526"
}'
The Initiate token expires in 15 minutes, and if a user does not verify his/her subscription after 15 minutes of initiation, the details of the subscription will be deleted.
List All Shop Insurance Policies
This endpoint returns a list of all the shop insurance products
GET
https://sandbox.insurpass.com/api/merchant/get_merchant_shop_insure_policies
Headers
{
"success":true,
"response_message":"Shop Insure Policy get successful",
"response_code":[
],
"data":[
{
"id":1,
"user_id":26,
"product_id":3,
"merchant_id":1,
"policy_number":"AJDHKH/DJAADAD",
"type_of_goods_sold":null,
"shop_duration":3,
"number_of_staff":4,
"wall_construction_material":"BLOCK",
"roof_construction_material":"zINC",
"avg_value_shop":null,
"shop_address":"oJO",
"status":true,
"start_date":"2022-03-31T00:00:00.000000Z",
"end_date":"2022-03-31T00:00:00.000000Z",
"deleted_at":null,
"created_at":"2022-03-31T12:10:02.000000Z",
"updated_at":"2022-03-31T12:10:05.000000Z",
"user":{
"first_name":"Sakani",
"middle_name":null,
"surname":"Oluwakemi",
"phone_no":"09076567875",
"email":"email@gmail.com",
"address":null,
"gender":"male",
"date_of_birth":null
},
"transactions":[
{
"id":30,
"user_id":26,
"amount":"5000.00",
"product_id":3,
"status":"pending",
"type":"credit",
"subscriptions_id":8,
"merchant_user_id":null,
"coverdor_commission":"0.00",
"merchant_commission":"0.00",
"transaction_ref":"SCH16475985146319137",
"total_commission":"0.00",
"message":null,
"platform":null,
"channel":"API",
"currency":null,
"subscription_type":"App\\Models\\SchoolFeePolicy",
"transaction_date":null,
"created_at":"2022-03-18T10:15:14.000000Z",
"updated_at":"2022-03-18T10:15:14.000000Z"
},
{
"id":31,
"user_id":26,
"amount":"5000.00",
"product_id":3,
"status":"pending",
"type":"credit",
"subscriptions_id":9,
"merchant_user_id":null,
"coverdor_commission":"0.00",
"merchant_commission":"0.00",
"transaction_ref":"SCH16476121439711639",
"total_commission":"0.00",
"message":null,
"platform":null,
"channel":"API",
"currency":null,
"subscription_type":"App\\Models\\SchoolFeePolicy",
"transaction_date":null,
"created_at":"2022-03-18T14:02:23.000000Z",
"updated_at":"2022-03-18T14:02:23.000000Z"
},
{
"id":32,
"user_id":26,
"amount":"5000.00",
"product_id":3,
"status":"pending",
"type":"credit",
"subscriptions_id":10,
"merchant_user_id":null,
"coverdor_commission":"0.00",
"merchant_commission":"0.00",
"transaction_ref":"SCH16476122069317166",
"total_commission":"0.00",
"message":null,
"platform":null,
"channel":"API",
"currency":null,
"subscription_type":"App\\Models\\SchoolFeePolicy",
"transaction_date":null,
"created_at":"2022-03-18T14:03:26.000000Z",
"updated_at":"2022-03-18T14:03:26.000000Z"
}
],
"product":{
"id":3,
"name":"School fee bronze",
"details":"sgsfgsfgsf",
"beneficiaries":false,
"max_beneficiaries":5,
"provider_id":1,
"logo_url":null,
"enable":true,
"created_at":"2022-02-24T10:01:42.000000Z",
"updated_at":"2022-02-24T09:14:21.000000Z",
"service_id":1
}
}
]
}
<?php
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => 'https://sandbox.insurpass.com/api/merchant/get_merchant_shop_insure_policies',
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => '',
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 0,
CURLOPT_FOLLOWLOCATION => true,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => 'GET',
CURLOPT_HTTPHEADER => array(
'Authorization: Bearer {{SECRETKEY}}'
),
));
$response = curl_exec($curl);
curl_close($curl);
echo $response;
var axios = require('axio');
var data = '';
var config = {
method: 'get',
url: 'https://sandbox.insurpass.com/api/merchant/get_merchant_shop_insure_policies',
headers: {
'Authorization': 'Bearer {{SECRETKEY}}'
},
data: data
};
axios(config)
.then(function (response) {
console.log(JSON.stringify(response.data));
})
.catch(function (error) {
console.log(error);
});
curl --location --request GET https://sandbox.insurpass.com/api/merchant/get_merchant_shop_insure_policies' \
--header 'Authorization: Bearer {{SECRETKEY}}' \
--header 'Accept: application/json' \
--data-raw ''
Shop Insurance Policy Details
This endpoint returns an object containing a single Shop Insurance Policy
POST
https://sandbox.insurpass.com/api/merchant/get_shop_insure_policy_details
Headers
Request Body
{
"success":true,
"response_message":"Policy details retrieved successfully",
"response_code":"",
"data":{
"id":1,
"user_id":26,
"product_id":3,
"merchant_id":1,
"policy_number":"AJDHKH/DJAADAD",
"type_of_goods_sold":null,
"shop_duration":3,
"number_of_staff":4,
"wall_construction_material":"BLOCK",
"roof_construction_material":"zINC",
"avg_value_shop":null,
"shop_address":"oJO",
"status":true,
"start_date":"2022-03-31T00:00:00.000000Z",
"end_date":"2022-03-31T00:00:00.000000Z",
"deleted_at":null,
"created_at":"2022-03-31T12:10:02.000000Z",
"updated_at":"2022-03-31T12:10:05.000000Z",
"user":{
"first_name":"Sakani",
"middle_name":null,
"surname":"Oluwakemi",
"phone_no":"09076567875",
"email":"email@gmail.com",
"address":null,
"gender":"male",
"date_of_birth":null,
"password":null,
"policy_no":null,
"have_beneficiaries":false,
"enable":true,
"next_of_kin_full_name":null,
"merchant_user_id":null,
"user_type":"user",
"created_at":"2022-02-24T11:35:24.000000Z",
"updated_at":"2022-02-24T11:35:24.000000Z",
"principal_policy_no":null,
"nin_number":null,
"id_url":null,
"id_type":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":3,
"name":"School fee bronze",
"details":"sgsfgsfgsf",
"beneficiaries":false,
"max_beneficiaries":5,
"provider_id":1,
"logo_url":null,
"enable":true,
"created_at":"2022-02-24T10:01:42.000000Z",
"updated_at":"2022-02-24T09:14:21.000000Z",
"service_id":1
}
}
}
<?php
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => 'https://sandbox.insurpass.com/api/merchant/get_shop_insure_policy_details',
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => '',
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 0,
CURLOPT_FOLLOWLOCATION => true,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => 'POST',
CURLOPT_POSTFIELDS =>'{"policy_number":"UIC/RE/INP/SI/30092022/79187"}',
CURLOPT_HTTPHEADER => array(
'Authorization: Bearer {{SECRETKEY}}',
'Content-Type: application/json'
),
));
$response = curl_exec($curl);
curl_close($curl);
echo $response;
var axios = require('axios');
var data = JSON.stringify({"policy_number":"UIC/RE/INP/SI/30092022/79187"});
var config = {
method: 'post',
url: 'https://sandbox.insurpass.com/api/merchant/get_shop_insure_policy_details',
headers: {
'Authorization': 'Bearer {{SECRETKEY}}',
'Content-Type': 'application/json'
},
data: data
};
axios(config)
.then(function (response) {
console.log(JSON.stringify(response.data));
})
.catch(function (error) {
console.log(error);
});
curl --location --request POST https://sandbox.insurpass.com/api/merchant/get_shop_insure_policy_details' \
--header 'Authorization: Bearer {{SECRETKEY}}' \
--header 'Accept: application/json' \
--header 'Content-Type: application/json' \
--data-raw '{
"policy_number": "UIC/RE/INP/SI/20102022/53687"
}'
Retrieve Shop Insurance Report
This endpoint returns an object containing a merchant's number of policies and claims
GET
https://sandbox.insurpass.com/api/merchant/shop_insure_policy_report
This endpoint returns an object containing a merchant's number of policies and claims for the shop insurance product.
Headers
{
"success":true,
"response_message":"Shop Insure policy report get successful",
"response_code":"",
"data":{
"no_of_policy":34,
"no_of_claim":0
}
}
<?php
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => 'https://sandbox.insurpass.com/api/merchant/shop_insure_policy_report',
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => '',
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 0,
CURLOPT_FOLLOWLOCATION => true,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => 'GET',
CURLOPT_HTTPHEADER => array(
'Authorization: Bearer {{SECRETKEY}}'
),
));
$response = curl_exec($curl);
curl_close($curl);
echo $response;
var axios = require('axio');
var data = '';
var config = {
method: 'get',
url: 'https://sandbox.insurpass.com/api/merchant/shop_insure_policy_report',
headers: {
'Authorization': 'Bearer {{SECRETKEY}}'
},
data: data
};
axios(config)
.then(function (response) {
console.log(JSON.stringify(response.data));
})
.catch(function (error) {
console.log(error);
});
curl --location --request GET https://sandbox.insurpass.com/api/merchant/shop_insure_policy_report' \
--header 'Authorization: Bearer {{SECRETKEY}}' \
--header 'Accept: application/json' \
--data-raw ''
Last updated