Configuration Object
Configuration Object
You configure Arkose Bot Manager by setting attribute values for the configuration object. This is done using the setConfig
method on the Arkose object passed to the setup function, as shown here. If any of the callback functions are not invoking as expected, contact your Sales Rep or Sales Engineer. Note that there are separate examples for our detection and enforcement components.
Note that callbacks, onShown
, onSuppress
onCompleted
, onError
, onFailed
, and onResize
, return a response
object, which contains information that usually needs to be further processed or presented to users by your code. See Response Object for more details.
// The Callback Function
function setupEnforcement(myEnforcement) {
myEnforcement.setConfig({
publicKey: '<YOUR PUBLIC KEY>',
data: {},
language: 'ar',
onCompleted: (response) => {},
onHide: () => {},
onReady: () => {},
onReset: () => {},
onShow: () => {},
onShown: (response) => {},
onSuppress: (response) => {},
onError: (response) => {},
onFailed:(response) => {},
onWarning:(response) => {},
onResize: (response) => {},
selector: '#my-submit-button',
accessibilitySettings: {
lockFocusToModal: true
}
});
}
// The Callback Function
function setupDetect(myDetect) {
myDetect.setConfig({
publicKey: '<YOUR PUBLIC KEY>',
data: {},
onCompleted: (response) => {},
onHide: () => {},
onReady: () => {},
onShow: () => {},
onSuppress: () => {},
onError: (response) => {},
onWarning:(response) => {},
selector: '#my-submit-button'
}
});
}
This table shows the settable setConfig
attributes, their types, brief description and to which product they are applicable.
Attribute | Type | Description | Applicable Component |
---|---|---|---|
| String | An optional attribute that can be used to dynamically set the Arkose Lab’s Public Key if needed. | Detection |
| Object | Encrypted arbitrary JSON data sent to Arkose at the very start of a sessions classification. This is how Arkose Data Exchange data is sent to the API. | Detection |
| String | Language code. See Supported Languages for our supported values. Browser settings control Arkose Platform's language, but can be overridden by using this setting to pass your desired language's entire Locale ID String. | Enforcement |
| Function | Callback function invoked when applicable detection and/or enforcement has been successfully completed. A Response Object is passed to this function. See Response Object for details. | Detection |
| Function | Callback function invoked when the detection and/or enforcement view is hidden. For example, this happens after detection and/or enforcement is completed. It's also triggered during enforcement if the user clicks the close button. Note that the close button only appears when in Lightbox mode. | Detection |
| Function | Callback function invoked when the detection or enforcement is ready. The Enforcement cannot be triggered before this event. You may want to disable the UI you are protecting until this event has been triggered. | Detection |
| Function | A callback invoked when detection and/or enforcement is loading. The function is also invoked when an enforcement is re-displayed (e.g. if the user closes the view and tries to continue). Note that the close button only appears when in Lightbox mode. | Detection |
| Function | Only applicable to enforcement. A callback invoked when the Enforcement Challenge is displayed. The A Response Object is passed to this function. See Response Object for details. | Enforcement |
| Function | A callback invoked when the detection and/or enforcement is running and the Arkose Platform is analyzing the user intent. A Response Object is passed to this function. See Response Object for details. | Detection |
| Function | A callback invoked when an error occurs in loading of the detection and/or enforcement. A Response Object is passed to this function.See Response Object for details. | Detection |
| Function | A callback invoked when a warning occurs in generating image assets for the enforcement challenge. A Response Object is passed to this function.See Response Object for details. | Enforcement |
| Function | Callback function invoked when a challenge has failed (the user has failed the challenge multiple times and is not allowed to continue the session). A Response Object is passed to this function.See Response Object for details. | Enforcement |
| Function | A callback invoked when a sizing event occurs in the loading of the challenge. A Response Object is passed to this function. See Response Object for details. | Enforcement |
| Function | A callback invoked after the enforcement resets. Typically occurs after a challenge has been successfully answered. Note that your implementation should not call the | Enforcement |
| String | The element selector (e.g. | Enforcement |
| String | Sets if the Enforcement Challenge will be shown as a modal or within the selected element. Allowed values are lightbox and inline, where the default is lightbox, which indicates display as modal. | Enforcement |
| Object | Contains settings for accessibility that need to make changes implementing websites markup.
| Enforcement |
| String | Sets theme to existing style manager built theme with the given name. If not set, the default theme is used. | Enforcement |
| Boolean (true/false) | Allows Default value is | Detection |
Updated 10 days ago