Skip to content

Commit 69c8521

Browse files
committed
Update user.md
track user's action
1 parent 4f582c8 commit 69c8521

File tree

1 file changed

+30
-0
lines changed

1 file changed

+30
-0
lines changed

user.md

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -210,3 +210,33 @@ curl -X POST --data "name=hayashi" -H "X-API-KEY: 4974328ce522a3eb86ecf73a193490
210210
"status": 1
211211
}
212212
````
213+
214+
#### <a name="track-user-action"></a> `🔒` `POST` Track User's Action
215+
Track User's Action
216+
217+
##### <a name="track-user-action-url"></a> Resource URL
218+
/api/v2/user/action_track
219+
220+
##### <a name="track-user-action-params"></a> Parameters
221+
222+
json array of [
223+
224+
+ `id` track id, should be globally unique. Can be done using md5(random_string)
225+
+ `resource` e.g : Profile / Feed / Browse.
226+
+ `action` e.g : open / close
227+
+ `time` e.g : 2014-03-10 08:20:10
228+
229+
]
230+
231+
##### <a name="track-user-action-request"></a>Sample Request
232+
````sh
233+
curl -X POST --data "data=[{\"id\": \"jasklfdjs8378329\", \"resource\": \"Profile\", \"action\": \"open\", \"time\": \"2014-03-10 08:20:10\"}]" -H "X-API-KEY: 4974328ce522a3eb86ecf73a193490314cf98c74" http://shoop.dev/api/v2/user/action_track
234+
````
235+
236+
##### <a name="track-user-action-response"></a>Sample Response
237+
238+
````json
239+
{
240+
"status": 1
241+
}
242+
````

0 commit comments

Comments
 (0)