Create a session

POST /api/v1/apply/sessions

Creates a session object.

application/json

Body

  • The URL the contractor will be directed to if they are ineligible or decide to abandon the insurance application and return to your website.

  • quote string Required

    The ID of an existing quote to be associated with the insurance application session.

  • The URL to which 1099Policy should direct independent contractors when a contractor successfully procures insurance coverage.

Responses

  • 201 application/json

    Returns the session object for an insurance application if quote, job, and contractor are valid.

    Hide response attributes Show response attributes object
    • The URL the contractor will be directed to if they are ineligible or decide to abandon the insurance application and return to your website.

    • created integer(int64)

      Time at which the object was created. Measured in seconds since the Unix epoch.

    • expired boolean

      Indicates whether the insurance application session has expired. If true, the contractor will be redirected to the cancel_url.

    • id string
    • quote string

      The ID of the quote associated with the insurance application session.

    • step string

      The step in the insurance application process that the contractor is currently on. The contractor will be redirected to this step when they return to the insurance application. One of verify_info, application_questions, esignature_document, add_card_details, final_review, or application_complete.

      Values are verify_info, application_questions, esignature_document, add_card_details, final_review, or application_complete.

    • The URL to which 1099Policy should direct independent contractors when a contractor successfully procures insurance coverage.

    • url string

      The URL to the insurance application Session. Redirect customers to this URL to take them to their insurance application. The domain will use apply.1099policy.com.

POST /api/v1/apply/sessions
curl \
 -X POST https://api.1099policy.com/api/v1/apply/sessions \
 -H "Content-Type: application/json" \
 -d '{"cancel_url":"https://1099jobcloud.com/1099policy/cancel","quote":"qt_5DciVga8Kt","success_url":"https://1099jobcloud.com/1099policy/success"}'
Request example
{
  "cancel_url": "https://1099jobcloud.com/1099policy/cancel",
  "quote": "qt_5DciVga8Kt",
  "success_url": "https://1099jobcloud.com/1099policy/success"
}
Response examples (201)
{
  "cancel_url": "https://1099jobcloud.com/1099policy/cancel",
  "created": 1646818364,
  "expired": false,
  "id": "ias_01FVCHXE7PNQHA1T3S2AXL2QZE",
  "quote": "qt_5DciVga8Kt",
  "step": "final_review",
  "success_url": "https://1099jobcloud.com/1099policy/success",
  "url": "http://apply.1099policy.com/..."
}