Links

Keke Policy

Initiate Keke Policy

post
https://sandbox.insurpass.com
/api/merchant/initiate_keke_pass_policy
This endpoint initiates the creation of a keke insurance policy.
PHP
NODE JS
CURL
1
<?php
2
$curl = curl_init();
3
4
curl_setopt_array($curl, array(
5
CURLOPT_URL => 'https://sandbox.insurpass.com/api/merchant/initiate_keke_pass_policy',
6
CURLOPT_RETURNTRANSFER => true,
7
CURLOPT_ENCODING => '',
8
CURLOPT_MAXREDIRS => 10,
9
CURLOPT_TIMEOUT => 0,
10
CURLOPT_FOLLOWLOCATION => true,
11
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
12
CURLOPT_CUSTOMREQUEST => 'POST',
13
CURLOPT_POSTFIELDS =>'{
14
"first_name": "James",
15
"last_name": "Robert",
16
"phone_number": "08045754345",
17
"email": "[email protected]",
18
"gender": "male",
19
"address": "main street",
20
"relationship": "brother",
21
"amount_insured": 6000,
22
"identity": "str",
23
"nok_surname": "John",
24
"nok_othernames": "Doe",
25
"nok_relationship": "Brother",
26
"nok_gender": "Male",
27
"nok_phone_no": "09034543643",
28
"nok_email_address": "[email protected]",
29
"product_id":2,
30
"id_url":"https://gmail.com",
31
"id_number":"2424253642",
32
"id_type":"nin"
33
}
34
',
35
CURLOPT_HTTPHEADER => array(
36
'Authorization: Bearer {{SECRETKEY}}',
37
'Content-Type: application/json'
38
),
39
));
40
41
$response = curl_exec($curl);
42
43
curl_close($curl);
44
echo $response;initiate_keke_pass_policy
1
var axios = require('axios');
2
var data = JSON.stringify({
3
"first_name": "James",
4
"last_name": "Robert",
5
"phone_number": "08045754345",
6
"email": "[email protected]",
7
"gender": "male",
8
"address": "main street",
9
"relationship": "brother",
10
"amount_insured": 6000,
11
"identity": "str",
12
"nok_surname": "John",
13
"nok_othernames": "Doe",
14
"nok_relationship": "Brother",
15
"nok_gender": "Male",
16
"nok_phone_no": "09034543643",
17
"nok_email_address": "[email protected]",
18
"product_id":2,
19
"id_url":"https://gmail.com",
20
"id_number":"2424253642",
21
"id_type":"nin"
22
}
23
);
24
25
var config = {
26
method: 'post',
27
url: 'https://sandbox.insurpass.com/api/merchant/initiate_keke_pass_policy',
28
headers: {
29
'Authorization': 'Bearer {{SECRETKEY}}',
30
'Content-Type': 'application/json'
31
},
32
data: data
33
};
34
35
axios(config)
36
.then(function (response) {
37
console.log(JSON.stringify(response.data));
38
})
39
.catch(function (error) {
40
console.log(error);
41
});
curl --location --request POST https://sandbox.insurpass.com/api/merchant/initiate_keke_pass_policy' \
--header 'Authorization: Bearer {{SECRETKEY}}' \
--header 'Accept: application/json' \
--header 'Content-Type: application/json' \
--data-raw '{
"first_name": "James",
"last_name": "Robert",
"phone_number": "08045754345",
"email": "[email protected]",
"gender": "male",
"address": "main street",
"relationship": "brother",
"amount_insured": 6000,
"identity": "str",
"nok_surname": "John",
"nok_othernames": "Doe",
"nok_relationship": "Brother",
"nok_gender": "Male",
"nok_phone_no": "09034543643",
"nok_email_address": "[email protected]",
"product_id":2,
"id_url":"https://gmail.com",
"id_number":"2424253642",
"id_type":"nin"
}'

Verify Keke Policy

post
https://sandbox.insurpass.com
/api/merchant/verify_keke_pass_policy
This endpoint sends a token that verifies the creation of a keke insurance policy.
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.
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_keke_pass_policy',
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
"token": "IDP1664732927341151853"
16
}',
17
CURLOPT_HTTPHEADER => array(
18
'Authorization: Bearer {{SECRETKEY}}',
19
'Content-Type: application/json'
20
),
21
));
22
23
$response = curl_exec($curl);
24
25
curl_close($curl);
26
echo $response;
1
var axios = require('axios');
2
var data = JSON.stringify({
3
"token": "IDP1664732927341151853"
4
});
5
6
var config = {
7
method: 'post',
8
url: 'https://sandbox.insurpass.com/api/merchant/verify_keke_pass_policy',
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_keke_pass_policy' \
--header 'Authorization: Bearer {{SECRETKEY}}' \
--header 'Accept: application/json' \
--header 'Content-Type: application/json' \
--data-raw '{
"token": "IDP163446435012295714"
}'

List All Keke Policies

get
https://sandbox.insurpass.com
/api/merchant/merchant_keke_pass_policies
This endpoint returns a list of all the keke insurance polices.
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/merchant_keke_pass_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('axios');
2
var data = '';
3
4
var config = {
5
method: 'get',
6
url: 'https://sandbox.insurpass.com/api/merchant/merchant_keke_pass_policies',
7
headers: {
8
'Authorization': 'Bearer {{SECRETKEY}}'
9
},
10
data: data
11
};
12
axios(config)
13
.then(function (response) {
14
console.log(JSON.stringify(response.data));
15
})
16
.catch(function (error) {
17
console.log(error);
18
});
curl --location --request GET https://sandbox.insurpass.com/api/merchant/merchant_keke_pass_policies' \
--header 'Authorization: Bearer {{SECRETKEY}}' \
--header 'Accept: application/json' \
--data-raw ''

Keke Policy Details

post
https://sandbox.insurpass.com
/api/merchant/keke_policy_details
This endpoint returns an object containing a single keke 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/keke_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/keke_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/keke_policy_details' \
--header 'Authorization: Bearer {{SECRETKEY}}' \
--header 'Accept: application/json' \
--header 'Content-Type: application/json' \
--data-raw '{
"policy_number": "UIC/RE/INP/KPASS/20102022/94731"
}'

Keke Policy Quote

post
https://sandbox.insurpass.com
/api/merchant/keke_get_policy_quote
The endpoint return a quote for a keke 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/keke_get_policy_quote',
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 =>'{"product_id":"26"}',
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({"product_id":"26"});
3
4
var config = {
5
method: 'post',
6
url: 'https://sandbox.insurpass.com/api/merchant/keke_get_policy_quote',
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/keke_get_policy_quote' \
--header 'Authorization: Bearer {{SECRETKEY}}' \
--header 'Accept: application/json' \
--header 'Content-Type: application/json' \
--data-raw '{
"policy_number": "UIC/RE/INP/KPASS/20102022/94731"
}'