Links

Shop Insurance Policy

Initiate Shop Insurance Policy

post
https://sandbox.insurpass.com
/api/merchant/initiate_shop_insure_policies
This method initiates the creation of a Shop Insurance Policy.
PHP
NODE JS
CURL
1
<?php
2
3
$curl = curl_init();
4
5
curl_setopt_array($curl, array(
6
CURLOPT_URL => 'https://sandbox.insurpass.com/api/merchant/initiate_shop_insure_policies',
7
CURLOPT_RETURNTRANSFER => true,
8
CURLOPT_ENCODING => '',
9
CURLOPT_MAXREDIRS => 10,
10
CURLOPT_TIMEOUT => 0,
11
CURLOPT_FOLLOWLOCATION => true,
12
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
13
CURLOPT_CUSTOMREQUEST => 'POST',
14
CURLOPT_POSTFIELDS =>'{
15
"first_name":"JK",
16
"last_name":"Rollins",
17
"email":"[email protected]",
18
"gender":"Female",
19
"occupation":"Medcine",
20
"product_id":3,
21
"type_of_goods_sold":"Big",
22
"shop_duration":"4",
23
"number_of_staff":5,
24
"wall_construction_material":"Brick",
25
"roof_construction_material":"Sheet",
26
"shop_address":"12 Jk Rollins street",
27
"phone_number":"08088464988"
28
}',
29
CURLOPT_HTTPHEADER => array(
30
'Authorization: Bearer {{SECRETKEY}}',
31
'Content-Type: application/json'
32
),
33
));
34
35
$response = curl_exec($curl);
36
37
curl_close($curl);
38
echo $response;
1
var axios = require('axios');
2
var data = JSON.stringify({
3
"first_name": "JK",
4
"last_name": "Rollins",
5
"email": "[email protected]",
6
"gender": "Female",
7
"occupation": "Medcine",
8
"product_id": 3,
9
"type_of_goods_sold": "Big",
10
"shop_duration": "4",
11
"number_of_staff": 5,
12
"wall_construction_material": "Brick",
13
"roof_construction_material": "Sheet",
14
"shop_address": "12 Jk Rollins street",
15
"phone_number": "08088464988"
16
});
17
18
var config = {
19
method: 'post',
20
url: 'https://sandbox.insurpass.com/api/merchant/initiate_shop_insure_policies',
21
headers: {
22
'Authorization': 'Bearer {{SECRETKEY}}',
23
'Content-Type': 'application/json'
24
},
25
data: data
26
};
27
28
axios(config)
29
.then(function (response) {
30
console.log(JSON.stringify(response.data));
31
})
32
.catch(function (error) {
33
console.log(error);
34
});
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": "[email protected]",
"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

post
https://sandbox.insurpass.com
/api/merchant/verify_shop_insure_policies
This endpoints sends a token that verifies the creation of a Shop policy.
PHP
NODE JS
CURL
1
<?php
2
3
$curl = curl_init();
4
5
curl_setopt_array($curl, array(
6
CURLOPT_URL => 'https://sandbox.insurpass.com/api/merchant/verify_shop_insure_policies',
7
CURLOPT_RETURNTRANSFER => true,
8
CURLOPT_ENCODING => '',
9
CURLOPT_MAXREDIRS => 10,
10
CURLOPT_TIMEOUT => 0,
11
CURLOPT_FOLLOWLOCATION => true,
12
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
13
CURLOPT_CUSTOMREQUEST => 'POST',
14
CURLOPT_POSTFIELDS =>'{"token":"SHIP1664573060382449756"}',
15
CURLOPT_HTTPHEADER => array(
16
'Authorization: Bearer {{SECRETKEY}}',
17
'Content-Type: application/json'
18
),
19
));
20
21
$response = curl_exec($curl);
22
23
curl_close($curl);
24
echo $response;
1
var axios = require('axios');
2
var data = JSON.stringify({
3
"token": "SHIP1664573060382449756"
4
});
5
6
var config = {
7
method: 'post',
8
url: 'https://sandbox.insurpass.com/api/merchant/verify_shop_insure_policies',
9
headers: {
10
'Authorization': 'Bearer {{SECRETKEY}}',
11
'Content-Type': 'application/json'
12
},
13
data: data
14
};
15
16
axios(config)
17
.then(function (response) {
18
console.log(JSON.stringify(response.data));
19
})
20
.catch(function (error) {
21
console.log(error);
22
});
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

get
https://sandbox.insurpass.com
/api/merchant/get_merchant_shop_insure_policies
This endpoint returns a list of all the shop insurance products
PHP
NODE JS
CURL
1
<?php
2
3
$curl = curl_init();
4
5
curl_setopt_array($curl, array(
6
CURLOPT_URL => 'https://sandbox.insurpass.com/api/merchant/get_merchant_shop_insure_policies',
7
CURLOPT_RETURNTRANSFER => true,
8
CURLOPT_ENCODING => '',
9
CURLOPT_MAXREDIRS => 10,
10
CURLOPT_TIMEOUT => 0,
11
CURLOPT_FOLLOWLOCATION => true,
12
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
13
CURLOPT_CUSTOMREQUEST => 'GET',
14
CURLOPT_HTTPHEADER => array(
15
'Authorization: Bearer {{SECRETKEY}}'
16
),
17
));
18
19
$response = curl_exec($curl);
20
21
curl_close($curl);
22
echo $response;
1
var axios = require('axio');
2
var data = '';
3
4
var config = {
5
method: 'get',
6
url: 'https://sandbox.insurpass.com/api/merchant/get_merchant_shop_insure_policies',
7
headers: {
8
'Authorization': 'Bearer {{SECRETKEY}}'
9
},
10
data: data
11
};
12
13
axios(config)
14
.then(function (response) {
15
console.log(JSON.stringify(response.data));
16
})
17
.catch(function (error) {
18
console.log(error);
19
});
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

post
https://sandbox.insurpass.com
/api/merchant/get_shop_insure_policy_details
This endpoint returns an object containing a single Shop Insurance Policy
PHP
NODE JS
CURL
1
<?php
2
3
$curl = curl_init();
4
5
curl_setopt_array($curl, array(
6
CURLOPT_URL => 'https://sandbox.insurpass.com/api/merchant/get_shop_insure_policy_details',
7
CURLOPT_RETURNTRANSFER => true,
8
CURLOPT_ENCODING => '',
9
CURLOPT_MAXREDIRS => 10,
10
CURLOPT_TIMEOUT => 0,
11
CURLOPT_FOLLOWLOCATION => true,
12
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
13
CURLOPT_CUSTOMREQUEST => 'POST',
14
CURLOPT_POSTFIELDS =>'{"policy_number":"UIC/RE/INP/SI/30092022/79187"}',
15
CURLOPT_HTTPHEADER => array(
16
'Authorization: Bearer {{SECRETKEY}}',
17
'Content-Type: application/json'
18
),
19
));
20
21
$response = curl_exec($curl);
22
23
curl_close($curl);
24
echo $response;
1
var axios = require('axios');
2
var data = JSON.stringify({"policy_number":"UIC/RE/INP/SI/30092022/79187"});
3
4
var config = {
5
method: 'post',
6
url: 'https://sandbox.insurpass.com/api/merchant/get_shop_insure_policy_details',
7
headers: {
8
'Authorization': 'Bearer {{SECRETKEY}}',
9
'Content-Type': 'application/json'
10
},
11
data: data
12
};
13
14
axios(config)
15
.then(function (response) {
16
console.log(JSON.stringify(response.data));
17
})
18
.catch(function (error) {
19
console.log(error);
20
});
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

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
PHP
NODE JS
CURL
1
<?php
2
3
$curl = curl_init();
4
5
curl_setopt_array($curl, array(
6
CURLOPT_URL => 'https://sandbox.insurpass.com/api/merchant/shop_insure_policy_report',
7
CURLOPT_RETURNTRANSFER => true,
8
CURLOPT_ENCODING => '',
9
CURLOPT_MAXREDIRS => 10,
10
CURLOPT_TIMEOUT => 0,
11
CURLOPT_FOLLOWLOCATION => true,
12
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
13
CURLOPT_CUSTOMREQUEST => 'GET',
14
CURLOPT_HTTPHEADER => array(
15
'Authorization: Bearer {{SECRETKEY}}'
16
),
17
));
18
19
$response = curl_exec($curl);
20
21
curl_close($curl);
22
echo $response;
1
var axios = require('axio');
2
var data = '';
3
4
var config = {
5
method: 'get',
6
url: 'https://sandbox.insurpass.com/api/merchant/shop_insure_policy_report',
7
headers: {
8
'Authorization': 'Bearer {{SECRETKEY}}'
9
},
10
data: data
11
};
12
13
axios(config)
14
.then(function (response) {
15
console.log(JSON.stringify(response.data));
16
})
17
.catch(function (error) {
18
console.log(error);
19
});
curl --location --request GET https://sandbox.insurpass.com/api/merchant/shop_insure_policy_report' \
--header 'Authorization: Bearer {{SECRETKEY}}' \
--header 'Accept: application/json' \
--data-raw ''