Introduction to the Subscribe-HR RESTful API

From Subscribe-HR Wiki Help
Jump to: navigation, search
(Authentication)
(4 intermediate revisions by the same user not shown)
Line 1: Line 1:
 
{{page.name: Integration Module: Introduction to the Subscribe-HR RESTful API - Subscribe-HR Wiki}}
 
{{page.name: Integration Module: Introduction to the Subscribe-HR RESTful API - Subscribe-HR Wiki}}
{{page.head: Introduction to the Subscribe-HR API}}
+
{{page.head: Introduction to the Subscribe-HR RESTful API}}
  
 
__TOC__
 
__TOC__
Line 28: Line 28:
 
<td width="150"><b><font face="Arial" size="2">Field Name</font></b></td>
 
<td width="150"><b><font face="Arial" size="2">Field Name</font></b></td>
 
<td width="550"><b><font face="Arial" size="2">Description</font></b></td>
 
<td width="550"><b><font face="Arial" size="2">Description</font></b></td>
 +
</tr>
 +
        <tr>
 +
<td width="150"><font face="Arial" size="2">UUID</font></td>
 +
<td width="550"><font face="Arial" size="2">Unique record ID</font></td>
 
</tr>
 
</tr>
 
<tr>
 
<tr>
Line 56: Line 60:
 
<td width="150"><font face="Arial" size="2">Start Date</font></td>
 
<td width="150"><font face="Arial" size="2">Start Date</font></td>
 
<td width="550"><font face="Arial" size="2">Date when scheduler will become active.</font></td>
 
<td width="550"><font face="Arial" size="2">Date when scheduler will become active.</font></td>
 +
</tr>
 +
<tr>
 +
<td width="150"><font face="Arial" size="2">Belongs to App</font></td>
 +
<td width="550"><font face="Arial" size="2">Select app if this authentication record is to be added to one of your apps.</font></td>
 
</tr>
 
</tr>
  
Line 65: Line 73:
  
 
The following fields are available:
 
The following fields are available:
 +
* '''UUID''': Unique record ID.
 
* '''Type''': Determines the type of authentication. Options are: '''OAuth2.0''' and '''Authorization Header'''.
 
* '''Type''': Determines the type of authentication. Options are: '''OAuth2.0''' and '''Authorization Header'''.
 
* '''Name''': The name of the integration.
 
* '''Name''': The name of the integration.
Line 79: Line 88:
 
* '''Header Name''': The name of the Authorization Header.
 
* '''Header Name''': The name of the Authorization Header.
 
* '''Authorisation Method''': The method of Authorisation used by the header.
 
* '''Authorisation Method''': The method of Authorisation used by the header.
 +
* '''Belongs to App''': Select app if this authentication record is to be added to one of your apps.
  
 
[[File:subscribehr_logo.gif]]
 
[[File:subscribehr_logo.gif]]

Revision as of 01:00, 1 April 2019


RESTful API

Subscribe-HR API or SAPI for short is the primary way to get data out of, and put data into, the platform. It's an HTTP-based RESTful API that you can use to query, create, update and delete entities within Subscribe-HR. All the supported operations are outlined on apiary at the following link http://docs.subscribehr.apiary.io

SHaRpi Integration Module

The Integration Module provides a front-end configurable interface for setting up integrations using the RESTful API. Additional documentation can be found here: http://subscribehr.readthedocs.io/en/latest/sharpi.html

It contains the following two sections:

Processes

The Processes page allows you to define your JSONpath configuration file. There are 2 available tabs for this:

  1. Configuration: This tab holds the configuration file to be edited. The configuration file process can be run from here.
    • Run Processes: This will run the process currently loaded, hoever please note, the record needs to be saved and validated before running the process. Running process before saving it will execute previous version of configuration file.
  2. Events: This tab holds the log of events that occur when running the process.

Fields

Field Name Description
UUID Unique record ID
Name The name that will be assigned to the saved process
Last Executed The last time the process was run
Last Successful Execution The last time process has completed successfully
Enable Scheduler Enable scheduler to run the process on predefined interval
Interval Scheduler interval - must be a whole number e.g. 10 minutes
Units Interval units e.g. minutes, hours, days etc.
Start Date Date when scheduler will become active.
Belongs to App Select app if this authentication record is to be added to one of your apps.

Authentication

The Authentication records provide a record that can be referenced in your configuration Processes record. This authentication record holds the access tokens and keys depending on the authentication type.

The following fields are available:

  • UUID: Unique record ID.
  • Type: Determines the type of authentication. Options are: OAuth2.0 and Authorization Header.
  • Name: The name of the integration.
  • Grant Type: The Authorisation grant type.
  • Client ID: A field for the string that identifies the Client to be entered.
  • Client Secret: An encrypted field for holding a key belonging to the client.
  • Refresh Token: An encrypted field for holding the refresh token response after making a call.
  • Access Token Expiry: The date and time the Access toekn expires.
  • Refresh Token Expiry: The date and time the refresh token expires.
  • URL: The initial URL that the authorisation is sent to.
  • Scope: The scope of the access for the integration.
  • Access Token URL: The inital URL the access token is sent to.
  • Request Parameters: The parameters for SHaRpi to request new tokens.
  • Header Name: The name of the Authorization Header.
  • Authorisation Method: The method of Authorisation used by the header.
  • Belongs to App: Select app if this authentication record is to be added to one of your apps.

Subscribehr logo.gif