classafHcaptcha::CaptchaClient

sys::Obj
  afHcaptcha::CaptchaClient

@Js

getResponse

Source

Str? getResponse(Str widgetId)

Returns the result of the user completing hCapture puzzles.

make

Source

new make(Str siteKey, Bool enabled)

render

Source

Str render(Str containerId, [Str:Obj?]? params := null)

theme, type, size, tabindex callback, expired-callback, error-callback not supported

No need to add sitekey

Themes: normal = 304px x78px

compact = 164px x 144px

What's returned is NOT the hCaptcha widget id

See hCaptcha Container Configuration for details.

reset

Source

Void reset(Str widgetId)

setResponse

Source

static Void setResponse(Str? response)

Use in testing to set a stubbed response to be validated by the server. Valid codes accepted by CaptchaServer are:

  • <fail>
  • <error>
  • <success>

Only works when hCapture is not enabled.