XWiki Integration


About this integration
SAS_IntegrationRESTIntroduction_OnlyEN

You can integrate third-party systems with Product name - ev sas.png in many ways. The method you select will depend on business requirements, architectural and security constraints as well as the characteristics specific to each third-party application or service. You can use the REST, CSV, Online CSV data sources as well as the HTML Script widget.

This document describes a standard integration process with the REST data source that has already been implemented in a customer context. It provides only a few examples of HTTP queries for manipulating resources (i.e. endpoints) using the REST API in the third-party application. You can discover more about the possibilities of this API and consult the relevant documentation on the website of the third-party software company.

To find out more about this integration, please contact the Logo - EasyVista.png Consulting & Professional Services team, the Logo - EasyVista.png Support team, or your service provider and integrator.

Integration Summary

This integration is used to retrieve all available information from your XWiki domain using the XWiki REST API (GET method).

     Example documentation icon EN.png  Retrieve and display in an Product name - ev sas.png app a list of all wiki pages (including their name and URI) in a particular space of a particular wiki or from all spaces or wikis answering certain criteria (pages containing specific keywords, etc.)

Integration Data Feed (direction) Authentication Type Integration Connector Options

Product name - ev sas - big.png

Up arrow.png

Logo - XWiki.png

Check icon.png   Basic Access Authentication

REST data source   Apps - Datasource - JSON Online icon.png

SaaS Version of Third-Party Product

On-premise Version of Third-Party Product

Check icon.png

Check icon.png

SAS_ConventionAPIRequests_OnlyEN

Convention for the API requests

Curly brackets { } indicate values you have to supply. 

In most of the cases, we draw your attention with:

  • in green and bold, the important and mandatory values to be replaced;
  • in green, certain important and/or optional values (often choice of parameters).

Example documentation icon EN.png  https://{subdomain}.xwiki  ==> replace {subdomain} with the name of your XWiki instance

API detailed description

Item Comments
About the software and company

Logo - XWiki.png

XWiki is a free wiki software platform written in Java with a design emphasis on extensibility. XWiki Enterprise, the enterprise wiki edition, includes WYSIWYG editing, OpenDocument based document import/export, semantic annotations and tagging, and advanced permissions management.

Information about the REST API

Date on which the information was retrieved from the software company's website: March 2016

Last known REST API name/version/date: XWiki RESTful API

Note: Other APIs that can be used:

Main useful links to software company information about REST

XWiki REST API Introduction

XWiki REST API References

Format and sample of API resources/endpoints For SaaS version:
  • By default the XWiki RESTful API entrypoint is rooted at the following URI: https://{subdomain}/xwiki/rest/

    ==> https://{subdomain}/xwiki/rest/wikis/{wikiName}/spaces/{nestedSpaceName}/pages

Example documentation icon EN.png For EasyVista wiki called wiki and the space Documentation accessible by all Internet users:

==> https://wiki.easyvista.com/xwiki/rest/wikis/wiki/spaces/Documentation/pages

  • To retrieve content in JSON format:

    https://{subdomain}/xwiki/rest/wikis/{wikiName}/spaces/{nestedSpaceName}/pages?media=json

For On-premises version:
  • By default all the resources of the RESTful API are rooted at the following URI: http://{host:port}/xwiki/rest/

    ==> http://{host:port}/xwiki/rest/wikis/{wikiName}/spaces/{nestedSpaceName}/pages

Example documentation icon EN.png For a wiki on your localhost called wiki123 with a space Documentation:

==> http://localhost:8080/xwiki/rest/wikis/wiki123/spaces/Documentation/pages

  • To retrieve content in JSON format:

    http://{host:port}/xwiki/rest/wikis/{wikiName}/spaces/{nestedSpaceName}/pages?media=json

Notes:
  • When documenting a resource, XWiki uses curly brackets { } for identifiers.
  • Replace in the URI:
    • {subdomain} with your subdomain name provided by XWiki.
    • {wikiName} and {nestedSpaceName} with the name of the specific wiki and the name of the specific space for which you want to execute API calls.
    • {host:port} with the location of your server hosting XWiki.
API assets
  • A "HATEOAS" graph in order to better understand the relations among resources

  • Possibility to execute queries using other XWiki APIs (HQL, XWQL, Lucene or SOLR queries):

    https://{subdomain}/xwiki/rest/wikis/{wikiName}/query?q={query}&type={hql,xwql,lucene,solr}[&distinct={true,false}][&order={asc,desc}][&start=n][&number=n][&prettyNames={true,false}][&className=className]

API recommendations (limitations, advice, tips)
  • API calls: No information available/found
  • Pagination: /wikis/{wikiName}/spaces[?start=offset&number=n]
Comments
  • No API versioning
  • The total number of records is not returned in the JSON file

Step-by-step integration process

XWiki can be integrated with Product name - ev sas.png in 4 easy steps:


Step 1: Check the list of prerequisites

  • This documentation assumes that you already have a XWiki domain/platform or On-premises server.


Step 2: Start the process for creating the REST data source

 Open url.png  For details about the creation, see the wiki page REST data source

  • Click Apps - Add datasource icon.png in the Objects pane
  • Open the Online category and select the REST data source Apps - Datasource - JSON Online icon.png.
  • Name the data source.
             Example documentation icon EN.png  XWiki_List of Pages


Step 3: Authenticate to XWiki

Authenticate with Basic Access Authentication

  • Select the type of authentication: Authentication Type = Basic.
  • Click Apps - Edit icon.png next to the Basic Authentication Parameters field. 
  • Enter the User Name using the following format: firstname.lastname@company.com. Enter the Password.
             Basic Access Authentication.png
    • The user name is the XWiki account/login (with Admin credentials) you want to use for this data source. 
    • The password is the password set for this account.
    • Once you validate, the *** symbols will appear in the field.


Step 4: Create a query string using XWiki documentation

       Open url.png  See the XWiki REST API References (endpoints)
        Open url.png  See Examples of use cases

  • Create a query string as a data source, i.e. a resource to access, in the URL field.

Example documentation icon EN.png You want to create a data source that will retrieve the list of all wiki pages (including their URI) in a particular space of a particular wiki  ==>  Enter the following text in the URL field. Note: Replace {subdomain} with the name of your XWiki instance.

https://{subdomain}/xwiki/rest/wikis/{wikiName}/spaces/{nestedSpaceName}/pages?media=json

Best Practice big icon.pngBest Practice

      Open url.png  See Best Practice for the REST data source

  • You must keep all information on credentials secure.

Samples of most relevant use cases and resources

Note: Replace in the URI: 

  • {subdomain} with your subdomain name provided by XWiki.
  • {wikiName} and {nestedSpaceName} with the name of the specific wiki and the name of the specific space for which you want to execute API calls. 

Method: GET

Use Case Sample Endpoint
Retrieve the list of wikis available on the XWiki instance

Note: Unless the wiki is configured to be a wiki farm, this list is usually made of a single element xwiki.

Authentication Type: Basic Access Authentication
Basic Authentication Parameters: User Name: {email_address}

Password: {password}

URI: https://{subdomain}.xwiki/rest/wikis?media=json
Selector: N/A
Retrieve the list of all wiki pages (including their URI) in a particular space of a particular wiki

Authentication Type: Basic Access Authentication
Basic Authentication Parameters: User Name: {email_address}

Password: {password}

URI: https://{subdomain}/xwiki/rest/wikis/{wikiName}/spaces/{nestedSpaceName}/pages?media=json
Selector: N/A
Retrieve the list of wiki pages and objects that contain:
  • specific {keywords}
  • in specified {scopes}
  • with results sorted out in ascending order

Authentication Type: Basic Access Authentication
Basic Authentication Parameters: User Name: {email_address}

Password: {password}

URI: https://{subdomain}.xwiki/rest/wikis/{wikiName}/search?q={Keywords}&scope=name,content,title,objects&order=asc&media=json

Note: Replace {Keywords} with the keywords for which you want to get pages.

Example documentation icon EN.png For keyword = Rest Data Source and scopes = name and content

==> https://{subdomain}.xwiki/rest/wikis/{wikiName}/search?q=Rest%20Data%20Source&scope=name,content&order=asc&media=json

Selector: N/A
SAS_IntegrationRESTAboutTheUse_OnlyEN

About the use of the third-parties REST API

Please note that numerous software companies limit the access to the REST API of their software, generally by basing itself on a number of calls by hour/day/month.
Moreover, only specific editions of their software can be eligible in the use of the API REST (with or without additional cost).
Finally, some software companies set up plans (for example Classic, Professional, Enterprise, etc.) for which the number of possible calls to the REST API or even to specific resources (i.e. endpoints) can be more or less numerous.

The possible cost of the use of the third-parties API by means of Product name - ev sas.png is not taken care by Logo - EasyVista.png.

Tags:
Last modified by Unknown User on 2017/04/24 15:27
Created by Administrator XWiki on 2016/07/11 15:05

Shortcuts

Recent Updates

Haven't been here in a while? Here's what changed recently:

-   Product name - ev itsm.png
-   Product name - ev sas.png

Interesting Content

How to Automate Integration
Add a Shortcut to an App
History
Quick Dashboard
Full text search - Stop Words

Powered by XWiki ©, EasyVista 2018