> For the complete documentation index, see [llms.txt](https://milonics.gitbook.io/api-documentation/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://milonics.gitbook.io/api-documentation/insurpass-api-reference/school-fees-insurance/school-fees-claims.md).

# School Fees Claims

## Initiate School Fees Claims

## The endpoint initiates the creation of a school fees claim.

<mark style="color:green;">`POST`</mark> `https://sandbox.insurpass.com/api/merchant/school_fee_initiate_claim`

#### Headers

| Name                                            | Type   | Description                     |
| ----------------------------------------------- | ------ | ------------------------------- |
| Authorization<mark style="color:red;">\*</mark> | String | Bearer {$secret-key}/{$api-key} |
| Content-Type<mark style="color:red;">\*</mark>  | String | application/json                |

#### Request Body

| Name                                                   | Type   | Description                                                                        |
| ------------------------------------------------------ | ------ | ---------------------------------------------------------------------------------- |
| policy\_number<mark style="color:red;">\*</mark>       | String | The unique number that identifies the purchased  insurance policy - **IN98570819** |
| full\_details<mark style="color:red;">\*</mark>        | String | Dscriptive text of the full details of the incident                                |
| supporting\_document<mark style="color:red;">\*</mark> | String | image url of very possible doument to suport their claim                           |
| signature\_date<mark style="color:red;">\*</mark>      | String | Date the claim was made. DD/MM/YYYY                                                |
| date\_of\_occurance<mark style="color:red;">\*</mark>  | String | Date the incident occurred. DD/MM/YYYY                                             |
| signature<mark style="color:red;">\*</mark>            | String | image url of the signature                                                         |

{% tabs %}
{% tab title="200: OK " %}

```javascript
{
   "success":true,
   "response_message":"School fee  policy claim initiated successfully",
   "response_code":"",
   "data":{
      "result":"School fee  policy claim initiated successfully"
   }
}
```

{% endtab %}
{% endtabs %}

{% tabs %}
{% tab title="PHP" %}
{% code overflow="wrap" lineNumbers="true" %}

```php
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => 'https://sandbox.insurpass.com/api/merchant/school_fee_initiate_claim',
  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/SFP/02102022/78555",
    "full_details": "Mille Bobby Brown",
    "supporting_document": "This is a detail",
    "signature_date": "2021-02-12",
    "date_of_occurance": "1993-02-12",
    "signature": "string"
}',
  CURLOPT_HTTPHEADER => array(
    'Authorization: Bearer {{SECRETKEY}}',
    'Content-Type: application/json'
  ),
));

$response = curl_exec($curl);

curl_close($curl);
echo $response;
```

{% endcode %}
{% endtab %}

{% tab title="NODE JS" %}
{% code overflow="wrap" lineNumbers="true" %}

```javascript
var axios = require('axios');
var data = JSON.stringify({
    "policy_number": "UIC/RE/INP/SFP/02102022/78555",
    "full_details": "Mille Bobby Brown",
    "supporting_document": "This is a detail",
    "signature_date": "2021-02-12",
    "date_of_occurance": "1993-02-12",
    "signature": "string"
});

var config = {
  method: 'post',
  url: 'https://sandbox.insurpass.com/api/merchant/school_fee_initiate_claim',
  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);
});
```

{% endcode %}
{% endtab %}

{% tab title="CURL" %}
{% code overflow="wrap" %}

```clike
curl --location --request POST https://sandbox.insurpass.com/api/merchant/school_fee_initiate_claim' \
--header 'Authorization: Bearer {{SECRETKEY}}' \
--header 'Accept: application/json' \
--header 'Content-Type: application/json' \
--data-raw '{
    "policy_number": "UIC/RE/INP/SFP/02102022/78555",
    "full_details": "Mille Bobby Brown",
    "supporting_document": "This is a detail",
    "signature_date": "2021-02-12",
    "date_of_occurance": "1993-02-12",
    "signature": "string"
}'
```

{% endcode %}
{% endtab %}
{% endtabs %}

## **School Fees Claim Details**

## This endpoint  returns an object containing a single school fees claim&#x20;

<mark style="color:green;">`POST`</mark> `https://sandbox.insurpass.com/api/merchant/school_fee_merchant_claims`

#### Headers

| Name                                            | Type   | Description                     |
| ----------------------------------------------- | ------ | ------------------------------- |
| Authorization<mark style="color:red;">\*</mark> | String | Bearer {$secret-key}/{$api-key} |
| Content-Type<mark style="color:red;">\*</mark>  | String | application/json                |

#### Request Body

| Name                                           | Type   | Description                                                                        |
| ---------------------------------------------- | ------ | ---------------------------------------------------------------------------------- |
| policyNumber<mark style="color:red;">\*</mark> | String | The unique number that identifies the purchased  insurance policy - **IN98570819** |

{% tabs %}
{% tab title="200: OK " %}

```javascript
{
   "success":true,
   "response_message":"Data fetched successfully",
   "response_code":"",
   "data":{
      "status":true,
      "full_details":"Salami Kaol",
      "supporting_document":"This is a detail",
      "signature":"string",
      "signature_date":"2021-02-12T00:00:00.000000Z",
      "date_of_occurance":"1993-02-12T00:00:00.000000Z",
      "deleted_at":null,
      "created_at":"2022-04-04T08:09:05.000000Z",
      "updated_at":"2022-04-04T08:09:05.000000Z",
      "school_fee_policy":{
         "beneficiary_id":18,
         "policy_number":"INS1645702524736",
         "trustee_fullname":"fsfs",
         "trustee_phone_number":"08034543234",
         "trustee_email":"salamikolawole@gmail.com",
         "frequency_type":"monthly",
         "frequency":30,
         "status":true,
         "deleted_at":null,
         "created_at":"2022-02-24T11:35:24.000000Z",
         "updated_at":"2022-02-24T11:35:24.000000Z"
      }
   }
}
```

{% endtab %}
{% endtabs %}

{% tabs %}
{% tab title="PHP" %}
{% code overflow="wrap" lineNumbers="true" %}

```php
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => 'https://sandbox.insurpass.com/api/merchant/school_fee_claim_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;
```

{% endcode %}
{% endtab %}

{% tab title="NODE JS" %}
{% code overflow="wrap" lineNumbers="true" %}

```javascript
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/school_fee_claim_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);
});
```

{% endcode %}
{% endtab %}

{% tab title="CURL" %}
{% code overflow="wrap" %}

```clike
curl --location --request POST https://sandbox.insurpass.com/api/merchant/school_fee_merchant_claims' \
--header 'Authorization: Bearer {{SECRETKEY}}' \
--header 'Accept: application/json' \
--header 'Content-Type: application/json' \
--data-raw '{"policy_number":"UIC/RE/INP/SI/30092022/79187"}'
```

{% endcode %}
{% endtab %}
{% endtabs %}

## List All **School Fees Claims**

## This endpoint returns a list of all the School Fees claim objects.

<mark style="color:blue;">`GET`</mark> `https://sandbox.insurpass.com/api/merchant/school_fee_merchant_claims`

#### Headers

| Name                                            | Type   | Description                     |
| ----------------------------------------------- | ------ | ------------------------------- |
| Authorization<mark style="color:red;">\*</mark> | String | Bearer {$secret-key}/{$api-key} |
| Content-Type<mark style="color:red;">\*</mark>  | String | application/json                |

{% tabs %}
{% tab title="200: OK " %}

```javascript
{
   "success":true,
   "response_message":"Data fetched successfully",
   "response_code":"",
   "data":[
      {
         "status":true,
         "full_details":"Salami Kaol",
         "supporting_document":"This is a detail",
         "signature":"string",
         "signature_date":"2021-02-12T00:00:00.000000Z",
         "date_of_occurance":"1993-02-12T00:00:00.000000Z",
         "deleted_at":null,
         "created_at":"2022-04-04T08:09:05.000000Z",
         "updated_at":"2022-04-04T08:09:05.000000Z",
         "school_fee_policy":{
            "policy_number":"INS1645702524736"
         }
      }
   ]
}
```

{% endtab %}
{% endtabs %}

{% tabs %}
{% tab title="PHP" %}
{% code overflow="wrap" lineNumbers="true" %}

```php
<?php

$curl = curl_init();

curl_setopt_array($curl, array(
  CURLOPT_URL => 'https://sandbox.insurpass.com/api/merchant/school_fee_merchant_claims',
  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;
```

{% endcode %}
{% endtab %}

{% tab title="NODE JS" %}
{% code overflow="wrap" lineNumbers="true" %}

```javascript
var axios = require('axios');
var data = '';

var config = {
  method: 'get',
  url: 'https://sandbox.insurpass.com/api/merchant/school_fee_merchant_claims',
  headers: { 
    'Authorization': 'Bearer {{SECRETKEY}}'
  },
  data: data
};
axios(config)
.then(function (response) {
  console.log(JSON.stringify(response.data));
})
.catch(function (error) {
  console.log(error);
});
```

{% endcode %}
{% endtab %}

{% tab title="CURL" %}
{% code overflow="wrap" %}

```clike
curl --location --request POST https://sandbox.insurpass.com/api/merchant/school_fee_merchant_claims' \
--header 'Authorization: Bearer {{SECRETKEY}}' \
--header 'Accept: application/json' \
--header 'Content-Type: application/json' \
--data-raw ''
```

{% endcode %}
{% endtab %}
{% endtabs %}
