---
title: "EDelivery Enrollment"
url: "https://developers.zinnia.com/apis/policy-transactions-1-0-2/versions/d0006570-ab9d-464e-814f-d120ba425e84/operations/EDeliveryEnrollment1"
---

> Full API specification: https://developers.zinnia.com/apis/policy-transactions-1-0-2/versions/d0006570-ab9d-464e-814f-d120ba425e84.md

# EDelivery Enrollment

`POST` `/policy/v1/transactions/{planCode}/{policyNumber}/edeliveryenrollment`

Operation ID: `EDeliveryEnrollment1`

## Path parameters

- `planCode` (string, required)
- `policyNumber` (string, required)

## Request body (required)

Content types: `application/json`

## Responses

- `200` - Success
- `400` - BadRequest
- `500` - Internal Server Error

## OpenAPI definition

```yaml
openapi: 3.1.0
info:
  title: Zinnia Policy Transactions API.
  version: 1.0.8
servers:
  - url: https://dev.api.zinnia.io
    description: DEV Environment
  - url: https://qa.api.zinnia.io
    description: QA Environment
paths:
  /policy/v1/transactions/{planCode}/{policyNumber}/edeliveryenrollment:
    post:
      x-kong-plugin-pre-function:
        config:
          access:
            - >
              local path = kong.request.get_path()

              local new_path = path:gsub("^/policy/v1/transactions",
              "/bpm/v1/policies")

              kong.service.request.set_path(new_path)
      tags:
        - Non Financial Transactions
      summary: EDelivery Enrollment
      operationId: EDeliveryEnrollment1
      parameters:
        - name: planCode
          in: path
          required: true
          schema:
            type: string
        - name: policyNumber
          in: path
          required: true
          schema:
            type: string
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: array
              items:
                $ref: "#/components/schemas/EDeliveryEnrollmentRequest"
      responses:
        "200":
          description: Success
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/TransactionAcceptedResponse"
        "400":
          description: BadRequest
          content:
            application/json:
              schema:
                anyOf:
                  - $ref: "#/components/schemas/TransactionFailureResponse"
                  - $ref: "#/components/schemas/ValidationResponse"
              examples:
                businessRuleFailure:
                  $ref: "#/components/examples/failureTransactionResponse"
                valdiationFailure:
                  $ref: "#/components/examples/validationFailureResponse"
        "500":
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/ServerErrorResponse"
      security:
        - Auth0: []
security:
  - Auth0: []
components:
  schemas:
    EDeliveryEnrollmentRequest:
      type: object
      properties:
        id:
          type: string
          description: preferenceId  (should be null for preference creation)
          example: e22cd4aee27d34c9b7c748d50e558b41
        carrierId:
          type: string
          description: carrier id for policy
          example: CARRIERID_1
        deliveryOption:
          type: string
          enum:
            - EMAIL
            - FAX
            - MAIL
          description: Delivery Options - Applicable values EMAIL/FAX/MAIL
          example: EMAIL
        email:
          type: string
          example: abc.def@gmail.com
          description: User's email
        effectiveFrom:
          type: string
          format: date-time
          description: Date (with pattern "yyyy-MM-dd'T'HH:mm:ss'Z'") when the preference
            will be effective, default value is '2999-12-31T00:00:00.000Z'
        effectiveTo:
          type: string
          format: date-time
          description: Date (with pattern "yyyy-MM-dd'T'HH:mm:ss'Z'") when the preference
            will stop being effective
        documentType:
          type: string
          enum:
            - NWB
            - ANST
            - CONF
            - TAX
            - AGNT
            - POLPG
          description: Type of document
          example: AGNT
        partyId:
          type: string
          description: Unique reference id of the party
          example: f22de4bff27e45d9a7c859e61f668c50
        acknowledgedByPartyId:
          type: string
          description: Party that initiated the acknowledgment (i.e. an agent, if not the
            party referred to by partyId)
          example: f22de4bff27e45d9a7c859e61f668c50
      required:
        - carrierId
        - deliveryOption
        - effectiveFrom
        - documentType
        - partyId
        - acknowledgedByPartyId
    TransactionAcceptedResponse:
      type: object
      properties:
        correlationId:
          type: string
          example: 3a2a3435-2089-4b81-9959-e0d569ccf4f0
          description: Unique identifier which used by every system to trace the request
        caseId:
          type: string
          example: CA0000369469
          description: Zinnia Live Case ID
        caseStatus:
          type: string
          example: IN_PROGRESS
          description: Zinnia Live Case Status
        pdfId:
          type: string
          description: Identifier for the generated or associated PDF document (e.g.
            OnBase document number). Returned on systematic program setup and
            update submit when available.
          example: DOC-10004567
    TransactionFailureResponse:
      type: object
      properties:
        status:
          type: string
          enum:
            - success
            - failure
        validationResult:
          type: array
          items:
            $ref: "#/components/schemas/Error"
    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
    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
    Error:
      type: object
      properties:
        errorCode:
          type: string
          example: BPM.NM.002
          description: This is the NIGO id generated by BPM system
        attribute:
          type: string
        error:
          type: string
          description: This is the error generated by BPM system
        resolution:
          type: string
          description: Resolution generated by BPM system to resolve the error
  examples:
    failureTransactionResponse:
      value:
        status: failure
        validationResult:
          - errorCode: BPM.NM.005
            attribute: null
            error: Amount request is invalid.
            resolution: Please check the One Time Premium Amount and submit the request
              again.
          - errorCode: BPM.NM.003
            attribute: null
            error: Party information does not match with information in the Zahara system.
            resolution: Please validate the party information and submit the request again.
    validationFailureResponse:
      value:
        statusCode: 400
        timestamp: 2024-10-08T13:23:10.124Z
        errorId: a4a57ed0-2c1b-4922-9959-3b85dd8a96d3
        message: JSON Valdiation fails with error
        error:
          - attribute can not be null
          - attribute should be in proper format
  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
```
