This document provides an overview of the Data-Applied API for developers. It describes how to register and log in to access the XML-based API. It explains that requests and responses are sent in XML format and must be in UTF-8 encoding. It also provides an example of how to log in, get a ticket, and extract user information from the response. Finally, it describes entities, messages, and properties that make up the API.
2. Getting started To get the login username and password, register at: http://www.data-applied.com/App/ This will work in only those browsers which support Microsoft Silverlight Confirm the registration from your email account The username and password set will be used to login before one can use there XML based API One can also use there XML based API to do the registration (to be covered later)
3. XML based API One can communicate with data-applied using there XML based API Requests and Replies from data-applied are sent in XML format Request XML should be in UTF-8 format Requests needs to be submitted at http://www.data-applied.com/app/Execute/default.aspx
4. A quick example Now we will demonstrate how to do: Quick login Obtain a ticket in response which is a must to validate further queried We have the login XML in file login.xml: <LogonMessage> <Instance> <UserInfo> <Password>passwor</Password> <Name>xyz</Name> </UserInfo> </Instance> </LogonMessage>
5. A quick example We read this file, login.xml, in a string: login _string = open(‘login.xml’,’r’).read() Convert the string to UTF-8 login_string_utf = unicode(login_string,’utf-8’) Now we are ready to send our request. Sending this request using HTTP (in a quick but inefficient way, just for demonstration): reply = urllib.urlopen(“http://www.data-applied.com/app/Execute/default.aspx”, login_string_utf) If the credentials provided were correct, then the reply will give us the XML in reply to our request reply_xml = reply.read()
6. A quick example Reply XML looks like: <LogonMessage> <Instance> <UserInfo> <Id>id</Id> <Name>username</Name> <FirstName>fname</FirstName> <LastName>lname</LastName> <EmailAddress>xyz@zyz.com</EmailAddress> <DateCreated>01/12/2010 02:25:35</DateCreated> <LicenseKey>Organization=*;Workspaces=1;Tables=1;Rows=500;Fields=6;FileSize=102400;Tasks=1;Priority=0;;UserName=username;:*</LicenseKey> </UserInfo> </Instance> <Version>1.1</Version> <Ticket>ticket</Ticket> </LogonMessage> And by parsing this XML all the relevant information can be extracted
9. An Example So using the properties of ChunkInfo , our message will look like: <CreateMessage> <Instance><ChunkInfo> <WorkspaceInfoId>4f5ad0e3-8ef5-...</WorkspaceInfoId> <TableInfoId>ddb37ed0-cc91-...</TableInfoId> <FileName>data.csv</FileName> <Content>...[base64 data]...</Content> <HasFieldHeader>True</HasFieldHeader> </ChunkInfo> </Instance> <Ticket>...</Ticket> </CreateMessage>
10.
11.
12. The tutorials section is free, self-guiding and will not involve any additional support.