API Endpoints
journal
The journal endpoint supports GET, POST and PUTmethods to get journal lists, create a journal entry, and modify journal attributes, respectively.
GET
The journal endpoint returns lists of journal entries. The items included in the list depend on the type of journal request made and the limit and range specified. The limit is 20 if not specified. The maximum is 200. Journal entries are returned in reverse chronological order (most recent to least recent). Date ranges are defined by 'since' and 'until'. 'since' defines start of range and anything earlier down to 'until' date if defined, or anytime earlier if not. 'since' and 'until' are exclusive while 'now' is inclusive.
| Method |
Description |
| /me/journal?type=user |
return current entries for the authenticated user |
| /me/journal?type=friends |
return current entries for friends of the authenticated user |
| /me/journal?type=all |
return current entries for the authenticated user and his friends |
| /me/journal?type=relevant |
return current entries for the authenticated user with media and most interesting public entries with at least 2 photos for activity feed display when not logged in to the website |
| /me/journal?type=user&limit=10 |
return 10 entries for the authenticated user |
| /me/journal?type=user&until=2011-01-02T14:01:00.0&limit=100 |
return entries from now until date specified or 100, whichever is less for the authenticated user |
| /me/journal?type=user&since=2011-01-02T14:01:00.0&limit=10 |
return 10 entries starting from since and earlier for the authenticated user |
| /me/journal?type=friends&since=2011-01-03T14:01:00.0&until=2011-01-01T14:01:00.0&limit=20 |
return 20 entries between since and until for friends |
| /USERID/journal?type=trips |
return 20 public trips of USERID, all trips are returned if access_token provided for USERID |
Example1: GET type=user&until=TIMESTAMP&limit=NUMBER_OF_ENTRIES
GET http://api.hipgeo.com/me/journal?type=user&until=2011-01-02T14:01:00.0&limit=4&access_token=TOKENVALUE
Returns:
{
"count":4,
"data":[
{
"id":"j_134813",
"from":{
"id":"u_111",
"name":"Joe",
"shareable":1,
"pingable":1,
"url":"http:\/\/www.hipgeo.com\/Joe",
"fullname":"Joe Chan",
"avatar":{
"id":"m_11101",
"shareable":0,
"type":0,
"when":"2012-01-06 22:42:29",
"icon":"http:\/\/img.hipgeo.com\/4c0faecc4ffdb3c15ea72a5f0ee8fb58_m?11101",
"icon_l":"http:\/\/img.hipgeo.com\/4c0faecc4ffdb3c15ea72a5f0ee8fb58_l?11101",
"icon_b":"http:\/\/img.hipgeo.com\/4c0faecc4ffdb3c15ea72a5f0ee8fb58_b?11101",
"full":"http:\/\/img.hipgeo.com\/4c0faecc4ffdb3c15ea72a5f0ee8fb58_d?11101",
"height":494,
"width":662
},
"photo":"http:\/\/img.hipgeo.com\/4c0faecc4ffdb3c15ea72a5f0ee8fb58_b?11101"
},
"type":2,
"when":"2012-03-30 18:10:43.863",
"user_when":"2012-03-30 11:10:43.863",
"privacy":3,
"user_modified":1,
"shareable":1,
"liked":0,
"title":"Hipgeo Cosmic Headquarters",
"content":"Hipgeo Cosmic Headquarters from 9:57am to 11:10am PDT (1 hr, 13 mins) in Fullerton, CA.",
"tags":"fullerton, california",
"location":{
"id":"l_144005",
"shareable":1,
"canmerge":1,
"name":"Hipgeo Cosmic Headquarters",
"title":"Hipgeo Cosmic Headquarters, Fullerton, CA",
"duration":4398,
"duration_sec":4398,
"hidestats":0,
"uid":"u_111",
"type":1,
"coord":{
"lat":33.87104,
"lon":-117.923998,
"radius":0
},
"pid":"p_31463"
},
"commentcount":0,
"likecount":0,
"mediacount":3,
"media":{
"count":3,
"data":[
{
"id":"m_34606",
"shareable":1,
"type":0,
"when":"2012-03-30 17:17:19",
"icon":"http:\/\/img.hipgeo.com\/4d8fafb54101bc1cd31f4f506f31aa57_m.jpg?34606",
"icon_l":"http:\/\/img.hipgeo.com\/4d8fafb54101bc1cd31f4f506f31aa57_l.jpg?34606",
"icon_b":"http:\/\/img.hipgeo.com\/4d8fafb54101bc1cd31f4f506f31aa57_b.jpg?34606",
"full":"http:\/\/img.hipgeo.com\/4d8fafb54101bc1cd31f4f506f31aa57_d.jpg?34606",
"height":662,
"width":494
},
{
"id":"m_34608",
"shareable":1,
"type":0,
"when":"2012-03-30 17:21:49",
"icon":"http:\/\/img.hipgeo.com\/4061a0fc4ebfb83ed1e0413f761f4487_m.jpg?34608",
"icon_l":"http:\/\/img.hipgeo.com\/4061a0fc4ebfb83ed1e0413f761f4487_l.jpg?34608",
"icon_b":"http:\/\/img.hipgeo.com\/4061a0fc4ebfb83ed1e0413f761f4487_b.jpg?34608",
"full":"http:\/\/img.hipgeo.com\/4061a0fc4ebfb83ed1e0413f761f4487_d.jpg?34608",
"height":662,
"width":494
},
{
"id":"m_34609",
"shareable":1,
"type":0,
"when":"2012-03-30 17:23:31",
"icon":"http:\/\/img.hipgeo.com\/45baa8e14728b8f8dbed4e3277ca57e8_m.jpg?34609",
"icon_l":"http:\/\/img.hipgeo.com\/45baa8e14728b8f8dbed4e3277ca57e8_l.jpg?34609",
"icon_b":"http:\/\/img.hipgeo.com\/45baa8e14728b8f8dbed4e3277ca57e8_b.jpg?34609",
"full":"http:\/\/img.hipgeo.com\/45baa8e14728b8f8dbed4e3277ca57e8_d.jpg?34609",
"height":662,
"width":494
}
]
}
},
{
"id":"j_134834",
"from":{
"id":"u_111",
"name":"Joe",
"shareable":1,
"pingable":1,
"url":"http:\/\/www.hipgeo.com\/Joe",
"fullname":"Joe Chan",
"avatar":{
"id":"m_11101",
"shareable":0,
"type":0,
"when":"2012-01-06 22:42:29",
"icon":"http:\/\/img.hipgeo.com\/4c0faecc4ffdb3c15ea72a5f0ee8fb58_m?11101",
"icon_l":"http:\/\/img.hipgeo.com\/4c0faecc4ffdb3c15ea72a5f0ee8fb58_l?11101",
"icon_b":"http:\/\/img.hipgeo.com\/4c0faecc4ffdb3c15ea72a5f0ee8fb58_b?11101",
"full":"http:\/\/img.hipgeo.com\/4c0faecc4ffdb3c15ea72a5f0ee8fb58_d?11101",
"height":494,
"width":662
},
"photo":"http:\/\/img.hipgeo.com\/4c0faecc4ffdb3c15ea72a5f0ee8fb58_b?11101"
},
"type":1,
"when":"2012-03-30 17:46:45.684",
"user_when":"2012-03-30 10:46:45.684",
"privacy":3,
"user_modified":0,
"shareable":1,
"liked":0,
"title":"Photo Post",
"content":"",
"message":"",
"commentcount":0,
"likecount":0,
"mediacount":2,
"media":{
"count":2,
"data":[
{
"id":"m_34617",
"shareable":1,
"type":0,
"when":"2012-03-30 17:46:53",
"icon":"http:\/\/img.hipgeo.com\/4848ad444a5abfe4de5049867cc1de89_m.jpg?34617",
"icon_l":"http:\/\/img.hipgeo.com\/4848ad444a5abfe4de5049867cc1de89_l.jpg?34617",
"icon_b":"http:\/\/img.hipgeo.com\/4848ad444a5abfe4de5049867cc1de89_b.jpg?34617",
"full":"http:\/\/img.hipgeo.com\/4848ad444a5abfe4de5049867cc1de89_d.jpg?34617",
"height":662,
"width":494
},
{
"id":"m_34618",
"shareable":1,
"type":0,
"when":"2012-03-30 17:49:51",
"icon":"http:\/\/img.hipgeo.com\/4042a8684ca7bbb4d00442337e31ed07_m.jpg?34618",
"icon_l":"http:\/\/img.hipgeo.com\/4042a8684ca7bbb4d00442337e31ed07_l.jpg?34618",
"icon_b":"http:\/\/img.hipgeo.com\/4042a8684ca7bbb4d00442337e31ed07_b.jpg?34618",
"full":"http:\/\/img.hipgeo.com\/4042a8684ca7bbb4d00442337e31ed07_d.jpg?34618",
"height":662,
"width":494
}
]
}
},
{
"id":"j_134831",
"from":{
"id":"u_111",
"name":"Joe",
"shareable":1,
"pingable":1,
"url":"http:\/\/www.hipgeo.com\/Joe",
"fullname":"Joe Chan",
"avatar":{
"id":"m_11101",
"shareable":0,
"type":0,
"when":"2012-01-06 22:42:29",
"icon":"http:\/\/img.hipgeo.com\/4c0faecc4ffdb3c15ea72a5f0ee8fb58_m?11101",
"icon_l":"http:\/\/img.hipgeo.com\/4c0faecc4ffdb3c15ea72a5f0ee8fb58_l?11101",
"icon_b":"http:\/\/img.hipgeo.com\/4c0faecc4ffdb3c15ea72a5f0ee8fb58_b?11101",
"full":"http:\/\/img.hipgeo.com\/4c0faecc4ffdb3c15ea72a5f0ee8fb58_d?11101",
"height":494,
"width":662
},
"photo":"http:\/\/img.hipgeo.com\/4c0faecc4ffdb3c15ea72a5f0ee8fb58_b?11101"
},
"type":1,
"when":"2012-03-30 17:37:43.605",
"user_when":"2012-03-30 10:37:43.605",
"privacy":3,
"user_modified":0,
"shareable":1,
"liked":0,
"title":"Photo Post",
"content":"",
"message":"",
"commentcount":0,
"likecount":0,
"mediacount":1,
"media":{
"count":1,
"data":[
{
"id":"m_34613",
"shareable":1,
"type":0,
"when":"2012-03-30 17:39:12",
"icon":"http:\/\/img.hipgeo.com\/423ea68c4f8abb17d970441279a01720_m.jpg?34613",
"icon_l":"http:\/\/img.hipgeo.com\/423ea68c4f8abb17d970441279a01720_l.jpg?34613",
"icon_b":"http:\/\/img.hipgeo.com\/423ea68c4f8abb17d970441279a01720_b.jpg?34613",
"full":"http:\/\/img.hipgeo.com\/423ea68c4f8abb17d970441279a01720_d.jpg?34613",
"height":662,
"width":494
}
]
}
},
{
"id":"j_134824",
"from":{
"id":"u_111",
"name":"Joe",
"shareable":1,
"pingable":1,
"url":"http:\/\/www.hipgeo.com\/Joe",
"fullname":"Joe Chan",
"avatar":{
"id":"m_11101",
"shareable":0,
"type":0,
"when":"2012-01-06 22:42:29",
"icon":"http:\/\/img.hipgeo.com\/4c0faecc4ffdb3c15ea72a5f0ee8fb58_m?11101",
"icon_l":"http:\/\/img.hipgeo.com\/4c0faecc4ffdb3c15ea72a5f0ee8fb58_l?11101",
"icon_b":"http:\/\/img.hipgeo.com\/4c0faecc4ffdb3c15ea72a5f0ee8fb58_b?11101",
"full":"http:\/\/img.hipgeo.com\/4c0faecc4ffdb3c15ea72a5f0ee8fb58_d?11101",
"height":494,
"width":662
},
"photo":"http:\/\/img.hipgeo.com\/4c0faecc4ffdb3c15ea72a5f0ee8fb58_b?11101"
},
"type":1,
"when":"2012-03-30 17:26:52.826",
"user_when":"2012-03-30 10:26:52.826",
"privacy":3,
"user_modified":0,
"shareable":1,
"liked":0,
"title":"Photo Post",
"content":"",
"message":"",
"commentcount":0,
"likecount":0,
"mediacount":2,
"media":{
"count":2,
"data":[
{
"id":"m_34610",
"shareable":1,
"type":0,
"when":"2012-03-30 17:26:58",
"icon":"http:\/\/img.hipgeo.com\/4b3fad6e486ebd3adddf4e137f0d66a5_m.jpg?34610",
"icon_l":"http:\/\/img.hipgeo.com\/4b3fad6e486ebd3adddf4e137f0d66a5_l.jpg?34610",
"icon_b":"http:\/\/img.hipgeo.com\/4b3fad6e486ebd3adddf4e137f0d66a5_b.jpg?34610",
"full":"http:\/\/img.hipgeo.com\/4b3fad6e486ebd3adddf4e137f0d66a5_d.jpg?34610",
"height":662,
"width":494
},
{
"id":"m_34611",
"shareable":1,
"type":0,
"when":"2012-03-30 17:30:18",
"icon":"http:\/\/img.hipgeo.com\/47a8aa2b407cbaa8dae942357d337a78_m.jpg?34611",
"icon_l":"http:\/\/img.hipgeo.com\/47a8aa2b407cbaa8dae942357d337a78_l.jpg?34611",
"icon_b":"http:\/\/img.hipgeo.com\/47a8aa2b407cbaa8dae942357d337a78_b.jpg?34611",
"full":"http:\/\/img.hipgeo.com\/47a8aa2b407cbaa8dae942357d337a78_d.jpg?34611",
"height":662,
"width":494
}
]
}
}
],
"result":"success",
"st":1333136222
}
| Error Code |
Possible Errors |
| 400 |
- Limit of [xxxx] is too large. The maximum is [xxxx].
- Limit of 0 is not allowed
- Order must be 'recent' or 'alpha'
- Bad time format: since = [xxxx]
- Bad time format: until = [xxxx]
- Invalid journal type
|
| 401 |
- Authentication failed
- Token expired
- Insufficient Permissions
- 'me' requires authentication
|
| 404 |
- ID not found
- Bad ID
|
| 405 |
- Target is not a user ID
- Must be GET
|
Example2: GET type=user&since=TIMESTAMP&limit=NUMBER_OF_ENTRIES
GET http://api.hipgeo.com/me/journal?type=user&since=2011-01-02T14:01:00.0&limit=10&access_token=TOKENVALUE
Returns:
{
"count":10,
"data":[
{
"id":"j_10477",
"from":{
"id":"u_7777",
"name":"john",
"shareable":1,
"pingable":1,
"fullname":"John Smith",
"photo":"http:\/\/img.hipgeo.com\/410eac7f4f08b1ca5b4739bb4f8c61d3_b?2519"
},
"type":3,
"when":"2011-01-02 05:08:49",
"privacy":7,
"shareable":1,
"travel":{
"id":"t_8978",
"shareable":1,
"canmerge":0,
"uid":"u_1",
"beginname":"Brea, CA",
"endname":"Fullerton, CA",
"duration":14044,
"duration_sec":14044,
"distance":10060.6,
"hidestats":1,
"type":2
},
"commentcount":0,
"mediacount":0
},
{
"id":"j_10476",
"from":{
"id":"u_7777",
"name":"john",
"shareable":1,
"pingable":1,
"fullname":"John Smith",
"photo":"http:\/\/img.hipgeo.com\/410eac7f08b1ca5b4739bb4f8c61d3_b?2519"
},
"type":2,
"when":"2011-01-02 01:14:45",
"privacy":7,
"shareable":1,
"location":{
"id":"l_8977",
"shareable":1,
"canmerge":1,
"title":"Brea, CA",
"duration":512,
"duration_sec":512,
"hidestats":1,
"uid":"u_1",
"type":1,
"coord":{
"lat":33.917999,
"lon":-117.889999,
"radius":0,
"alt":"0"
}
},
"commentcount":0,
"mediacount":0
},
== some items removed ==
{
"id":"j_10469",
"from":{
"id":"u_7777",
"name":"john",
"shareable":1,
"pingable":1,
"fullname":"John Smith",
"photo":"http:\/\/img.hipgeo.com\/410e7f4f08b1ca5b4739bb4f8c61d3_b?2519"
},
"type":3,
"when":"2011-01-01 23:08:27",
"privacy":7,
"shareable":1,
"travel":{
"id":"t_8968",
"shareable":1,
"canmerge":0,
"uid":"u_1",
"beginname":"Fullerton, CA",
"endname":"La Habra, CA",
"duration":418,
"duration_sec":418,
"distance":5476.74,
"hidestats":0,
"type":2
},
"commentcount":0,
"mediacount":0
},
{
"id":"j_10468",
"from":{
"id":"u_7777",
"name":"john",
"shareable":1,
"pingable":1,
"fullname":"John Smith",
"photo":"http:\/\/img.hipgeo.com\/410eac7f4fb1ca5b4739bb4f8c61d3_b?2519"
},
"type":2,
"when":"2011-01-01 23:01:29",
"privacy":7,
"shareable":1,
"location":{
"id":"l_8967",
"shareable":1,
"canmerge":1,
"title":"Fullerton, CA",
"duration":495,
"duration_sec":495,
"hidestats":1,
"uid":"u_1",
"type":1,
"coord":{
"lat":33.8848,
"lon":-117.940002,
"radius":0,
"alt":"0"
}
},
"commentcount":0,
"mediacount":0
}
],
"result":"success"
}
| Error Code |
Possible Errors |
| 400 |
- Limit of [xxxx] is too large. The maximum is [xxxx].
- Limit of 0 is not allowed
- Order must be 'recent' or 'alpha'
- Bad time format: since = [xxxx]
- Bad time format: until = [xxxx]
- Invalid journal type
|
| 401 |
- Authentication failed
- Token expired
- Insufficient Permissions
- 'me' requires authentication
|
| 404 |
- ID not found
- Bad ID
|
| 405 |
- Target is not a user ID
- Must be GET
|
Example3: GET type=trips
GET http://api.hipgeo.com/u_2224/journal?type=trips&limit=3&access_token=TOKENVALUE
Returns:
{
"count":3,
"data":[
{
"id":"j_134791",
"from":{
"id":"u_2224",
"name":"Joe",
"shareable":1,
"pingable":1,
"url":"http:\/\/www.hipgeo.com\/Joe",
"fullname":"Joe Smith",
"avatar":{
"id":"m_11101",
"shareable":0,
"type":0,
"when":"2012-01-06 22:42:29",
"icon":"http:\/\/img.hipgeo.com\/4c0faecc4ffdb3c15ea72a5f0ee8fb58_m?11101",
"icon_l":"http:\/\/img.hipgeo.com\/4c0faecc4ffdb3c15ea72a5f0ee8fb58_l?11101",
"icon_b":"http:\/\/img.hipgeo.com\/4c0faecc4ffdb3c15ea72a5f0ee8fb58_b?11101",
"full":"http:\/\/img.hipgeo.com\/4c0faecc4ffdb3c15ea72a5f0ee8fb58_d?11101",
"height":494,
"width":662
},
"photo":"http:\/\/img.hipgeo.com\/4c0faecc4ffdb3c15ea72a5f0ee8fb58_b?11101",
"friend":3,
"follower":3,
"following":3
},
"type":4,
"when":"2012-03-30 16:34:07.0",
"user_when":"2012-03-30 09:34:07.0",
"privacy":3,
"user_modified":0,
"shareable":1,
"liked":0,
"title":"Ttttttt",
"content":null,
"trip":{
"id":"d_898",
"title":"Ttttttt",
"url":"http:\/\/www.hipgeo.com\/slices\/viewApp\/key\/d_lx099i",
"time_text":"Friday March 30th, 2012 for 1 day",
"description":null,
"start":"2012-03-30 00:00:00",
"duration":86400,
"views":0,
"privacy":3,
"avatar":{
"id":"m_34610",
"shareable":1,
"type":0,
"when":"2012-03-30 17:26:58",
"icon":"http:\/\/img.hipgeo.com\/4b3fad6e486ebd3adddf4e137f0d66a5_m.jpg?34610",
"icon_l":"http:\/\/img.hipgeo.com\/4b3fad6e486ebd3adddf4e137f0d66a5_l.jpg?34610",
"icon_b":"http:\/\/img.hipgeo.com\/4b3fad6e486ebd3adddf4e137f0d66a5_b.jpg?34610",
"full":"http:\/\/img.hipgeo.com\/4b3fad6e486ebd3adddf4e137f0d66a5_d.jpg?34610",
"height":280,
"width":280
}
},
"commentcount":0,
"likecount":0,
"mediacount":0
},
{
"id":"j_133557",
"from":{
"id":"u_2224",
"name":"Joe",
"shareable":1,
"pingable":1,
"url":"http:\/\/www.hipgeo.com\/Joe",
"fullname":"Joe Smith",
"avatar":{
"id":"m_11101",
"shareable":0,
"type":0,
"when":"2012-01-06 22:42:29",
"icon":"http:\/\/img.hipgeo.com\/4c0faecc4ffdb3c15ea72a5f0ee8fb58_m?11101",
"icon_l":"http:\/\/img.hipgeo.com\/4c0faecc4ffdb3c15ea72a5f0ee8fb58_l?11101",
"icon_b":"http:\/\/img.hipgeo.com\/4c0faecc4ffdb3c15ea72a5f0ee8fb58_b?11101",
"full":"http:\/\/img.hipgeo.com\/4c0faecc4ffdb3c15ea72a5f0ee8fb58_d?11101",
"height":494,
"width":662
},
"photo":"http:\/\/img.hipgeo.com\/4c0faecc4ffdb3c15ea72a5f0ee8fb58_b?11101",
"friend":3,
"follower":3,
"following":3
},
"type":4,
"when":"2012-03-27 16:05:48.0",
"user_when":"2012-03-27 09:05:48.0",
"privacy":0,
"user_modified":0,
"shareable":1,
"liked":0,
"title":"Fvhh",
"content":null,
"trip":{
"id":"d_880",
"title":"Fvhh",
"url":"http:\/\/www.hipgeo.com\/slices\/viewApp\/key\/d_ln7air",
"time_text":"Tuesday March 27th, 2012 for 1 day",
"description":null,
"start":"2012-03-27 00:00:00",
"duration":86400,
"views":13,
"privacy":0,
"avatar":{
"id":"m_33997",
"shareable":1,
"type":0,
"when":"2012-03-27 16:06:56",
"icon":"http:\/\/img.hipgeo.com\/4419a9894137bf05d3ff773380b9973d_m.jpg?33997",
"icon_l":"http:\/\/img.hipgeo.com\/4419a9894137bf05d3ff773380b9973d_l.jpg?33997",
"icon_b":"http:\/\/img.hipgeo.com\/4419a9894137bf05d3ff773380b9973d_b.jpg?33997",
"full":"http:\/\/img.hipgeo.com\/4419a9894137bf05d3ff773380b9973d_d.jpg?33997",
"height":280,
"width":280
}
},
"commentcount":0,
"likecount":0,
"mediacount":0
},
{
"id":"j_130883",
"from":{
"id":"u_2224",
"name":"Joe",
"shareable":1,
"pingable":1,
"url":"http:\/\/www.hipgeo.com\/Joe",
"fullname":"Joe Smith",
"avatar":{
"id":"m_11101",
"shareable":0,
"type":0,
"when":"2012-01-06 22:42:29",
"icon":"http:\/\/img.hipgeo.com\/4c0faecc4ffdb3c15ea72a5f0ee8fb58_m?11101",
"icon_l":"http:\/\/img.hipgeo.com\/4c0faecc4ffdb3c15ea72a5f0ee8fb58_l?11101",
"icon_b":"http:\/\/img.hipgeo.com\/4c0faecc4ffdb3c15ea72a5f0ee8fb58_b?11101",
"full":"http:\/\/img.hipgeo.com\/4c0faecc4ffdb3c15ea72a5f0ee8fb58_d?11101",
"height":494,
"width":662
},
"photo":"http:\/\/img.hipgeo.com\/4c0faecc4ffdb3c15ea72a5f0ee8fb58_b?11101",
"friend":3,
"follower":3,
"following":3
},
"type":4,
"when":"2012-03-21 21:46:49.0",
"user_when":"2012-03-21 14:46:49.0",
"privacy":0,
"user_modified":0,
"shareable":1,
"liked":0,
"title":"Testinf",
"content":null,
"trip":{
"id":"d_859",
"title":"Testinf",
"url":"http:\/\/www.hipgeo.com\/slices\/viewApp\/key\/d_5zggu8",
"time_text":"Wednesday March 21st, 2012 for 1 day",
"description":null,
"start":"2012-03-21 00:00:00",
"duration":86400,
"views":11,
"privacy":0,
"avatar":{
"id":"m_0",
"shareable":0,
"type":64,
"when":"2012-04-03 19:26:54",
"icon":"http:\/\/www.hipgeo.com\/images\/trip-blank-medium.jpg",
"icon_l":"http:\/\/www.hipgeo.com\/images\/trip-blank-large.jpg",
"icon_b":"http:\/\/www.hipgeo.com\/images\/trip-blank-small.jpg",
"full":"http:\/\/www.hipgeo.com\/images\/trip-blank-large.jpg",
"height":280,
"width":280
}
},
"commentcount":0,
"likecount":0,
"mediacount":0
}
],
"result":"success",
"st":1333481214
}
| Error Code |
Possible Errors |
| 400 |
- Limit of [xxxx] is too large. The maximum is [xxxx].
- Limit of 0 is not allowed
- Order must be 'recent' or 'alpha'
- Invalid journal type
|
| 401 |
- Authentication failed
- Token expired
- Insufficient Permissions
- 'me' requires authentication
|
| 404 |
- ID not found
- Bad ID
|
| 405 |
- Target is not a user ID
- Must be GET
|
POST
POST operation allows the creation of a journal object. The journal information will be merged to an existing non-user created journal entry if a fit is found, otherwise a new journal entry will be created.
See example below for json data structure. "gll" is optional but "when" is required for the journal attribute and must also be included in the gll data if gll is supplied. Allowable privacy attributes are:
- 0 = Public
- 3 = Private
- 7 = Auto private
Other values will return an error.
A new trip can be created or the journal can be added to an existing trip by including "trips" JSON data. See Method/Description for details.
| Method |
Description |
| /me/journal |
"gll" is optional. "when" is required in journal data and in "gll" if present. If a PLACEID is provided, the location will be pinpointed to the PLACEID. See Example4 below for JSON structure |
| /me/journal |
"trips" is optional and can be included to create or add the journal to an existing trip. The JSON is:
{
"trips":[{"id":"d_7777"}, {"id":"z_scott_1234", "title":"trip title", "description":"this is about my trip"}]
}
where "d_7777" is the id of an existring trip, and "z_scott_1234" is a client provided ID to create a new trip.
Note:
1. Trip creation tripid provided by the client is of the form:
z_USERNAME_UNIQUEID
where UNIQUEID ensures that the value is unique for the user (probably system time).
2. At trip creation, a standard TRIPID of the form d_xxx is created and used to identify the trip in all journal data. The client provided TRIPID can be substituted for the standard TRIPID for the life of the trip when making queries but the client provided TRIPID will not appear in any journal data.
|
Example4: POST me /journal to Create Journal Object
PUT api.hipgeo.com/me/journal?access_token=TOKENVALUE
Data:
{
"title":"a title",
"content":"some content",
"when":"2011-11-12 01:56:27",
"privacy":0,
"pid":"p_1234",
"trips":[{"id":"d_7777"}, {"id":"z_scott_1234", "title":"trip title", "description":"this is about my trip"}],
"gll":{
"lat":33,
"lon":-117,
"alt":500,
"vel":0,
"hacc":100,
"when":"2011-11-12 01:56:27"
}
}
Returns:
{
"id":"j_62784",
"result":"success"
}
| Error Code |
Possible Errors |
| 400 |
- Invalid journal permission
- Unable to parse data
|
| 401 |
- Authentication failed
- Token expired
- Insufficient Permissions
|
| 403 |
- Insufficient permissions
|
| 404 |
- ID not found
- Bad ID
|
PUT (or POST)
PUT operation allows modification of the Journal object "privacy" attribute. Allowable privacy attributes are:
- 0 = Public
- 3 = Private
- 7 = Auto private
Other values will return an error.
The journal can be added to an existing trip or a new trip by including "trips" JSON data. See Method/Description for details.
Note: When “trips” is added to a journal entry, it is all-inclusive. In other words, the journal entry will be added to the trips specified in the list and removed from any not specified in the list.
| Method |
Description |
| /[j_nnnn] |
See Example5 below for JSON structure to modify 'privacy'
"trips" is optional and can be included to create or add the journal to an existing trip. The JSON is:
{
"trips":[{"id":"d_7777"}, {"id":"z_scott_1234", "title":"trip title", "description":"this is about my trip"}]
}
where "d_7777" is the id of an existring trip, and "z_scott_1234" is a client provided ID to create a new trip.
Note:
1. Trip creation tripid provided by the client is of the form:
z_USERNAME_UNIQUEID
where UNIQUEID ensures that the value is unique for the user (probably system time).
2. At trip creation, a standard TRIPID of the form d_xxx is created and used to identify the trip in all journal data. The client provided TRIPID can be substituted for the standard TRIPID for the life of the trip when making queries but the client provided TRIPID will not appear in any journal data.
|
Example5: PUT /JOURNALID with "privacy" and "trips" JSON data
PUT api.hipgeo.com/j_16995?access_token=TOKENVALUE
Data:
{
"privacy":0,
"trips":[{"id":"d_7777"}, {"id":"z_scott_1234", "title":"trip title", "description":"this is about my trip"}]
}
Returns:
{
"id":"j_16995",
"result":"success"
}
| Error Code |
Possible Errors |
| 400 |
- Invalid journal permission
- Unable to parse data
|
| 401 |
- Authentication failed
- Token expired
- Insufficient Permissions
|
| 403 |
- Insufficient permissions
|
| 404 |
- ID not found
- Bad ID
|