> ## Documentation Index
> Fetch the complete documentation index at: https://docs.unyte.africa/llms.txt
> Use this file to discover all available pages before exploring further.

# API Integration

> Learn how to use the Superpool REST APIs and how to facilitate policy acquisition for your customers

# Know Before You Code

The **Superpool** platform is the core infrastructure that banks, travel agencies, enterprises, and other businesses integrate with to facilitate **insurance policy acquisition and claims processing**. Our system ensures a **seamless experience** by providing well-structured workflows tailored to your needs.

If you're new to the platform and need to know how to **obtain access tokens**, use our API suite, or set up Postman for testing, refer to [Get Started with Superpool REST APIs](./getting_started).

***

# How It Works

## Insurance Policy Acquisition

Superpool simplifies the process of acquiring insurance policies for your customers. Below is the **end-to-end flow** for integrating policy acquisition.

<Steps>
  <Step title="Quote Request and Intent Capture">
    When a customer selects an insurance quote and tenure, a **QuoteIntent** is created. This:

    * **Locks in the pricing** for the selected tenure.
    * **Tracks customer information** for processing.

    ```mermaid theme={null}
    journey
      title Customer Policy Purchase Journey
      section Quote Selection
        Customer: 1: Chooses insurance product
        Customer: 2: Selects tenure and premium
        Superpool: 3: Creates QuoteIntent
      section Payment
        Customer: 1: Proceeds to payment gateway
        Payment Gateway: 2: Captures transaction
        Superpool: 3: Updates QuoteIntent to PAID
      section Policy Issuance
        Superpool: 1: Issues policy and finalizes purchase
    ```
  </Step>

  <Step title="Payment Processing">
    After initiating the `QuoteIntent`, the customer proceeds with payment. Our platforms integrates with several **payment gateways** to make this process seamless for your customers, allowing either **direct payments or redirection** to the payment gateway with the required details.

    ```mermaid theme={null}
    sequenceDiagram
        participant C as Customer
        participant S as Superpool
        participant P as Payment Gateway
        participant Q as QuoteIntent

        C->>S: Selects Quote and Tenure
        S->>S: Creates QuoteIntent
        S->>P: Redirects to Payment Gateway (quote_code, tenure, amount, customer_id)
        P->>S: Payment Successful
        S->>Q: Update QuoteIntent status to PAID
        S->>S: Finalize Policy Issuance
    ```
  </Step>

  <Step title="Policy Issuance">
    Once payment is confirmed, Superpool issues the insurance policy

    * The **QuoteIntent is updated to PAID**.
    * A **policy document** is generated.
    * The transaction is marked as **completed**.

    ```mermaid theme={null}
    graph TD;
      A[Customer selects quote] --> B[QuoteIntent Created]
      B --> C[Customer Proceeds to Payment]
      C -->|Success| D[QuoteIntent Updated to PAID]
      D --> E[Superpool Issues Policy]
      E --> F[Transaction Completed]
    ```
  </Step>
</Steps>

<Note title="Next Steps" icon="lightbulb">
  Now that you understand the policy acquisition flow, learn how to <a href="../content/insurance-quotes.mdx">retrieve quotes</a> and <a href="../api-reference/policies/purchase-a-policy.mdx">finalize policy purchases</a>.
</Note>

***

## Claims Filing and Processing

Superpool supports an efficient **claims filing system**, allowing customers to submit claims directly via your platform. We facilitate this process by automating everything
from document verification to settlement tracking.

```mermaid theme={null}
journey
  title Claims Processing Flow
  section Claim Initiation
    Customer: 1: Submits claim request
    Superpool: 2: Validates claim eligibility
  section Processing
    Superpool: 1: Assigns claim adjuster
    Claim Adjuster: 2: Reviews documentation
    Superpool: 3: Approves or Rejects claim
  section Settlement
    Superpool: 1: Processes payout
    Customer: 2: Receives settlement
```

<Note title="Want to enable claims?" icon="info">
  See the <a href="../api-reference/claims/submit-a-claim.mdx">Claims API documentation</a> to integrate claim submissions into your platform.
</Note>

***

## Renewals Made Easy

Superpool allows customers to **renew policies effortlessly**. Our API supports both **automated** and **manual renewals** to keep customers insured.

```mermaid theme={null}
graph TD;
  A[Policy Expiry Approaching?] --> B[We Send Renewal Notification to you as the merchant]
  B --> C[Customer Chooses to Renew]
  C --> D[Payment Captured]
  D --> E[Policy Renewed Successfully]
```

***

## Batch-Issuance of Policies

Businesses handling large-scale insurance processing can issue policies in **batches** using our API. This is useful for:

* **Banks** issuing travel insurance for multiple clients.
* **Enterprises** covering employees under group insurance plans.
* **Government agencies or Ministries** issuing policies to eligible citizens.
* **All other forms of coporate partnership** to with need of bulk-facilitation of policy management

```mermaid theme={null}
sequenceDiagram
    participant B as Business Platform
    participant S as Superpool
    participant P as Payment Processor

    B->>S: Submit Bulk Policy Request
    S->>S: Validate Bulk Data
    S->>P: Process Payments for All Policies
    P->>S: Confirm Payment Success
    S->>B: Issue Policies and Return Confirmation
```

At the moment, We are working hard to bring you this feature of Batch-Issuance. Please reach out to the business team at [tech@unyte.africa](mailto:tech@unyte.africa),
to get proper timeline of support for your business needs.

<Note title="Ready to issue policies in bulk?" icon="zap">
  Read the <a href="../content/policies/batch_api.mdx">Batch Policy Issuance API Guide</a> to start automating policy distribution.
</Note>
