Aggiefeed REST API GET api_v1_activity
Aggiefeed REST API: GET /api/v1/activity
Headers:
Headers | Comments |
---|---|
Authorization: ApiKey <api key> | Requires API KEY |
Query String Parameters:
Parameter | Name | Required (R) | Format | Min / Max Value | Comments | Example |
---|---|---|---|---|---|---|
s | Skip | R | number | min: 0 | Used for result pagination | s=10 |
l | Limit | R | number | min: 0 | Used for result pagination | l=100 |
u | User ID | O | string | N/A | Retrieve activities for a specific user and the groups he/she is associated with | u=userId |
t | Activity Type | O | string | N/A | Specify one or more activity types | t=notification |
m | Activity Label | O | string | N/A | Specify one or more activity labels
| m=~academic |
o | Activity Source Origin | O | string | N/A | Specify one or more activity sources | o=mondavi-rss o=mondavi-rss&o=athletics-rss |
sd | Activity Start Date | O | ISO-8601 Date | N/A | Specify the activities start date (In Zulu Time) | sd=2013-06-27T22:00:00.000Z |
ed | Activity End Date | O | ISO-8601 Date | N/A | Specify the activities end date (In Zulu Time) | ed=2013-06-28T22:00:00.000Z |
How to Use Query String Parameters:
- Specifying multiple Query String Parameters of the same type will match any (OR)
- Specifying multiple Query String Parameters of different types will narrow the result like an (AND)
e.g. 1:
t=notification&m=~campus-life&m=~academic
t=notification AND ( m=~campus-life OR m=~academic )
e.g. 2:
u=userId&t=notification&t=news&m=~campus-life&m=~academic
u=userId AND ( t=notification OR t=news ) AND ( m=~campus-life OR m=~academic)
e.g. 3:
u=userId&t=news&m=~campus-life&m=~academic&sd=2013-06-28T22:00:00.000Z
u=userId AND t=news AND ( m=~campus-life OR m=~academic ) AND sd=2013-06-28T22:00:00.000Z
e.g. 4:
u=userId&t=news&m=~campus-life&m=~academic&sd=2013-06-28T22:00:00.000Z&ed=2013-07-05T06:00:00.000Z
u=userId AND t=news AND ( m=~campus-life OR m=~academic ) AND sd=2013-06-28T22:00:00.000Z AND ed=2013-07-05T06:00:00.000Z
Testing using "curl":
curl -H "Authorization: ApiKey <api kei>" -i -X GET -G -d 's=0&l=100&u=userId&t=notification&m=~campus-life&m=~academic&sd=2013-06-28T22:00:00.000Z&ed=2013-07-05T06:00:00.000Z' "https://aggiefeed-test.ucdavis.edu/api/v1/activity"