@orbaone/api v0.0.6
Orba One Node
The official Node client for the Orba One API.
To start using Orba One's Node Client follows these simple steps:
- Install the Client through NPM/Yarn.
- Get an API and Secret Key.
- Start using the client.
Additional information can be found here.
1. Install the client
# Yarn
yarn add @orbaone/api
# NPM
npm install --save @orbaone/api
2. Get an API Key
The client requires the settings apiKey
and apiSecret
. Login to your OrbaOne account and create a new OrbaOne API and Secret key here: Developer Dashboard.
3. Usage
Initialize the Orba One Client.
Example
import { OrbaOne } from '@orbaone/api';
const client = new OrbaOne({
apiKey: 'test',
apiSecret: 'secret',
});
Parameters
Parameter | Type | Example | Description |
---|---|---|---|
apiKey | string | 'test' | The OrbaOne API Key you obtained from the dashboard. |
apiSecret | string | 'test' | The OrbaOne Secret Key you obtained from the dashboard. |
basePath | string(Optional) | 'https://api.orbaone.com/api' | The base URL of all API endpoints. |
apiVersion | string(Optional) | 'v1' | The API version. |
Methods
createApplicant(data)
This method allows you to create an Applicant.
Parameters
The data
parameter is an object that consists of the following:
Parameter | Type | Example |
---|---|---|
data.firstName | string | 'John' |
data.middleName | string(Optional) | 'Daniel' |
data.lastName | string | 'Scott' |
getApplicants(query)
This method allows you to get all the applicants.
Parameters
The query
parameter is an object that consists of the following:
Parameter | Type | Example |
---|---|---|
query.search | string(Optional) | 'John' |
query.pageSize | number(Optional) | 1 |
query.page | number(Optional) | 1 |
getApplicantByID(id)
This method allows you to get a specified applicant's data.
Parameters
Parameter | Type | Example |
---|---|---|
id | string | '7S7S7S' |
getApplicantPEPResult(id)
This method allows you to get a specified applicant's PEP scan results.
Parameters
Parameter | Type | Example |
---|---|---|
id | string | '7S7S7S' |
getApplicantSanctionResult(id)
This method allows you to get a specified applicant's Sanction scan results.
Parameters
Parameter | Type | Example |
---|---|---|
id | string | '7S7S7S' |
request(url, options)
This method is not dependent on the API version and allows the making of custom requests.
Parameters
Parameter | Type | Example | Description |
---|---|---|---|
url | string | 'https://api.orbaone.com/api/v1/applicants' | API endpoint. |
options | Object | {method:'PUT', body: JSON.stringify(data)} | An object that allows you to control a number of different options for the request. |