Betavine API Reference Manual

Chapter 4. Data Model

The Betavine API returns a variety of information. The following chapter describes how information is modelled and how it is represented in the different Response Formats .

A model can contain one or more members. A member can be a simple data type or another model. A member can be directly associated with an attribute or child element in XML notation, or an object variable in JSON.

For each model in this chapter a diagram of their members has been included. The members with a black outline will always be present. Those in red are dependant on the method called.

The Response model will always be returned from by the Vodafone Betavine API. It acts as a container for other information specific to individual API calls.

Properties

method

The path of the API Method. E.g. For Send SMS this would be send/sms.

version

The current version of the API. To avoid incompatibility errors ensure that the API version returned is the same as the one for which the application has been developed.

status

Whether or not the response was executed sucessfully or not. It can be either of the following values:

  • OK

    The API request has been successfully processed.

  • FAIL

    An error has occured. Check the Error model.

error

If the status of the Response is FAIL then Error will be populated with information about the API method failure. See Error Model .

transaction

Available on either a Send SMS, WAP Push, Application Trigger or Status API call. See Transaction Model.

applications

Available on either a Search Applications or Find Applications API call. It is a list of Application Model s.

files

Returned in the response of Find Files API call. It is a list of File Model s.

total

If the Response contains a Application model it will return the total number of Application s hosted by Betavine.

If the Response contains a File model it will return the total number of File s hosted by Betavine.

totalPages

If the Response contains a list of Application models or File models this will contain the total number of pages in the result set. The page size is determined by the limit paramter.

currentPage

If the Response contains a list of Application models or File models this will contain the current page number. The page size is determined by the limit paramter.

device

Available on a Find Device Firmware API call. See Firmware Model .

firmware

Available on a Find Device Properties API call. See Firmware Model .

Figure 4.1. Response Model

Response Model