Overview of questions

From an LOB perspective, a question is a prompt for information that can be used to pre-qualify an account holder or obtain additional information for rating a policy.

Questions are grouped together into question sets. There are three elements of a product that a question set can be associated with:

  • The policy period
  • The line
  • A policy location

When a policy period, line, or policy location is created, a set of QuestionAnswers are created for any associated questions as defined in the product definition. Each QuestionAnswer stores a question and its answer, if an answer has been provided.

LOB-endpoint pattern for questions

For every question set, there is a set of two endpoints:

  • GET ‚Äč.../questions
    • Retrieves all possible questions and their answers
  • PATCH .../questions
    • PATCHes the answers to one or more questions

There can be multiple pairs of question endpoints, depending on how many question sets a product has and where those questions sets are attached to the product.

Policy period question set endpoints exist at the job level. From a technical perspective, these are not LOB-specific endpoints. There is a single pair of endpoints for all products:

  • GET /job/v1/jobs/{jobId}/questions
  • PATCH /job/v1/jobs/{jobId}/questions

Line question set endpoints exist at the line level. These are LOB-specific endpoints. There is one pair of endpoints for each line question set in each product. For example:

  • GET /job/v1/jobs/{jobId}/lines/{lineId}/questions
  • PATCH /job/v1/jobs/{jobId}/lines/{lineId}/questions

Location question set endpoints exist at the location level. From a technical perspective, these are not LOB-specific endpoints. There is a single pair of endpoints for all products:

  • GET /job/v1/jobs/{jobId}/locations/{locationId}/questions
  • PATCH /job/v1/jobs/{jobId}/locations/{locationId}/questions