|
|
2. MyVox API presentation summaryThe first step you should take before using the MyVox API is to create a developer account. This account will provide you with a voice recorder key that will allow your application to make API calls. This recorder key will allow you to customize your user experience by creating your own voice prompts on the MyVox phone system. The MyVox API is documented in a PDF available online here: http://www2.myvox.com/downloads/api_1.pdf In order to get the most of this tutorial, it would be best to have the API documentation open as you read the tutorial, so you can refer to the official documentation for details on the API commands. The API works by sending HTTP GET or POST queries which include your recorder key, the command you want the system to perform, and other parameters. The request response comes in your choice of XML or JSON, specified as well as a query parameter. Let’s now explore briefly the main commands most applications will have to use. CreateRecordingList: As each application instance should have its recording list, the first action the gadget should do is to send a query to create a new recording list, and store the recording list key return in the command response. GetRecording: The GetRecording command will provide the data of a specific recording or of all the recordings available for the application if no recording key is specified. If the application has not yet created any recording, the list will be empty. CreateRecording: The CreateRecording command is the first step when creating a new recording. This command will only create a placeholder in the recording list and will allow a recording session to be initiated. StartRecordingSession: The StartRecordingSession command starts the second step of the recording sequence. This command will return the phone number and the pin number that the user must call from his/her phone to record the message. GetSessionStatus: While the recording session is in progress, the GetSessionStatus command allows the application to pull the status of the session. This allows the user to get some visual feedback in the gadget of the recording process while he/she is one the phone. DeleteRecording: The DeleteRecording command allows deleting a recording from the recording list. The other API commands available are DeleteRecordingList, ExpireRecordingSession, GetRecordingList, SetRecording, and SetRecordingList. Please refer to the MyVox developer website for more information on these commands, as they will not be used in our tutorial Voice Memo application. Note that the MyVox API supports metadata storage with a recording list or individual recordings. This functionality is not utilized in our tutorial, but this is important to keep it in mind, as in most cases, you will not need to setup your own data storage for your application. The iGoogle user preferences and the MyVox recording and metadata storage should provide you with everything you need to create voice enabled applications. Now that you understand the basics of the MyVox API, let’s look at how we can call these commands from the Google Gadget API. Note: If this quick presentation leaves you with some questions about the MyVox API, or if you would like to get more details, have a look at the Getting Started with MyVox API website here http://www2.myvox.com/developers/getstarted.asp Next, 3. How to call MyVox commands from the Google Gadget API |