GET :version/annotations
Returns a list of annotation objects by created date
A request requires a date range that can be supplied by using created_date_from
and created_date_to
.
Query parameters
Name | Description | Values | Required |
---|---|---|---|
created_date_from | Annotations that were created on and after this date | ISO datetime | True |
created_date_to | Annotations that were created before this date | ISO datetime | True |
page_size | Number of results to return | integer | False |
Annotations created between 10:00 8th of March to 11:00 8th of March
"https://ca-eu.conversocial.com/api/1/annotations?created_date_from=2016-03-08T10:00:00&created_date_to=2016-05-01&page_size=1"
{
"annotations": [
{
"action": "add_annotation",
"author": {
"author_ids": [
"t:506612322"
],
"customer_profiles_id": "56ced63f9bd56c4c0d321a82"
},
"created_date": "2016-03-08T10:37:58.613000",
"id": "56deab869bd56c25017bab44",
"text": "09287123123",
"type_id": "564b5d709bd56c14074805ed",
"user": 16
}
],
"paging": {
"next_page": "https://ca-eu.conversocial.com/api/1/annotations?created_date_from=2016-03-08T10:00:00&created_date_to=2016-05-01&page_size=1& page_token=564b5d709bd56c14074805ed"
},
}
Annotations created on the 1st of March
"https://ca-eu.conversocial.com/api/1/annotations?created_date_from=2016-03-01&created_date_to=2016-03-01"
Annotations created on the 1st of March, returning only 10 results
"https://ca-eu.conversocial.com/api/1/annotations?created_date_from=2016-03-01&created_date_to=2016-03-01&page_size=10"
Examples
# python
import requests
base_url = "https://ca-eu.conversocial.com/api"
response = requests.get(
"https://ca-eu.conversocial.com/api/1/annotations?created_date_from=2016-03-01T14:00:00&created_date_to=2016-03-01T18:00:00",
auth=("iamausername", "iampassword"))
print response.status_code
> 200
# bash
curl -u "iamausername:iamapassword"
"https://ca-eu.conversocial.com/api/1/annotations?created_date_from=2016-03-01T14:00:00&created_date_to=2016-03-01T18:00:00"