To access to end-points access logs go to menu Components > jBackend > Logs. A list of traced requests will be shown:
Each logged request has the following information:
Field: | Description: |
---|---|
Endpoint | The ID of the end-point that has received the request |
Access type | The type of access used on the end-point (free, user, API key) |
Request time | The date and time of the request |
Duration | Time required to serve the request (in seconds) |
Error code | The error code in case of request error |
User ID | The ID of the user when available |
Key | The API key used when available |
Action | The action of the request |
Module | The module of the request |
Resource | The resource of the request |
It is possible to enable log trace for each end-point from the menu item options:
To manage API Keys used to grant access to end-points go to menu Components > jBackend > Keys. A list of jBackend Keys will be shown:
Each key has the following properties:
Field: | Description: |
---|---|
Key | The enabling key |
User | The user associated to this key (to restrict access with key and to a single user) |
Enabled endpoints | If this key is enable on ALL endpoints or ONLY on selected endpoints |
Selected endpoints | The endpoints for which the key is enabled, when not enabled for ALL |
Enabled on default | If the key should also work on the default requests (i.e. /index.php?option=com_jbackend&view=request&...) |
Daily requests | Maximum number of daily requests allowed for the key (0 means unlimited) |
Expiration date | Key expiration date (0000-00-00 00:00:00 means never expires) |
Comment | Just a reminder for the key |
For each key the following statistics fields are available:
Field: | Description: |
---|---|
Hits | Number of times the key was used |
Last visit | Last time the key was used |
Current day | Current day for daily requests limit |
Current hits | Hits of current day for daily requests limit |
The API key, when required by the endpoint, must be included in any request using one of the following methods:
The SobiPro Module is implemented with the plg_jbackend_sobipro plugin. It provides functions related to SobiPro directory extension (sections, categories and entries). Here is the list of supported methods.
action=get module=sobipro resource=sections
<end-point>?action=get&module=sobipro&resource=sections
<end-point>/get/sobipro/sections
{ "status": "ok", "total": <T>, "sections": [ { "id": "<section id>", "nid": "<section nid>", "name": "<section name>" }, ... { "id": "<section id>", "nid": "<section nid>", "name": "<section name>" } ]}
action=get module=sobipro resource=sections id=<N>
<end-point>?action=get&module=sobipro&resource=sections&id=<N>
<end-point>/get/sobipro/sections/<N>
{ "status": "ok", "id": "<section id>", "nid": "<section nid>", "name": "<section name>", "description": "<section description>", "owner": "<section owner id>", "counter": "<counter>", "createdTime": "<created time>", "updatedTime": "<updated time>", "metaDesc": "<meta description>", "metaKeys": "<meta keywords>", "metaAuthor": "<meta author>", "metaRobots": "<meta robots>", "version": "<version number>" }
Created and updated date format is YYYY-MM-DD HH:MM:SS
action=get module=sobipro resource=categories parent=<N>
<end-point>?action=get&module=sobipro&resource=categories&parent=<N>
<end-point>/get/sobipro/categories?parent=<N>
{ "status": "ok", "total": <T>, "categories": [ { "id": "<category id>", "nid": "<category nid>", "name": "<category name>", "owner": "<owner id>", "counter": "<counter>", "createdTime": "<created time>", "updatedTime": "<updated time>", "metaDesc": "<meta description>", "metaKeys": "<meta keywords>", "metaAuthor": "<meta author>", "metaRobots": "<meta robots>", "version": "<version number>" }, ... { "id": "<category id>", "nid": "<category nid>", "name": "<category name>", "owner": "<owner id>", "counter": "<counter>", "createdTime": "<created time>", "updatedTime": "<updated time>", "metaDesc": "<meta description>", "metaKeys": "<meta keywords>", "metaAuthor": "<meta author>", "metaRobots": "<meta robots>", "version": "<version number>" } ]}
Created and updated date format is YYYY-MM-DD HH:MM:SS
action=get module=sobipro resource=categories id=<N>
<end-point>?action=get&module=sobipro&resource=categories&id=<N>
<end-point>/get/sobipro/categories/<N>
{ "status": "ok", "id": "<category id>", "nid": "<category nid>", "name": "<category name>", "description": "<category description>", "owner": "<category owner id>", "counter": "<counter>", "createdTime": "<created time>", "updatedTime": "<updated time>", "metaDesc": "<meta description>", "metaKeys": "<meta keywords>", "metaAuthor": "<meta author>", "metaRobots": "<meta robots>", "version": "<version number>", "parent": "<parent id>" }
Created and updated date format is YYYY-MM-DD HH:MM:SS
action=get module=sobipro resource=entries category=<C>
<end-point>?action=get&module=sobipro&resource=entries&category=<C>
<end-point>/get/sobipro/entries?category=<C>
{ "status": "ok", "total": <T>, "entries": [ { "id": "<entry id>", "nid": "<entry nid>", "name": "<entry name>", "owner": "<owner id>", "counter": "<counter>", "createdTime": "<created time>", "updatedTime": "<updated time>", "metaDesc": "<meta description>", "metaKeys": "<meta keywords>", "metaAuthor": "<meta author>", "metaRobots": "<meta robots>", "version": "<version number>" }, ... { "id": "<entry id>", "nid": "<entry nid>", "name": "<entry name>", "owner": "<owner id>", "counter": "<counter>", "createdTime": "<created time>", "updatedTime": "<updated time>", "metaDesc": "<meta description>", "metaKeys": "<meta keywords>", "metaAuthor": "<meta author>", "metaRobots": "<meta robots>", "version": "<version number>" } ]}
Created and updated date format is YYYY-MM-DD HH:MM:SS
action=get module=sobipro resource=entries id=<N>
<end-point>?action=get&module=sobipro&resource=entries&id=<N>
<end-point>/get/sobipro/entries/<N>
{ "status": "ok", "id": "<entry id>", "nid": "<entry nid>", "name": "<entry name>", "owner": "<entry owner id>", "section": "<entry section id>", "counter": "<counter>", "createdTime": "<created time>", "updatedTime": "<updated time>", "metaDesc": "<meta description>", "metaKeys": "<meta keywords>", "metaAuthor": "<meta author>", "metaRobots": "<meta robots>", "version": "<version number>", "fields": [ { "name": "<field name>", "fid": "<field id>", "nid": "<field nid>", "sid": "<field sid>", "section": "<section id>", "lang": "<language code>", "_data": "<field data>", "_rawData": "<field raw data>", "fieldType": "<field type>", "isFree": "<is free>", "position": "<position>" }, ... { "name": "<field name>", "fid": "<field id>", "nid": "<field nid>", "sid": "<field sid>", "section": "<section id>", "lang": "<language code>", "_data": "<field data>", "_rawData": "<field raw data>", "fieldType": "<field type>", "isFree": "<is free>", "position": "<position>" } ]}
Created and updated date format is YYYY-MM-DD HH:MM:SS
The following options are available for user plugin:
Option | Description |
JSON Entries | Enable JSON payload on entries action. |
The K2 Module is implemented with the plg_jbackend_k2 plugin. It provides functions related to K2 content construction kit for Joomla (items and categories). Here is the list of supported methods.
action=get module=k2 resource=categories rootid=<R> (optional) endlevel=<E> (optional)
<end-point>?action=get&module=k2&resource=categories&rootid=<R>&endlevel=<E>
<end-point>/get/k2/categories?rootid=<R>
{ "status": "ok", "total": <T>, "categories": [ { "id": "<category id>", "name": "<category name>", "alias": "<category alias>", "description": "<category description>", "parent": "<parent category id>" }, ... { "id": "<category id>", "name": "<category name>", "alias": "<category alias>", "description": "<category description>", "parent": "<parent category id>" } ] }
If rootid is specified, starts to get subcategories from the specified category id instead of the root category. If endlevel is specified, get categories and all subcategories up to the specified number of level, otherwise get all levels (default).
action=get module=k2 resource=categories id=<N>
<end-point>?action=get&module=k2&resource=categories&id=<N>
<end-point>/get/k2/categories/<N>
{ "status": "ok", "id": "<category id>", "name": "<category name>", "alias": "<category alias>", "description": "<category description>", "robots": "<meta robots>", "author": "<meta author>", "language": "<language code>", "parent": "<category id>" }
Language can be "*" if any.
action=get module=k2 resource=items cats=<C1,C2,...,CN> (optional) subs=<0|1> (optional) featured=<0|1|2> (optional) limit=<L> (optional) page=<P> (optional) ordering=<field> (optional)
<end-point>?action=get&module=k2&resource=items&cats=<C>&subs=1
<end-point>/get/k2/items?cats=<C>&limit=<L>&page=<P>
{ "status": "ok", "total": "<total items>", "limit": <pagination limit>, "offset": <pagination offset>, items: [ { "id": "<item id>", "title": "<item title>", "alias": "<item alias>", "content": "<item content>", "featured": "<featured>", "images": { "image": "<image URL>", "imageWidth": "<image width>", "image_caption": "<image caption>", "image_credits": "<image credits>", "imageXSmall": "<image extra small URL>", "imageSmall": "<image small URL>", "imageMedium": "<image medium URL>", "imageLarge": "<image large URL>", "imageXLarge": "<image extra large URL>" }, "video": { "video": "<video URL>", "video_caption": "<video caption>", "video_credits": "<video credits>" }, "language": "<item language>", "category_id": "<category id>", "category_name": "<category name>", "author": "<item author>", "created": "<item creation date>", "modified": "<item modification date>" }, ... { ... } ] }
Cats:
List of categories id to include
Subs:
0=Do not include sub categories (default), 1=Include sub categories
Featured:
0=Hide, 1=Show (default), 2=Show only featured items
Ordering:
date, rdate, alpha, ralpha, order, rorder, featured, hits, rand, best, modified, publishUp, id (default)
Created and modified date format is YYYY-MM-DD HH:MM:SS
action=get module=k2 resource=items id=<N>
<end-point>?action=get&module=k2&resource=items&id=<N>
<end-point>/get/k2/items/<N>
{ "status": "ok", "id": "<item id>", "title": "<item title>", "alias": "<item alias>", "content": "<item content>", "featured": "<featured>", "images": { "image": "<image URL>", "imageWidth": "<image width>", "image_caption": "<image caption>", "image_credits": "<image credits>", "imageXSmall": "<image extra small URL>", "imageSmall": "<image small URL>", "imageMedium": "<image medium URL>", "imageLarge": "<image large URL>", "imageXLarge": "<image extra large URL>" }, "video": { "video": "<video URL>", "video_caption": "<video caption>", "video_credits": "<video credits>" }, "metadesc": "<meta description>", "metakey": "<meta keywords>", "metadata": { "robots": "<meta robots>", "author": "<meta author>", "rights": "<meta content rights>", "xreference": "<meta external reference>" }, "language": "<language code>", "category_id": "<category id>", "category_name": "<category name>", "author": "<item author>", "created": "<item creation date>", "modified": "<item modification date>" }
Created and modified date format is YYYY-MM-DD HH:MM:SS
Language can be "*" if any.
The following options are available for user plugin:
Option | Description |
Full image URL | Generate absolute URL (i.e. with domain) for images fields. |
Full video URL | Generate absolute URL (i.e. with domain) for video fields. |
Full img tag URL | Force absolute URL (i.e. with domain) in any HTML img tag. |
Content in items | Include or exclude full content in the items response. |
jBackend provides a robust and extensible solution to expose content and services through a Joomla website. The component provides the basic structure that has in charge of managing requests, controlling accesses, and dispatching incoming requests to the corresponding module. The jBackend architecture is extensible because its service modules are implemented as Joomla plugins, so adding new plugins allows to add new services and expose the contents of new extensions.
In this section we will describe how to create custom modules, and what is the structure of a jBackend plugin. For this purpose it was created an "Hello World" plugin available for download here:
http://www.selfget.com/downloads/file/31-plg-jbackend-helloworld-j30.html
Each HTTP request to an jBackend endpoint MUST include at least three parameters:
action=<action_type> module=<module_name> resource=<service_request>
The action would specify one of the HTTP methods used in a RESTful service (e.g. GET, PUT, POST, or DELETE). This is because all Joomla requests are made using GET, so this FIRST parameter introduces the missing information.
The module parameter indicates the name of the module that has in charge of managing this request (e.g. content). This can be implemented as a single jBackend plugin, or even a pool of plugins where each one implements a subset of module services. As example, for com_content core extension a content plugin already exists, which provides read-only access to content and categories. It could be possible to create a new plugin (e.g. plg_jbackend_content_admin) registered also as content module, which takes in charge editor functions like create content and categories.
The resource parameter specifies the service we are requesting to the module (e.g. articles of the content module, login service of the user module, etc.). This parameter must be validated and managed by the plugin itself, no checks will be made on this by jBackend (it cannot know about services provided by each plugin).
Considering all the required parameters (action, module, and resource), each request has this structure:
<end-point>?action=<action_type>&module=<module_name>&resource=<service_request>
If Joomla SEF is enabled, the request can assume this REST-like structure:
<end-point>/<action_type>/<module_name>/<service_request>
A request can also take additional parameters needed by the resource itself for the required service (e.g. the id of the article). This parameters can be added as a standard URL query string, so the request structure assumes this aspect:
<end-point>?action=<action_type>&module=<module_name>&resource=<service_request>&var1=<value1>&...&varN=<valueN>
Or can be (when SEF is enabled):
<end-point>/<action_type>/<module_name>/<service_request>?var1=<value1>&...&varN=<valueN>
An event onBeforeCheckModule is triggered just before to check the module name to dispatch. This permits to override the module variable (as well as action and resource variables) before the request dispatching process and can be useful, as example, when a plugin must deal with existing client requests that cannot be customized as required by jBackend.
Using onBeforeCheckModule it is possible, as example, to match a request like the following:
<endpoint>?var=catchme
This request doesn't include any of the required variables (action, module, resource), but we can "catch" the var and set the required variables:
public function onBeforeCheckModule() { $app = JFactory::getApplication(); $var = $app->input->getString('var'); if ($var === 'catchme') { $app->input->set('action', 'get'); $app->input->set('module', 'content'); $app->input->set('resource', 'articles'); $app->input->set('catid', '64'); $app->input->set('id', '71'); } }
As a standard Joomla plugin, any jBackend plugin needs an XML installation file with the following structure:
<?xml version="1.0" encoding="utf-8"?> <extension version="3.0" type="plugin" group="jbackend" method="upgrade"> <name>plg_jbackend_helloworld</name> ... </extension>
The plugin group must be "jbackend". All other XML elements are the same of a standard Joomla plugin. The PHP plugin code should have a generateError() function which builds and return all plugin specific errors:
/** * This is the function to generate plugin specific errors * The error response is an array with the following structure: * array( * 'status' => 'ko', * 'error_code' => $errorCode, * 'error_description' => <short error description> * ) * * @param string $errorCode The error code to generate * * @return array The response of type error to return */ public static function generateError($errorCode) { $error = array(); $error['status'] = 'ko'; switch($errorCode) { case 'REQ_ANS': $error['error_code'] = 'REQ_ANS'; $error['error_description'] = 'Action not specified'; break; case 'HWD_GEN': $error['error_code'] = 'HWD_GEN'; $error['error_description'] = 'Generic hello world error'; break; } return $error; }
It is not mandatory, but a good practice for the format of the error code is to use a pattern like XXX_YYY, where XXX is a code associated to the plugin (e.g. HWD for the helloworld plugin), and YYY for the specific error (e.g. GEN for generic error).
The other function that any jBackend plugin should have is the onRequest<Module>() function. This is called by jBackend during requests dispatching process. It has three parameters, an input parameter $module that is the module name and is used by the plugin to understand if it should handle the request, an output parameter $response that is the response object, and a $status parameter that can return additional information. The function returns true if there are no problems (status = ok), false in case of errors (status = ko):
public function onRequestHelloWorld($module, &$response, &$status = null)
The first thing the onRequest function should do is to check if it must handle the request or not. If not, it should return to improve the performance of the dispatching process:
if ($module !== 'helloworld') return true; // Check if this is the triggered module or exit
The second thing is to add the plugin to the module call stack:
// Add to module call stack jBackendHelper::moduleStack($status, 'helloworld'); // Add this request to the module stack register
After these tasks, it is possible to get request vars and process the response:
$app = JFactory::getApplication(); $action = $app->input->getString('action'); $resource = $app->input->getString('resource'); // Check if the action is specified if (is_null($action)) { $response = plgJBackendHelloWorld::generateError('REQ_ANS'); // Action not specified return false; } switch ($resource) { case 'greeting': if ($action == 'get') { return $this->actionGreeting($response, $status); } break; case 'about': if ($action == 'get') { return $this->actionAbout($response, $status); } break; } return true;
Each function like actionGreeting() and actionAbout() is specific to manage the resource requested by the action. To maintain the code clean it is a good practice to create a different function for each action.
The following is an example of an action() function that shows the code structure and how to manage the errors:
public function actionGreeting(&$response, &$status = null) { $app = JFactory::getApplication(); // Get additional request parameters $id = $app->input->getInt('id'); if (!is_null($id)) { // Example of how to generate and return an error inside an action function if ($id == '101') { $response = plgJBackendHelloWorld::generateError('HWD_GEN'); // Generic hello world error return false; } } // Get plugin params $option_name = $this->params->get('option_name', 0); $response['status'] = 'ok'; $response['message'] = $this->_greeting_msg; if ($option_name) { $response['option'] = 'true'; } return true; }
The first thing to do is to enable Tag Meta plugin. To enable the plugin go to menu "Extensions" -> "Plug-in Manager", find a system type plugin named "System - Tag Meta Community" or "System - Tag Meta Enterprise" in the plugin list, and click on it to access to plugin settings. Set "Status" to “Enabled”, and set other parameters on the right side according to your needs. Look at "Plugin settings" paragraph for detailed information about each parameter. Click on "Save & Close" button and check that the plugin is now enabled.
Remember that is the plugin that "does the work". The Tag Meta component is just the administrative interface for managing meta rules an other features, but is the plugin that checks site requests and performs meta enhancement when needed. So, the very first thing to do is to enable the plugin. Note that if you need to disable Tag Meta, just disable the plugin.
Another thing to check is the plugins order that can be very important, especially if there are some other plugins that mess with page's meta information. In most cases it is better to set Tag Meta as the last system plugin, so it will be the last to be executed and to madofy page content. Now Tag Meta is ready to work! You can now create your first meta rule, and test the result through the web browser. Be careful that you could get a cached page. To avoid this just clear server-side cache from backend (menu "Maintenance" -> "Clean Cache"), and client-side cache from your web browser.
The Content Module is implemented with the plg_jbackend_content plugin. It provides functions related to Joomla content (articles and categories). Here is the list of supported methods.
action=get module=content resource=categories rootid=<R> (optional) recursive=<true or 1> (optional) countitems=<true or 1> (optional)
<end-point>?action=get&module=content&resource=categories&rootid=<R>&recursive=<false>&countitems=<0>
<end-point>/get/content/categories?rootid=<R>
{ "status": "ok", "total": <T>, "categories": [ { "id": "<category id>", "title": "<category title>", "description": "<category description>", "parent_id": "<parent category id>", "numitems": <items count> }, ... { "id": "<category id>", "title": "<category title>", "description": "<category description>", "parent_id": "<parent category id>", "numitems": <items count> } ] }
If rootid is specified, starts to get subcategories from the specified category id instead of the root category. If recursive is true or 1, get categories and all subcategories, otherwise get only one level (default). If countitems is true or 1, return the number of articles of each category, otherwise do not return this information (default). Category id can be "root" for root node.
action=get module=content resource=categories id=<N>
<end-point>?action=get&module=content&resource=categories&id=<N>
<end-point>/get/content/categories/<N>
{ "status": "ok", "id": "<category id>", "title": "<category title>", "alias": "<category alias>", "description": "<category description>", "metadesc": "<meta description>", "metakey": "<meta keywords>", "metadata": { "page_title": "<meta title>", "author": "<meta author>", "robots": "<meta robots>" }, "language": "<language code>", "parent_id": "<category id>", "level": "<category level>", "numitems": "<N>" }
Language can be "*" if any. Category id can be "root" for root node.
action=get module=content resource=articles catid=<C> (optional) maxsubs=<S> (optional) featured=<F> (optional) limit=<L> (optional) offset=<O> (optional) orderby=<field> (optional) orderdir=<dir> (optional)
<end-point>?action=get&module=content&resource=articles&catid=<C>&maxsubs=<S>&featured=<F>&orderby=<id>
<end-point>/get/content/articles?catid=<C>&limit=<L>&offset=<O>
{ "status": "ok", "total": <total articles>, "limit": <pagination limit>, "offset": <pagination offset>, "pages_current": <current page>, "pages_total": <total pages>, "articles": [ { "id": "<article id>", "title": "<article title>", "alias": "<article alias>", "featured": "<featured>", "content": "<article content>", "catid": "<article category id>", "images": { "image_intro": "<image_url_for_intro>", "float_intro": "<float_side_for_intro>", "image_intro_alt": "<alt_text_for_intro>", "image_intro_caption": "<caption_for_intro>", "image_fulltext": "<image_url_for_fulltext>", "float_fulltext": "<float_side_for_fulltext>", "image_fulltext_alt": "<alt_text_for_fulltext>", "image_fulltext_caption": "<caption_for_fulltext>" }, "tags": [ { "id": "<tag id>", "title": "<tag title>", "alias": "<tag alias>", "language": "<tag language>" }, ... ], "fields": [ { "id": "<field id>", "title": "<field title>", "name": "<field name>", "type": "<field type>", "default_value": "<default value>", "group_id": "<field group id>", "label": "<field label>", "description": "<field description>", "required": "<field required>", "value": "<field value>", "rawvalue": "<field raw value>" }, ... ], "metakey": "<meta keywords>", "metadesc": "<meta description>", "metadata": { "robots": "<meta robots>", "author": "<meta author>", "rights": "<meta content rights>", "xreference": "<meta external reference>" }, "language": "<language code>", "category_title": "<category title>", "category_alias": "<category alias>", "author": "<article author>", "created_date": "<created date>", "modified_date": "<modified date>", "published_date": "<publish up date>", "unpublished_date": "<publish down date>", "state": "<article state>" }, ... { ... } ] }
State:
Max subs:
Number of subcategories to include (default 0=none)
Featured:
hide,only,show (default)
Order by:
id, title, alias, catid, state, created, created_by, ordering (default), hits
Order dir:
asc (default), desc
Dates are in ISO 8601 format (e.g 2017-05-11T10:16:32+00:00)
Property content is present only if plugin's option Content in article list is set.
Property tags is present only if plugin's option Add tags in article list is set.
Property fields is present only if plugin's option Prepare content in article list is set.
action=get module=content resource=articles id=<N>
<end-point>?action=get&module=content&resource=articles&id=<N>
<end-point>/get/content/articles/<N>
{ "status": "ok", "id": "<article id>", "title": "<article title>", "alias": "<article alias>", "featured": "<featured>", "introtext": "<article intro text>", "content": "<article content>", "content_raw": "<article content raw>", "catid": "<article category id>", "images": { "image_intro": "<image_url_for_intro>", "float_intro": "<float_side_for_intro>", "image_intro_alt": "<alt_text_for_intro>", "image_intro_caption": "<caption_for_intro>", "image_fulltext": "<image_url_for_fulltext>", "float_fulltext": "<float_side_for_fulltext>", "image_fulltext_alt": "<alt_text_for_fulltext>", "image_fulltext_caption": "<caption_for_fulltext>" }, "tags": [ { "id": "<tag id>", "title": "<tag title>", "alias": "<tag alias>", "language": "<tag language>" }, ... ], "associations": [ ], "event": { "afterDisplayTitle": "<after display title>", "beforeDisplayContent": "<before display content>", "afterDisplayContent": "<after display content>" }, "fields": [ { "id": "<field id>", "title": "<field title>", "name": "<field name>", "type": "<field type>", "default_value": "<default value>", "group_id": "<field group id>", "label": "<field label>", "description": "<field description>", "required": "<field required>", "value": "<field value>", "rawvalue": "<field raw value>" }, ... ], "cck_fields": [ ], "metakey": "<meta keywords>", "metadesc": "<meta description>", "metadata": { "robots": "<meta robots>", "author": "<meta author>", "rights": "<meta content rights>", "xreference": "<meta external reference>" }, "language": "<language code>", "category_title": "<category title>", "category_alias": "<category alias>", "author": "<article author>", "parent_id": "<parent id>", "parent_title": "<parent title>", "parent_alias": "<parent alias>", "parent_route": "<parent route>", "created_date": "<created date>", "modified_date": "<modified date>", "published_date": "<publish up date>", "unpublished_date": "<publish down date>", "version": "<article version>", "hits": "<article hits>", "rating": "<article rating>", "rating_count": "<article rating count>", "state": "<article state>" }
State:
Dates are in ISO 8601 format (e.g 2017-05-11T10:16:32+00:00)
Language can be "*" if any.
Property content_raw is present only if plugin's option Include content raw is set.
Property event is present only if plugin's option Show article event is set.
Property cck_fields is present only if plugin's option Include CCK is set.
action=get module=content resource=tagarticles tagid=<T1,T2,...,Tn> limit=<L> (optional) offset=<O> (optional)
<end-point>?action=get&module=content&resource=tagarticles&tagid=<T>&limit=<L>&offset=<O>
<end-point>/get/content/tagarticles?tagid=<T>&limit=<L>&offset=<O>
{ "status": "ok", "total": <total articles>, "limit": <pagination limit>, "offset": <pagination offset>, "pages_current": <current page>, "pages_total": <total pages>, articles: [ { "id": "<article id>", "title": "<article title>", "alias": "<article alias>", "featured": "<featured>", "content": "<article content>", "images": { "image_intro": "<image_url_for_intro>", "float_intro": "<float_side_for_intro>", "image_intro_alt": "<alt_text_for_intro>", "image_intro_caption": "<caption_for_intro>", "image_fulltext": "<image_url_for_fulltext>", "float_fulltext": "<float_side_for_fulltext>", "image_fulltext_alt": "<alt_text_for_fulltext>", "image_fulltext_caption": "<caption_for_fulltext>" }, "tags": [ { "id": "<tag id>", "title": "<tag title>", "alias": "<tag alias>", "language": "<tag language>" }, ... ], "metadesc": "<meta description>", "metakey": "<meta keywords>", "metadata": { "robots": "<meta robots>", "author": "<meta author>", "rights": "<meta content rights>", "xreference": "<meta external reference>" }, "category_title": "<category title>", "author": "<article author>", "published_date": "<article date>" }, ... { ... } ] }
Dates are in ISO 8601 format (e.g 2017-05-11T10:16:32+00:00)
action=get module=content resource=articlebyalias id=<alias>
<end-point>?action=get&module=content&resource=articlebyalias&id=<alias>
<end-point>/get/content/articlebyalias/<alias>
Same response as "Get an article"
Same notes as "Get an article".
The following options are available for user plugin:
Option | Description |
Filter language | Filter content by language. |
Status | Filter content by state. |
Access archived articles | Allow get article on archived items. |
Grant access | Skip access permissions check and allow access to articles. |
Full image URL | Generate absolute URL (i.e. with domain) for images fields. |
Force full image URL in content | Try to replace relative image URL in content with absolute URL. |
Add tags in article list | Include article tags in the list of articles. |
Prepare content in article list | Call onContent events on each article in the list of articles. |
Content in article list | Include full content in the list of articles. |
Show article event | Include results of events in the article response. |
Include content raw | Include raw content (no content plugin) in the article response. |
Include CCK | Include SEBLOD CCK custom fields in the article response. |