1.0.3 • Published 6 years ago

on-demand-client v1.0.3

Weekly downloads
7
License
Apache 2.0
Repository
-
Last release
6 years ago

on-demand-client

The Sterling On Demand API allows you to integrate background checks into your platform and manage the process from end-to-end. This SDK is automatically generated by the Swagger Codegen project:

  • API version: 2018-05-08T16:44:26.238-07:00
  • Package version: 1.0.3
  • Build package: io.swagger.codegen.languages.JavascriptClientCodegen

Installation

For Node.js

npm

Install it via:

npm install on-demand-client --save

Setting credentials

The example script as well as the Integration tests, require valid credentials. For these scripts, the 'CREDENTIALS' environmental variable needs to be set to your API credentials. These credentials are a base64 hash of "apiusername:password".

For example, the base64 hash of "username@yourcompany.com:somepassword" is "dXNlcm5hbWVAeW91cmNvbXBhbnkuY29tOnNvbWVwYXNzd29yZA=="

Getting Started

Please follow the installation instruction and execute the following JS code:

var OnDemandClient = require('on-demand-client');

// default basePath is set to the testing env https://api-int.kennect.com
// for pointing to production set basePath as shown below
//OnDemandClient.ApiClient.instance.basePath = "https://api.kennect.com/v1";
//OnDemandClient.Auth.ApiClient.instance.basePath = "https://api.kennect.com/oauth";

var api = new OnDemandClient.DefaultApi();
var authApi = new OnDemandClient.Auth.DefaultApi();

var credentials = process.env.CREDENTIALS;

authApi.tokenPost('Basic ' + credentials, function(error, fetched, response) {
    if (error) throw error;
    var defaultClient = OnDemandClient.ApiClient.instance;
    defaultClient.defaultHeaders['Authorization'] = 'Bearer ' + fetched.access_token;

    api.packagesGet(null, function(error, fetched, response) {
        if (error) throw error;
        console.log(fetched);
    });
});

More Examples

For more examples of API invocations see on-demand-client/test/integration/DefaultApi.int.spec.js. Some integration tests may require specific account configurations in order to pass.

Documentation for API Endpoints

All URIs are relative to https://api-int.kennect.com/v1

ClassMethodHTTP requestDescription
OnDemandClient.DefaultApibillingCodesGetGET /billing-codesGet a list of valid billing codes
OnDemandClient.DefaultApicandidatesGetGET /candidatesGet a list of Candidates
OnDemandClient.DefaultApicandidatesIdDocumentsGetGET /candidates/{id}/documentsList documents attached to a candidate
OnDemandClient.DefaultApicandidatesIdDocumentsPostPOST /candidates/{id}/documentsAttach a document to a candidate
OnDemandClient.DefaultApicandidatesIdGetGET /candidates/{id}Get a specific Candidate
OnDemandClient.DefaultApicandidatesIdLinksPostPOST /candidates/{id}/linksGet links to the Candidate portal for use by the Candidate
OnDemandClient.DefaultApicandidatesIdPutPUT /candidates/{id}Update a candidate
OnDemandClient.DefaultApicandidatesIdTrustPostPOST /candidates/{id}/trustTrust a candidate
OnDemandClient.DefaultApicandidatesPostPOST /candidatesCreate a candidate
OnDemandClient.DefaultApichargesPostPOST /chargesCreate a capture
OnDemandClient.DefaultApihealthGetGET /healthCheck the health of the API
OnDemandClient.DefaultApiidentitiesIdGetGET /identities/{id}Get a verified identity
OnDemandClient.DefaultApiidentitiesIdRetryPostPOST /identities/{id}/retryRetry creating an identity and get a new set of questions
OnDemandClient.DefaultApiidentitiesIdVerificationPutPUT /identities/{id}/verificationVerify an identity by providing correct answers
OnDemandClient.DefaultApiidentitiesPostPOST /identitiesGet a list of questions needing to be answered before an identity can be created
OnDemandClient.DefaultApipackagesGetGET /packagesGet a list of Packages
OnDemandClient.DefaultApipackagesIdPriceGetGET /packages/{id}/priceGet the estimated price of a Package
OnDemandClient.DefaultApireferenceCodesGetGET /reference-codesReturn a list of valid Reference Codes
OnDemandClient.DefaultApiscreeningsIdAdverseActionsPostPOST /screenings/{id}/adverse-actionsCreate an adverse action on a Screening
OnDemandClient.DefaultApiscreeningsIdDetailsGetGET /screenings/{id}/detailsGet a specific screening
OnDemandClient.DefaultApiscreeningsIdDocumentsAttachmentIdGetGET /screenings/{id}/documents/{attachmentId}Get a Screening attachment in PDF form
OnDemandClient.DefaultApiscreeningsIdDocumentsGetGET /screenings/{id}/documents
OnDemandClient.DefaultApiscreeningsIdDocumentsPostPOST /screenings/{id}/documentsAttach a document to a Screening
OnDemandClient.DefaultApiscreeningsIdGetGET /screenings/{id}Get a specific screening
OnDemandClient.DefaultApiscreeningsIdInvitePostPOST /screenings/{id}/inviteCreate an invite
OnDemandClient.DefaultApiscreeningsIdReportGetGET /screenings/{id}/reportGet a Screening report in PDF form
OnDemandClient.DefaultApiscreeningsIdReportLinksPostPOST /screenings/{id}/report-linksCreate a one-time use report link
OnDemandClient.DefaultApiscreeningsIdReportPdfGetGET /screenings/{id}/report.pdfGet a Screening report in PDF form
OnDemandClient.DefaultApiscreeningsPostPOST /screeningsCreate a Screening
OnDemandClient.DefaultApisubscriptionsIdDeleteDELETE /subscriptions/{id}Delete a subscription
OnDemandClient.DefaultApisubscriptionsIdEventsGetGET /subscriptions/{id}/eventsGet a list of events related to a given subscription
OnDemandClient.DefaultApisubscriptionsIdGetGET /subscriptions/{id}Get a subscription
OnDemandClient.DefaultApisubscriptionsPostPOST /subscriptionsCreate a subscription
OnDemandClient.DefaultApitokensPostPOST /tokensCreates a temporary access token
OnDemandClient.DefaultApitrustedUsersIdGetGET /trusted-users/{id}Get trust information about a verified user
OnDemandClient.DefaultApitrustedUsersPostPOST /trusted-usersTrust a verified user
OnDemandClient.DefaultApitrustsIdDeleteDELETE /trusts/{id}Untrust a Trusted User

Documentation for Models

Documentation for Authorization

jwt-authorizer

  • Type: OAuth
  • Flow: password
  • Authorization URL:
  • Scopes:
    • user: User Scope
1.0.3

6 years ago

1.0.2

6 years ago

1.0.1

6 years ago

1.0.0

6 years ago