Cloudcheck Go API1.0

Overview

The Cloudcheck Go API service enables you to send a secure link to your customers, allowing them to self-verify. Each Go request can provide this functionality for up to 500 of your customers (or "recipients" in Go terminology).

The methods available to send the links to your customers are flexible. You can have Cloudcheck send them an email or SMS. Alternatively you can download the links and send them yourself, or you can incorporate the link in your own system creating a seamless experience for your customers.

If offers the same functionality as the Go feature within Cloudcheck Direct and they can both work together. For example, you can create a Go request using the API, then login to Cloudcheck Direct and view the request. You could continue the process using either the API or Direct.

Create

Path /go/create/ Method POST

Creates a new Go request. Everything required by Go can be included in the request, including up to 500 recipients.

When creating a Go request, you must include the following parameters as part of the call.

Please note all these parameters must be posted as URL encoded form data. As such, the request should contain a Content-Type header of application/x-www-form-urlencoded.

Parameter Required Description
key true

Your API Key.

signature true

An HMAC SHA-256 signature of request data for call validation. See details on generating a request signature.

nonce true

A single-use key generated for this request. Note that each nonce may only be used once for each access key.

timestamp true

The system timestamp when the request was created in milliseconds since the Epoch (timezone independent). Note Unix time is in seconds and will need to be multiplied by 1000. Requests with old timestamps will be rejected.

data true

A JSON string containing the details to be verified.

Request

The details to be verified must be supplied as a JSON object, included in the POST as the data parameter. All the request parameters need to be included in the signature generation, and the request signed with the private key provided to you.

This API will validate each recipient and will not load it into the system if it's invalid. There must be at least 1 valid recipient for the request to succeed.

Example

Data Element Notes

Element Notes
reference A reference that you provide to identify this Go request. Optional but recommended.
notifications If true, you will be sent a notification email every time a user completes verification. Optional, defaults to false.
notificationEmailAddress Comma-separated list of email address that notifications are sent to. Mandatory if notifications is true.
sendReminders If true, recipients will get a reminder email after 5 days if they haven't performed their verification. Optional, defaults to false.
completeUrl Where to redirect users after completing the verification. Include the protocol at the start of the URL (https:// or http://). This element is optional but highly recommended. A token parameter will be added to the URL that can be used in the Go Result and PDF Result API calls, to fetch the results for this recipient in either json or PDF format. If you do not specify a completeUrl the user will be redirected to a default "thank you" page.
notificationUrl A URL that we will call when the status of a recipient in this request changes. Include the protocol at the start of the URL (https:// or http://). A goApiReference parameter will be added to the URL that identifies the Go request, a recipientToken parameter identifies the recipient within the Go request and a status parameter gives the new status.
emailFrom Where the email is from, usually the name of your organisation. Mandatory if recipient email addresses have been entered.
replyTo An email address for replies to your organisation. Mandatory if recipient email addresses have been entered.
emailSubject Email subject. Mandatory if recipient email addresses have been entered.
emailContent The content of the email. This content can include safe HTML tags, unsafe tags such as <script> will be removed.
recipients A list of recipients. At least 1 and no more than 500 valid recipients must be provided.
name Standard name fields.
emailAddress The email address of the recipient.
mobileNumber The mobile phone number of the recipient.
dateofbirth The date of birth in yyyy-MM-dd format.
address Standard address fields of the recipient. Must not be a PO Box. Australian addresses would include state and no suburb.
reference A reference that you provide to identify this recipient. Optional but recommended.
requestType Specifies what checks you want the recipient to complete. One or more of verification, live, idscan, akahu or credfin must be true. Live, IDscan, Akahu and Credfin must be configured for your Cloudcheck account in order to use them.

Response

The response JSON contains the outcome of the request.

Example

The goApiReference returned in a successful response is a unique reference for this request and is used in the other Go API requests.

Possible error codes for invalid recipients and their error codes are:

Code Description
INVALID_PHONE_NUMBER Enter a mobile number including the country code (eg. +64).
INVALID_DATE_OF_BIRTH Invalid date of birth
INVALID_ADDRESS Invalid address
MISSING_SERVICE Please select either verification or an additional measure (e.g. Cloudcheck Live, IDscan, Akahu or Credfin).
SERVICE_NOT_AVAILABLE An additional measure (e.g. Live, IDscan, Akahu or Credfin) has been requested but is not available.

Add Recipient

Path /go/add-recipient/ Method POST

Add a recipient to an existing Go request.

Parameter Required Description
key true

Your API Key.

signature true

An HMAC SHA-256 signature of request data for call validation. See details on generating a request signature.

nonce true

A single-use key generated for this request. Note that each nonce may only be used once for each access key.

timestamp true

The system timestamp when the request was created in milliseconds since the Epoch (timezone independent). Note Unix time is in seconds and will need to be multiplied by 1000. Requests with old timestamps will be rejected.

data true

A JSON string containing the details of the recipient.

Request

The recipient details must be supplied as a JSON object, included in the POST as the data parameter. All the request parameters need to be included in the signature generation, and the request signed with the private key provided to you.

This API will validate the recipient and will not load it into the system if it's invalid.

Example

Note that additional elements can be sent for a recipient, however this is the typical information supplied. See the Go Create API example for details of additional elements available.

Response

The response JSON contains the outcome of the request. A successful response is shown in the following example.

Example

The recipientToken uniquely identifies the recipient within the Go request and can be used in other Go API calls.

Edit Recipient

Path /go/edit-recipient/ Method POST

Edit a recipient in an existing Go request.

Parameter Required Description
key true

Your API Key.

signature true

An HMAC SHA-256 signature of request data for call validation. See details on generating a request signature.

nonce true

A single-use key generated for this request. Note that each nonce may only be used once for each access key.

timestamp true

The system timestamp when the request was created in milliseconds since the Epoch (timezone independent). Note Unix time is in seconds and will need to be multiplied by 1000. Requests with old timestamps will be rejected.

data true

A JSON string containing the details of the recipient.

Request

The recipient details must be supplied as a JSON object, included in the POST as the data parameter. All the request parameters need to be included in the signature generation, and the request signed with the private key provided to you.

This API will validate the recipient and will not load it into the system if it's invalid.

If successful, the existing recipient will be completely replaced by the details supplied in this call.

Example

Note that additional elements can be sent for a recipient, however this is the typical information supplied. See the Go Create API example for details of additional elements available.

Response

The response JSON contains the outcome of the request. A successful response is shown in the following example.

Example

Note: the recipientToken will change if a recipient emailAddress or mobileNumber has changed and an email/SMS has already been sent. In this scenario the old recipientToken will no longer be valid.

Cancel Recipient

Path /go/cancel-recipient/ Method POST

Cancel a single or multiple recipients in an existing Go request.

Request

The recipient details must be supplied as a JSON object, included in the POST as the data parameter. All the request parameters need to be included in the signature generation, and the request signed with the private key provided to you.

This API will check if the recipient exists in the system.

If successful, the existing recipient will be cancelled by the token supplied in this call.

Example

Response

The response JSON contains the outcome of the request. A successful response is shown in the following example.

Example

Send

Path /go/send/ Method POST

There are two use cases for using this API.

The first is to send a test email and/or SMS message. It is not a requirement that you send a test email/SMS before sending the real email/SMS to recipients. One reason you might want to send a test is to check that the email looks correct. If you want to change the wording or formatting of the email after the test you can use the Go functionality with Cloudcheck Direct to modify the email contents.

The second is to send emails and/or SMS's to the recipients in this Go request.

When calling this API, you must include the following parameters as part of the call.

Please note all these parameters must be posted as URL encoded form data. As such, the request should contain a Content-Type header of application/x-www-form-urlencoded.

Parameter Required Description
key true

Your API Key.

signature true

An HMAC SHA-256 signature of request data for call validation. See details on generating a request signature.

nonce true

A single-use key generated for this request. Note that each nonce may only be used once for each access key.

timestamp true

The system timestamp when the request was created in milliseconds since the Epoch (timezone independent). Note Unix time is in seconds and will need to be multiplied by 1000. Requests with old timestamps will be rejected.

data true

A JSON string containing the details to be verified.

Request

The behaviour of the Send request is specified using the data parameter, which is a JSON object.

Example

Response

The response JSON contains the results of the Send request.

Example

Resend

Path /go/resend/ Method POST

Resend an email/SMS to a recipient within this Go request.

Parameter Required Description
key true

Your API Key.

signature true

An HMAC SHA-256 signature of request data for call validation. See details on generating a request signature.

nonce true

A single-use key generated for this request. Note that each nonce may only be used once for each access key.

timestamp true

The system timestamp when the request was created in milliseconds since the Epoch (timezone independent). Note Unix time is in seconds and will need to be multiplied by 1000. Requests with old timestamps will be rejected.

data true

A JSON string containing the details of the Go request and recipient.

Request

The Go request and recipient identifiers must be supplied as a JSON object, included in the POST as the data parameter. All the request parameters need to be included in the signature generation, and the request signed with the private key provided to you.

Example

Response

The response JSON contains the outcome of the request. A successful response is shown in the following example.

Example

Quick Send

Path /go/quicksend/ Method POST

Allows you to quickly send an email or SMS with minimal information required.

When creating a Go Quick Send request, you must include the following parameters as part of the call.

Please note all these parameters must be posted as URL encoded form data. As such, the request should contain a Content-Type header of application/x-www-form-urlencoded.

Parameter Required Description
key true

Your API Key.

signature true

An HMAC SHA-256 signature of request data for call validation. See details on generating a request signature.

nonce true

A single-use key generated for this request. Note that each nonce may only be used once for each access key.

timestamp true

The system timestamp when the request was created in milliseconds since the Epoch (timezone independent). Note Unix time is in seconds and will need to be multiplied by 1000. Requests with old timestamps will be rejected.

data true

A JSON string containing the details to be verified.

Request

The details to be verified must be supplied as a JSON object, included in the POST as the data parameter. All the request parameters need to be included in the signature generation, and the request signed with the private key provided to you.

Example

Notes:

  • Either emailAddress or mobileNumber must be provided if generateLink is false.
  • One or more elements in requestType must be true.
  • Users will be redirect to the completeUrl after completing the verification. Include the protocol at the start of the URL (https:// or http://). This element is optional but highly recommended. A token parameter will be added to the URL that can be used in the Go Result and PDF Result API calls, to fetch the results for this recipient in either json or PDF format. If you do not specify a completeUrl the user will be redirected to a default "thank you" page.
  • The notificationUrl is a URL that we will call when the status of the recipient in this request changes. Include the protocol at the start of the URL (https:// or http://). A goApiReference parameter will be added to the URL that identifies the Go request, a recipientToken parameter identifies the recipient within the Go request and a status parameter gives the new status.

Response

The response JSON contains the outcome of the request.

Example

The goApiReference returned in a successful response is a unique reference for this request and is used in the other Go API requests. The recipientToken can also be used in other APIs, such as fetching the results of the Go request.

Result

Path /go/result/ Method GET

Fetches the verification result for an individual recipient. You must include the following parameters as part of the call.

Parameter Required Description
key true

Your API Key.

signature true

An HMAC SHA-256 signature of request data for call validation. See details on generating a request signature.

nonce true

A single-use key generated for this request. Note that each nonce may only be used once for each access key.

timestamp true

The system timestamp when the request was created in milliseconds since the Epoch (timezone independent). Note Unix time is in seconds and will need to be multiplied by 1000. Requests with old timestamps will be rejected.

token true

A recipient token. This token is passed as a parameter to the completeUrl that you specified in the Go Create API. You can also call the Go Results API, which will show the current status of all recipients, including the token.

Response

An example response is shown below.

Example

Refer to the Integrated Verification API response for standard verification fields.

Refer to the Live Result API response for standard Live fields.

Refer to the Credfin Result API response for standard Credfin fields.

Refer to the Akahu Result API for standard Akahu fields.

Refer to the IDscan Result API for standard IDscan fields.

Results

Path /go/results/ Method GET

Fetches the verification results for each recipient at this point in time in JSON format.

Parameter Required Description
key true

Your API Key.

signature true

An HMAC SHA-256 signature of request data for call validation. See details on generating a request signature.

nonce true

A single-use key generated for this request. Note that each nonce may only be used once for each access key.

timestamp true

The system timestamp when the request was created in milliseconds since the Epoch (timezone independent). Note Unix time is in seconds and will need to be multiplied by 1000. Requests with old timestamps will be rejected.

goApiReference true

The unique reference that was returned in the Go Create response.

Response

An example response is shown below:

Example

The possible values for the recipient status element are: Not Sent, Sent, Delivered, Bounced, Delayed, Rejected, Opened, Clicked, Expired and Responded. A status of Expired can either mean that the user did not complete the verification before it expired, it can also mean that the user completed part of the verification but then cancelled before they finished. Therefore you should fetch the results of the verification when the status is Responded or Expired.

PDF Result

Path /go/pdf/ Method GET

Fetches the verification result for an individual recipient in PDF format. You must include the following parameters as part of the call.

Parameter Required Description
key true

Your API Key.

signature true

An HMAC SHA-256 signature of request data for call validation. See details on generating a request signature.

nonce true

A single-use key generated for this request. Note that each nonce may only be used once for each access key.

timestamp true

The system timestamp when the request was created in milliseconds since the Epoch (timezone independent). Note Unix time is in seconds and will need to be multiplied by 1000. Requests with old timestamps will be rejected.

token true

A recipient token. This token is passed as a parameter to the completeUrl that you specified in the Go Create API. You can also call the Go Results API, which will show the current status of all recipients, including the token.

Response

This method will either return a PDF file or a JSON object with an error message. You should check the response Content-Type to determine which you have received.

Generate PDF Results

Path /go/pdfs/generate/ Method GET

Requests the generation of PDF results for each recipient that has responded. This is a time consuming process that can take around an hour to complete for 500 recipients, therefore it is an asynchronous operation. First you request that the PDFs are generated, using this API. Then you call the Retrieve PDF Results API to download a zip file containing the PDFs.

Parameter Required Description
key true

Your API Key.

signature true

An HMAC SHA-256 signature of request data for call validation. See details on generating a request signature.

nonce true

A single-use key generated for this request. Note that each nonce may only be used once for each access key.

timestamp true

The system timestamp when the request was created in milliseconds since the Epoch (timezone independent). Note Unix time is in seconds and will need to be multiplied by 1000. Requests with old timestamps will be rejected.

goApiReference true

The unique reference that was returned in the Go Create response.

Response

An example response looks like this:

Example

The token that is returned is used in the Retrieve PDF results request.

Retrieve PDF Results

Path /go/pdfs/retrieve/ Method GET

Retrieves a zip file containing the PDF results of each recipient that has responded. If the generation of the PDFs is still in progress a JSON response is returned instead, with the status of the job.

If another response is received from an end user after the PDF results were generated this call will result in a 'Missing or invalid token' error as the results are no longer current. In this case you will need to generate the results again.

Parameter Required Description
key true

Your API Key.

signature true

An HMAC SHA-256 signature of request data for call validation. See details on generating a request signature.

nonce true

A single-use key generated for this request. Note that each nonce may only be used once for each access key.

timestamp true

The system timestamp when the request was created in milliseconds since the Epoch (timezone independent). Note Unix time is in seconds and will need to be multiplied by 1000. Requests with old timestamps will be rejected.

token true

The token returned in the Go Generate PDF Results API response.

Response

If the PDF generation is complete a zip file will be returned containing the PDF documents. If the generation is still in progress the following JSON will be returned:

Example