Api.createGuestLink¶
- createGuestLink(email, name, branchId, applicationFlexibleFieldValues, emailSubjectOverride, emailContentOverride, sendEmail, operationMode, clientApplicationReference, digitalIdentificationScheme, containerEventCallbackUrl, containerEventCallbackHeaders)¶
Creates a new link that allows a guest to log in and upload one application. The link remains valid until an application is submitted using it, or until it expires. The expiry period is configured against a customer account and is typically seven days.
This method executes asynchronously and returns a promise.
- Arguments
email (
string()
) – The email address of the guest. An invitation email is sent to this address containing the link to allow them to login.name (
string()
) – The name of the guest. This is used in the invitation email and is also stored in the application’s guest name flexible field.branchId (
guid()
) – Optional: The unique identifier of the branch to assign this guest application to. If this is not supplied, the application is assigned to the branch of the session account.applicationFlexibleFieldValues (
object()
) – Optional: Contains application-level custom field information used to set these custom fields. The methodContainer.createCustomFields()
can be used to create the required object data.emailSubjectOverride (
string()
) – Optional: Use this to override the default Subject used in the email sent to the guest. To use the default Subject, keep the default value of null.emailContentOverride (
string()
) – Optional: Use this to override the default email body used in the email sent to the guest. To use the default email body, keep the default value of null. Only the first part of the email body can be modified; the second part is fixed. Supply this value as markdown. It is converted to HTML when the email is sent.sendEmail (
bool()
) – Optional: A flag that determines whether an email is sent to the guest. The default value istrue
. If this is set tofalse
, the link is included in the response and it is the caller’s responsibility to pass this onto the guest.operationMode (
int()
) – Optional: A flag that controls whether a guest link is generated, or whether only email content is generated. This allows you to display the email content to a user so they can modify it. The default value is 0, meaning the link is generated. A value of 1 only returns default email content and does not create and send the link.clientApplicationReference (
string()
) – Optional: An optional string that can be passed through, that allows for calling clients to add identifying information. This may be useful for the adding of context mapping, or linking your object ID’s to ours. This value will be included in request payload sent to your webhook.digitalIdentificationScheme (
int()
) – Optional: A flag that controls whether a guest link is set to achieve Digital Identification Profile, like Right To Work Or Right To Rent. The default value is 0, meaning it is not needed.containerEventCallbackUrl (
string()
) – Optional: An url used for callback to your webhook.containerEventCallbackHeaders (
object()
) – Optional: Contains list of Headers and Values used in callback.
See also
DigitalIdentificationScheme for more information about the digital identification scheme.
- Returns
For error responses, see Error Responses.
If successful, the response object provides different data depending on your input. The response could include the following properties:
Success – This property is always present and is set to
true
when the call succeeds.EmailSubject – The default email subject used in the email sent to the guest. This is only included if you set operationMode to 1.
EmailContent – The default email body used in the email sent to the guest. Note that this is not the entire body, only the overridable top portion. This is only included if you set operationMode to 1.
LinkUrl – The link the guest should use to access the TrustID web client to upload their application. This is only included if you set operationMode to 0 and sendEmail to
false
.