Feed

Get Feed

curl "https://example.ziik.io/api/feed"
  -H "Authorization: Bearer aaaaaaaaaa.bbbbbbbbbbb.cccccccccccc"

The above command returns JSON structured like this:

{
  "hits":
    [{
        "id":123,
        "content_type":"debate",
        "author":{
            "id":234,
            "name":"Test User",
            "avatar": {
                ...
            },
            "userType": {
                "id":11,
                "name":"Worker",
                "url":"api\/v1\/user_types\/11"
            },
            "url":"api\/v1\/users\/234"
        },
        "date":1470129614,
        ...
        "url":"api\/v1\/debates\/123"
      },
      {
        "id":124,
        "content_type":"debate",
        "author":{
            "id":234,
            "name":"Test User",
            "avatar":{
                ...
            },
            "userType":{
                "id":11,
                "name":"Worker",
                "url":"api\/v1\/user_types\/11"
            },
            "url":"api\/v1\/users\/234"
        },
        "date":1465910290,
        ...
        "url":"api\/v1\/debates\/1205"
      }
  ],
  "meta": {
      "pagination": {
          "total": 3,
          "count": 3,
          "per_page": 50,
          "current_page": 1,
          "total_pages": 1,
          "links": []
      }
  }
}

This endpoint retrieves news, events and group debates for the logged in user, ordered by creation time.

The feed is the starting point for the application, giving the user a quick overview of what has happened since last check.

Unlike Facebook, Ziik does not attempt to measure relevance or interest.

TIP

See the respective content type endpoints for more details as to how they are represented

HTTP Request

GET http://example.ziik.io/api/feed

Query Parameters

ParameterTypeDefaultDescription
pageInteger1Page number to retrieve.
limitInteger50How many records to return per page.
typesArray['news', 'debate', 'event']Filter the feed by type.
unpublishedInteger0Show only unpublished content. 1 = unpublished, 0 = published.