---
title: "Submit Annuity Documents to Zinnia"
url: "https://developers.zinnia.com/apis/new-business-annuity/versions/45a989ab-c3aa-4f85-8f67-f05c41747ed7/operations/createAnnuityDocument"
---

> Full API specification: https://developers.zinnia.com/apis/new-business-annuity/versions/45a989ab-c3aa-4f85-8f67-f05c41747ed7.md

# Submit Annuity Documents to Zinnia

`POST` `/eApp/v1/applications/documents`

Operation ID: `createAnnuityDocument`

## Header parameters

- `Authorization` (string, required) - This will be passed as Bearer plus "token" as generated by above token API.

## Request body (required)

Content types: `application/json`

## Responses

- `201` - Created
- `400` - Bad request
- `401` - Authentication failed
- `403` - Access denied
- `500` - Server error

## OpenAPI definition

```yaml
openapi: 3.1.0
info:
  title: Zinnia New Business Annuity API
  version: 0.6.0
servers:
  - url: https://qa.api.zinnia.io
    description: QA Environment
  - url: https://dev.api.zinnia.io
    description: DEV Environment
  - url: https://uat.api.zinnia.io
    description: UAT Environment
  - url: https://api.zinnia.io
    description: PROD Environment
paths:
  /eApp/v1/applications/documents:
    post:
      tags:
        - Annuity Version 1
      summary: Submit Annuity Documents to Zinnia
      operationId: createAnnuityDocument
      parameters:
        - name: Authorization
          required: true
          description: This will be passed as Bearer plus "token" as generated by above
            token API.
          in: header
          schema:
            type: string
          example: Bearer eykjsfjfjasdasdad
      requestBody:
        description: Details required to submit the eApp to Zinnia for Annuity
        content:
          application/json:
            schema:
              $ref: "#/components/schemas/DocumentInformation"
        required: true
      responses:
        "201":
          description: Created
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/SuccessResponse"
        "400":
          description: Bad request
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/ValidationResponse"
        "401":
          description: Authentication failed
        "403":
          description: Access denied
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/AccessDeniedResponse"
        "500":
          description: Server error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/ServerErrorResponse"
      security:
        - Auth0: []
security:
  - Auth0: []
components:
  schemas:
    DocumentInformation:
      type: object
      required:
        - appId
        - version
        - effectiveDate
        - totalDocumentCount
        - documentDetails
      properties:
        appId:
          type: string
          description: Unique Identifier against an e-App application. First 4 letters
            represent the receiving company, next 3 letters represent the firm,
            next 8 positions represent the date eApp is submitted, next 10
            positions represents the sequential number of the eApps from the
            eApp instance. For Orion - Accept integers upto 15 digits
          example: XXXXEDJ041120240000000001
        version:
          type: string
          description: Version for that case - 3 digits, incremental if same case if
            submitted more than once in case of errors. For Orion - Accept
            integers upto 15 digits
          example: "000"
        effectiveDate:
          type: string
          format: date
          pattern: ([0-9]{4})-([0-9]{2})-([0-9]{2})
          description: e-App submitted date to Zinnia (with pattern "yyyy-mm-dd").
          example: 2023-12-19
        totalDocumentCount:
          type: number
          example: 1
        documentDetails:
          type: array
          items:
            $ref: "#/components/schemas/DocumentDetail"
    SuccessResponse:
      type: object
      properties:
        statusCode:
          type: integer
          format: int32
          example: 201
        timestamp:
          type: string
          format: date-time
        message:
          type: string
          example: Request Submitted Successfully
    ValidationResponse:
      type: object
      properties:
        statusCode:
          type: integer
          format: int32
          example: 400
        timestamp:
          type: string
          format: date-time
        errorId:
          type: string
          example: a4a57ed0-2c1b-4922-9959-3b85dd8a96d3
        message:
          type: string
          example: JSON Valdiation fails with error
        error:
          type: array
          items:
            type: string
            example: Mandatory attribute label missing
    AccessDeniedResponse:
      type: object
      properties:
        timestamp:
          type: string
          format: date-time
        message:
          type: string
          example: "User is not authorized for the carrier : CarrierName_1"
    ServerErrorResponse:
      type: object
      properties:
        statusCode:
          type: integer
          format: int32
          example: 500
        timestamp:
          type: integer
          format: int64
          example: 1681395423438
        errorId:
          type: string
          example: 0286d47a-7ad9-499c-8ca0-8f6634d236a3
        message:
          type: string
          example: Failed to process request
    DocumentDetail:
      type: object
      required:
        - documentId
        - binaryData
        - formId
        - formName
        - documentCategory
        - documentFileType
      properties:
        documentId:
          type: string
          description: Unique Identifier for the individual document. Duplicate document
            Ids will be rejected.
          example: 0ca10708-4b53-464c-b745-355c8f6f0edb
        binaryData:
          type: string
          description: Base 64 encoded binary stream
          example: SGVsbG8gV29ybGQ=
        formId:
          type: string
          description: Unique ID for a Form
          example: FR2279
        formName:
          type: string
          description: Unique Name for a form
          example: Fixed Annuity Order Entry Cover Sheet
        documentCategory:
          type: string
          description: Category of the document as per OnBase system
          example: NB Supporting Document
        documentFileType:
          type: string
          enum:
            - pdf
          description: Type of file
          example: pdf
  securitySchemes:
    Auth0:
      type: openIdConnect
      openIdConnectUrl: https://login.uat.zinnia.com/.well-known/openid-configuration
      x-kong-security-openid-connect:
        config:
          run_on_preflight: true
          scopes_claim:
            - https://uat.api.zinnia.io/permissions
          audience_claim:
            - aud
          audience_required:
            - https://uat.api.zinnia.io
          client_id:
            - client_id
          auth_methods:
            - bearer
        enabled: true
        protocols:
          - grpc
          - grpcs
          - http
          - https
```
