RESTful API

Send Location

Previous Versions

Overview

Report a device current location to the Campaign Manager. It's supposed to be used from your App if you are developing yours.

This method needs to be invoked as a reaction of calling the Request Device Location method

URL

Parameters on the following URL are inside braces { }

{base_url}/rest/api/tools/sendLocation/{instanceId}/{requestId}/{date}/{latitude}/{longitude}/{publicKey}/{signature}
Parameter Name Description
instanceId An instance id is the workspace identification number, if you don't know yours please request it using our ticketing tool, you will need to provide your Mobile Engagement Campaign Manager's URL and your user login
requestId This the request identifier. Originated by the Request Device Information method
date The current time & date. formatted date string: yyyy-MM-dd'T'HH:mm:ss.SSSZZ For more information please review the pattern letters quick reference
latitude The point latitude Number (decimal notation)
longitude The point longitude Number (decimal notation)
publicKey The public key to access this API. if you don't know yours please request it using our ticketing tool, you will need to provide your Mobile Engagement Campaign Manager's URL and your user login
signature The unique SHA256 signature for this call, it's involve all input parameters. To learn about generating the correct signature please visit our Java Example

Response

The Response XML is divided in a static part and a dynamic one, we call it dynamic because it will vary depending on the method you invoke. Please read our Response XML Basics section if you want to learn more about the response parts.

<input>sendLocation</input>
<status>OK</status>
<description>Completed</description>
<result>
	<LocationRequest>
		<requestId>3d97e8ca-fcc9-4f15-8c22-8cbf123c723f</requestId>
		<user>13056708084</user>
		<requestType>LOCATION</requestType>
		<latitude>8.599172</latitude>
		<longitude>-71.141196</longitude>
		<status>PENDING</status>
		<clientId>uTJoDFuabB6YFvc9s43</clientId>
		<appName>AppName</appName>
		<platform>IOS</platform>
		<date>2014-03-17T17:26:23.133-04:30</date>
	</LocationRequest>
</result>
Result parameters
Parameter Name Description Possible Values
LocationRequest.requestId This is your request identifier Text
LocationRequest.user The deviceId or mobile phone number Text
LocationRequest.requestType The request's type. In this case: LOCATION
LocationRequest.latitude The device's latitude. Number (decimal notation) Starting value: 0.0
LocationRequest.longitude The device's longitude. Number (decimal notation) Starting value: 0.0)
LocationRequest.status This is the general status for the operation Starting value: PENDING
LocationRequest.clientId This is your unique id, it represents you on the Campaign Manager Platform Text
LocationRequest.appName The identifier of the application, which will receive the push message. Text
LocationRequest.platform The target platform used Valid values:
ANDROID
IOS
LocationRequest.date Time mark at the origination moment A formatted date string: yyyy-MM-dd'T'HH:mm:ss.SSSZZ
For more information please review the pattern letters quick reference