Skip to content

Instantly share code, notes, and snippets.

@seanrucker seanrucker/Mobile API
Last active Aug 29, 2015

Embed
What would you like to do?
## Create A Visit
`POST /visits`
````javascript
{
uuid: "ABC123",
majorNumber: "12984",
customer: {
customerID: "800000516109",
name: "Sean",
email: "srucker@gmail.com",
attributes: {
gender: "male"
}
},
device: "iPhone 5S",
operatingSystem: "iOS",
operatingSystemVersion: "8.1",
version: "0.24.1"
}
````
## Enter Location
`POST /visits/:id/events`
````javascript
{
object: "location",
action: "enter",
timestamp: "2015-01-08"
}
````
## Exit Location
POST /visits/:id/events
{
object: "location",
action: "exit",
timestamp: "2015-01-08"
}
## Enter Touchpoint
POST /visits/:id/events
{
object: "touchpoint",
action: "enter",
timestamp: "2015-01-08",
touchpoint: "ab123"
}
## Exit Touchpoint
POST /visits/:id/events
{
object: "touchpoint",
action: "exit",
timestamp: "2015-01-08",
touchpoint: "ab123"
}
## Open app while visiting a Touchpoint
POST /visits/:id/events
{
object: "touchpoint",
action: "open",
timestamp: "2015-01-08",
touchpoint: "ab123"
}
## View a Card
POST /visits/:id/events
{
object: "card",
action: "view",
timestamp: "2015-01-08",
card: "abc123"
}
## Click a link in a Card
POST /visits/:id/events
{
object: "card",
action: "click",
timestamp: "2015-01-08",
card: "abc123",
url: "rover://view?id=def456"
}
## Save a card
POST /visits/:id/events
{
object: "card",
action: "save",
timestamp: "2015-01-08",
card: "abc123"
}
## Discard a card
POST /visits/:id/events
{
object: "card",
action: "discard",
timestamp: "2015-01-08",
card: "abc123"
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.