Zum Hauptinhalt springen

Documentation

IMPORTANT

This is the outdated SI-documentation which will be adapted soon. A huge part may be obsolete!

Post View

Post View

In this section, we will briefly explain the REST API to view Post View.

This REST API call allows requester to view post which created on the site. To view the post, requester will need to send a GET request to this following url:

http://site.com/index.php?option=com_easydiscuss&view=post&format=json&tmpl=component

GET Parameters

The following are the available parameters when a GET is made to this API call:

  • id (required)
    This id parameter is the post id available on the site.

Response

Upon a successful request, EasyDiscuss system will return a response in a form of JSON to the requester.

The successful request response will looks similar as below:

{
  "post": {
    "id": "25",
    "permalink": "http://easydiscuss.com/index.php?option=com_easydiscuss&view=post&id=25&Itemid=118&format=json",
    "title": "Unable to select tag for multi tag menu item",
    "user_id": "959",
    "hits": "4",
    "vote": "0",
    "state": "1",
    "locked": "0",
    "created": "2016-04-18 08:48:35",
    "modified": "2016-04-19 04:45:01",
    "content": "Unable to select tag for multi tag menu item",
    "preview": "Unable to select tag for multi tag menu item",
    "replies": [
      {
        "id": "29",
        "permalink": "http://easydiscuss.com/index.php?option=com_easydiscuss&view=post&id=25&Itemid=118#reply-29&format=json",
        "title": null,
        "user_id": "965",
        "hits": "0",
        "vote": "0",
        "state": "1",
        "locked": "0",
        "created": "2016-04-19 05:09:33",
        "modified": "2016-04-19 05:09:33",
        "content": "http://screencast.com/t/pPXrXtT1",
        "preview": "<a href=\"http://screencast.com/t/ppxrxtt1\" >http://screencast.com/t/ppxrxtt1</a>",
        "replies": [],
        "comments": []
      }
    ],
    "comments": []
  }
}

And a fail request response will looks similar as below:

{
    "code": 404,
    "message": "Sorry, but the post that you are trying to access is not available."
}
Wir benutzen Cookies
Wir nutzen Cookies auf unserer Website. Einige von ihnen sind essenziell für den Betrieb der Seite, während andere uns helfen, diese Website und die Nutzererfahrung zu verbessern. Du kannst selbst enscheiden, ob du Cookies zulassen möchtest. Bitte beachte, dass bei Ablehnung womöglich nicht mehr alle Funktionalitäten zur Verfügung stehen.