This site contains the documentation that is relevant to older WSO2 product versions and offerings.
For the latest WSO2 documentation, visit https://wso2.com/documentation/.
Working with Tips in Foursquare
The addTips
operation adds a tip on a venue.
addTips
<foursquare.addTips> <venueId>{$ctx:venueId}</venueId> <tip>{$ctx:tip}</tip> <url>{$ctx:url}</url> <broadcast>{$ctx:broadcast}</broadcast> </foursquare.addTips>
properties
venueId
: The venue where you want to add this tip.tip
: The text of the tip, up to 200 characters.url
: A URL related to this tip.broadcast
: Whether to broadcast this tip.
Sample request
Following is a sample REST/JSON request that can be handled by the addTips
operation.
sample request for addTips
{ "apiUrl":"%https://api.foursquare.com", "venueId":"4d6728f6a88a6ea8aa9fe072", "tip":"Awesome Place................!!!!!!!" "accessToken":"VCNCLT0LGPHREG5CFWGWKBCY0T5HOSWYALVOFOQC24IPMM4U" }
Related Foursquare documentation
https://developer.foursquare.com/docs/tips/add
Sample Configuration
Following is a sample proxy service that illustrates how to connect to Foursquare with the init
 operation and use the addTips
operation. The sample request for this proxy can be found in addTips sample request. You can use this sample as a template for using other operations in this category.
Sample proxy
<proxy xmlns="http://ws.apache.org/ns/synapse" name="addTips" transports="https,http" statistics="disable" trace="disable" startOnLoad="true"> <target> <inSequence> <property name="apiUrl" expression="json-eval($.apiUrl)"/> <property name="accessToken" expression="json-eval($.accessToken)"/> <property name="venueId" expression="json-eval($.venueId)"/> <property name="tip" expression="json-eval($.tip)"/> <property name="url" expression="json-eval($.url)"/> <property name="broadcast" expression="json-eval($.broadcast)"/> <foursquare.init> <apiUrl>{$ctx:apiUrl}</apiUrl> <accessToken>{$ctx:accessToken}</accessToken> </foursquare.init> <foursquare.addTips> <venueId>{$ctx:venueId}</venueId> <tip>{$ctx:tip}</tip> <url>{$ctx:url}</url> <broadcast>{$ctx:broadcast}</broadcast> </foursquare.addTips> <respond/> </inSequence> <outSequence> <send/> </outSequence> </target> <description/> </proxy>