> ## 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.

# Submit a claim

> Submits a new claim entry on behalf of a customer



## OpenAPI

````yaml post /api/v1/claims/
openapi: 3.0.3
info:
  title: Superpool API
  version: 2.0.0
  description: >-
    Insurance infrastructure for Financial Institutions, Insurers, and
    Insurtechs
  contact:
    name: Unyte Africa LTD.
    url: https://ng.unyte.africa
    email: tech@unyte.com
servers: []
security: []
paths:
  /api/v1/claims/:
    post:
      tags:
        - Claims
      summary: Submit a claim
      description: Submits a new claim entry on behalf of a customer
      operationId: submit_claim
      parameters:
        - in: header
          name: U-Request-Id
          schema:
            type: string
          description: Idempotency key to enforce idempotent processing of POST requests
        - in: path
          name: id
          schema:
            type: string
          description: UUID of the claim
          required: true
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/ClaimRequest'
            examples:
              BasicValidPayloadWithRequiredFields:
                value:
                  claimant_metadata:
                    first_name: John
                    last_name: Doe
                    birth_date: '1985-05-15'
                    email: johndoe@example.com
                    relationship: Self
                  claim_details:
                    claim_type: accident
                    incident_description: Car accident on highway
                    incident_date: '2024-07-10'
                    claim_amount: '1500.00'
                    supporting_documents:
                      - document_name: Police Report
                        evidence_type: PDF
                        document_url: https://example.com/police-report.pdf
                        uploaded_at: '2024-07-11T08:00:00Z'
                  policy_id: 123e4567-e89b-12d3-a456-426614174000
                  witness_details: []
                  authority_report:
                    report_number: ABC123456
                    report_date: '2024-07-11'
                    filing_station: Miami Police Station
                summary: Basic valid payload with required fields
              MinimalValidPayloadWithOnlyRequiredField-OmittingOptionalFields:
                value:
                  claimant_metadata:
                    first_name: Alice
                    last_name: Johnson
                    birth_date: '1980-01-01'
                    email: alicejohnson@example.com
                    relationship: Parent
                  claim_details:
                    claim_type: theft
                    incident_description: Bicycle stolen from garage
                    incident_date: '2024-07-20'
                summary: >-
                  Minimal valid payload with only required field - omitting
                  optional fields
              FullValidPayloadWithAllFields:
                value:
                  claimant_metadata:
                    first_name: Jane
                    last_name: Smith
                    birth_date: '1990-12-01'
                    email: janesmith@example.com
                    phone_number: '+1234567890'
                    relationship: Spouse
                  claim_details:
                    claim_type: illness
                    incident_description: Hospitalized due to severe illness
                    incident_date: '2024-06-15'
                    claim_amount: '5000.00'
                    supporting_documents:
                      - document_name: Police Report
                        evidence_type: PDF
                        document_url: https://example.com/police-report.pdf
                        uploaded_at: '2024-07-11T08:00:00Z'
                  policy_id: 123e4567-e89b-12d3-a456-426614174001
                  policy_number: POL12345678
                  witness_details:
                    - witness_name: Michael Doe
                      witness_contact_phone: '+1987654321'
                      witness_contact_email: michael.doe@example.com
                      witness_statement: I saw the entire incident happen.
                  authority_report:
                    report_number: XYZ987654
                    report_date: '2024-06-17'
                    filing_station: IsaleEko Police Station
                summary: Full valid payload with all fields
          application/x-www-form-urlencoded:
            schema:
              $ref: '#/components/schemas/ClaimRequest'
            examples:
              BasicValidPayloadWithRequiredFields:
                value:
                  claimant_metadata:
                    first_name: John
                    last_name: Doe
                    birth_date: '1985-05-15'
                    email: johndoe@example.com
                    relationship: Self
                  claim_details:
                    claim_type: accident
                    incident_description: Car accident on highway
                    incident_date: '2024-07-10'
                    claim_amount: '1500.00'
                    supporting_documents:
                      - document_name: Police Report
                        evidence_type: PDF
                        document_url: https://example.com/police-report.pdf
                        uploaded_at: '2024-07-11T08:00:00Z'
                  policy_id: 123e4567-e89b-12d3-a456-426614174000
                  witness_details: []
                  authority_report:
                    report_number: ABC123456
                    report_date: '2024-07-11'
                    filing_station: Miami Police Station
                summary: Basic valid payload with required fields
              MinimalValidPayloadWithOnlyRequiredField-OmittingOptionalFields:
                value:
                  claimant_metadata:
                    first_name: Alice
                    last_name: Johnson
                    birth_date: '1980-01-01'
                    email: alicejohnson@example.com
                    relationship: Parent
                  claim_details:
                    claim_type: theft
                    incident_description: Bicycle stolen from garage
                    incident_date: '2024-07-20'
                summary: >-
                  Minimal valid payload with only required field - omitting
                  optional fields
              FullValidPayloadWithAllFields:
                value:
                  claimant_metadata:
                    first_name: Jane
                    last_name: Smith
                    birth_date: '1990-12-01'
                    email: janesmith@example.com
                    phone_number: '+1234567890'
                    relationship: Spouse
                  claim_details:
                    claim_type: illness
                    incident_description: Hospitalized due to severe illness
                    incident_date: '2024-06-15'
                    claim_amount: '5000.00'
                    supporting_documents:
                      - document_name: Police Report
                        evidence_type: PDF
                        document_url: https://example.com/police-report.pdf
                        uploaded_at: '2024-07-11T08:00:00Z'
                  policy_id: 123e4567-e89b-12d3-a456-426614174001
                  policy_number: POL12345678
                  witness_details:
                    - witness_name: Michael Doe
                      witness_contact_phone: '+1987654321'
                      witness_contact_email: michael.doe@example.com
                      witness_statement: I saw the entire incident happen.
                  authority_report:
                    report_number: XYZ987654
                    report_date: '2024-06-17'
                    filing_station: IsaleEko Police Station
                summary: Full valid payload with all fields
          multipart/form-data:
            schema:
              $ref: '#/components/schemas/ClaimRequest'
            examples:
              BasicValidPayloadWithRequiredFields:
                value:
                  claimant_metadata:
                    first_name: John
                    last_name: Doe
                    birth_date: '1985-05-15'
                    email: johndoe@example.com
                    relationship: Self
                  claim_details:
                    claim_type: accident
                    incident_description: Car accident on highway
                    incident_date: '2024-07-10'
                    claim_amount: '1500.00'
                    supporting_documents:
                      - document_name: Police Report
                        evidence_type: PDF
                        document_url: https://example.com/police-report.pdf
                        uploaded_at: '2024-07-11T08:00:00Z'
                  policy_id: 123e4567-e89b-12d3-a456-426614174000
                  witness_details: []
                  authority_report:
                    report_number: ABC123456
                    report_date: '2024-07-11'
                    filing_station: Miami Police Station
                summary: Basic valid payload with required fields
              MinimalValidPayloadWithOnlyRequiredField-OmittingOptionalFields:
                value:
                  claimant_metadata:
                    first_name: Alice
                    last_name: Johnson
                    birth_date: '1980-01-01'
                    email: alicejohnson@example.com
                    relationship: Parent
                  claim_details:
                    claim_type: theft
                    incident_description: Bicycle stolen from garage
                    incident_date: '2024-07-20'
                summary: >-
                  Minimal valid payload with only required field - omitting
                  optional fields
              FullValidPayloadWithAllFields:
                value:
                  claimant_metadata:
                    first_name: Jane
                    last_name: Smith
                    birth_date: '1990-12-01'
                    email: janesmith@example.com
                    phone_number: '+1234567890'
                    relationship: Spouse
                  claim_details:
                    claim_type: illness
                    incident_description: Hospitalized due to severe illness
                    incident_date: '2024-06-15'
                    claim_amount: '5000.00'
                    supporting_documents:
                      - document_name: Police Report
                        evidence_type: PDF
                        document_url: https://example.com/police-report.pdf
                        uploaded_at: '2024-07-11T08:00:00Z'
                  policy_id: 123e4567-e89b-12d3-a456-426614174001
                  policy_number: POL12345678
                  witness_details:
                    - witness_name: Michael Doe
                      witness_contact_phone: '+1987654321'
                      witness_contact_email: michael.doe@example.com
                      witness_statement: I saw the entire incident happen.
                  authority_report:
                    report_number: XYZ987654
                    report_date: '2024-06-17'
                    filing_station: IsaleEko Police Station
                summary: Full valid payload with all fields
        required: true
      responses:
        '201':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ClaimResponse'
              examples:
                ClaimSubmissionResponse:
                  value:
                    claim_id: d2d0c0b4-bf72-4a61-a02e-3ab896dd8bf7
                    claim_reference_number: CLAIM-20240813-5678
                    claim_status: submitted
                    insurer: Leadway Assurance
                  summary: Claim submission response
          description: Claim submitted successfully
      security:
        - ClientKeyAuth: []
components:
  schemas:
    ClaimRequest:
      type: object
      description: Validates incoming request data for creating a new claim.
      properties:
        claimant_metadata:
          $ref: '#/components/schemas/ClaimantMetadata'
        claim_details:
          $ref: '#/components/schemas/ClaimDetails'
        policy_id:
          type: string
          format: uuid
        policy_number:
          type: string
        witness_details:
          type: array
          items:
            $ref: '#/components/schemas/Witness'
        authority_report:
          $ref: '#/components/schemas/AuthorityReport'
      required:
        - claim_details
        - claimant_metadata
    ClaimResponse:
      type: object
      description: V2 Serializer for formating responses when
      properties:
        claim_id:
          type: string
          format: uuid
        policy_id:
          type: string
        claim_status:
          type: string
        insurer:
          type: string
      required:
        - claim_id
        - claim_status
        - insurer
        - policy_id
    ClaimantMetadata:
      type: object
      description: Validates incoming request data for creating a new claim.
      properties:
        first_name:
          type: string
        last_name:
          type: string
        birth_date:
          type: string
          format: date
        email:
          type: string
          format: email
        phone_number:
          type: string
        relationship:
          type: string
          description: The relationship of the claimant to the policyholder
      required:
        - birth_date
        - email
        - first_name
        - last_name
    ClaimDetails:
      type: object
      description: Specifies the data structure for capturing claim details
      properties:
        claim_type:
          $ref: '#/components/schemas/ClaimTypeEnum'
        incident_description:
          type: string
          description: Detailed account of the event that led to the claim
        incident_date:
          type: string
          format: date
        claim_amount:
          type: string
          format: decimal
          pattern: ^-?\d{0,8}(?:\.\d{0,2})?$
          description: Estimated amount of the claim in the format "1000.00"
        supporting_documents:
          type: array
          items:
            $ref: '#/components/schemas/ClaimDocument'
          description: >-
            List of supporting documents in the format [{"document_name": "Name
            of Document", "evidence_type": "Type of Evidence", "blob": "Base64
            encoded document"}]
      required:
        - claim_type
        - incident_date
    Witness:
      type: object
      description: >-
        Specifies the data structure for capturing witness information of a
        claim


        There can be 0 - n witnesses for a claim
      properties:
        witness_name:
          type: string
          description: Full name of the witness in the format, "First Name Last Name"
        witness_contact_phone:
          type: string
        witness_contact_email:
          type: string
          format: email
        witness_statement:
          type: string
          description: A brief statement from the witness about the incident
      required:
        - witness_name
        - witness_statement
    AuthorityReport:
      type: object
      description: Specifies the data structure for the Authority Report e.g Police Report
      properties:
        report_number:
          type: string
        report_date:
          type: string
          format: date
        filing_station:
          type: string
      required:
        - report_date
        - report_number
    ClaimTypeEnum:
      enum:
        - basic
        - premium
        - advanced
        - accident
        - death
        - illness
        - theft
        - other
      type: string
      description: |-
        * `basic` - Basic
        * `premium` - Premium
        * `advanced` - Advanced
        * `accident` - Accident
        * `death` - Death
        * `illness` - Illness
        * `theft` - Theft
        * `other` - Other
    ClaimDocument:
      type: object
      properties:
        document_name:
          type: string
          description: Name of the document uploaded.
          maxLength: 255
        evidence_type:
          allOf:
            - $ref: '#/components/schemas/EvidenceTypeEnum'
          description: |-
            Type of evidence uploaded.

            * `video` - Video
            * `audio` - Audio
            * `document` - Document
            * `picture` - Picture
        document_url:
          type: string
          format: uri
          nullable: true
          title: File Reference
          description: >-
            Reference to the stored document (e.g., Google Cloud Storage blob
            name).
          maxLength: 1024
        uploaded_at:
          type: string
          format: date-time
          readOnly: true
      required:
        - document_name
        - evidence_type
        - uploaded_at
    EvidenceTypeEnum:
      enum:
        - video
        - audio
        - document
        - picture
      type: string
      description: |-
        * `video` - Video
        * `audio` - Audio
        * `document` - Document
        * `picture` - Picture
  securitySchemes:
    ClientKeyAuth:
      type: apiKey
      in: header
      name: X-API-Key

````