Creating a Survey Application with VoiceXML and Entity Framework

A new example has been added to the VoiceModel Project that shows how to create a flexible survey application.  Surveys are powerful tools for soliciting information from customers that can improve business.  Using a voice application over a telephone to perform the survey as another channel of communicating with your customers can be extremely beneficial to understanding what they think of a companies products and services. This survey application is very flexible in that that the survey configuration is stored in a database so that new surveys can be created and old ones modified without creating a new voice application call flow each time.  This the first in a series of posts that describes how the Survey Application is designed and areas of future work to make it even more robust and flexible.

The Survey Application uses Entity Framework (EF) version 5 for object-relational mapping (ORM) and uses the code-first model.  The code-first model allows you to define your objects/entities first and have EF automatically create the database schema for you.  You can fine the entities for the Survey Application in the Survey.Entities project.  The following diagram shows the entities and their relationship.

There can be multiple Surveys which are identified by their Name. Each Survey has multiple Questions. Currently Questions can have two types of responses; a boolean response which expects a yes or no response, or a list of possible answers.  Therefore a Question may have multiple PossibleAnswers.  More types will be added in the future versions, such as a rating (ex: rate your experience from 0 to 9).  A Question can have multiple SurveyResponses which indicate the answers to the survey questions given by a User.  Users can have multiple SurverResponses.

In the next installment we will explore the layered architecture used for the Survey Application and how the database is created and seeded by just running the application.

Comments

Popular posts from this blog

Using Claims in ASP.NET Identity

Customizing Claims for Authorization in ASP.NET Core 2.0

Seeding & Customizing ASP.NET MVC SimpleMembership