Skip to main content
Are you experiencing issues obtaining the token?
Contact support

Receiving events from the extension

The CapMonster extension allows your code to track key moments in the captcha solving process directly on the webpage. Using events, you can know when a captcha solving attempt starts, when it successfully completes, or if an error occurs, and perform the corresponding actions in your script.

All events are sent to the global window object on the current page. This means you can subscribe to them using the standard window.addEventListener method and respond to events without complex workarounds.

Using these events is convenient if you want to:

  • Track the progress of captcha solving in real time.
  • Automatically trigger actions after a captcha is successfully solved.
  • Handle errors and re-initiate captcha solving if necessary.

The following sections provide a complete list of available events with a brief description of each.

info

No parameters are passed to events

Example

window.addEventListener("onCMExtensionReady", () => {
// DO SOMETHING
})

Available events

Global

EventDescription
onCMExtensionReadyThe extension is fully loaded and ready to work

ReCaptcha

EventDescription
onReCaptchaClickStartImage click event when solving ReCaptcha by clicks
onReCaptchaClickSubmit or next button click event when solving ReCaptcha by clicks
onReCaptchaClickIncorrectIncorrect ReCaptcha solving by clicks
onReCaptchaClickBackendErrorError when solving ReCaptcha by clicks
onReCaptchaClickSuccessSuccessful solving ReCaptcha by clicks
onRecaptchaTokenStartStart solving ReCaptcha by token
onRecaptchaTokenSuccessSuccessful ReCaptcha solving by token
onRecaptchaTokenErrorError when solving ReCaptcha by token

GeeTest

EventDescription
onGeeTestTokenStartStart of the GeeTest solving by token
onGeeTestTokenSuccessSuccessful solution of GeeTest by token
onGeeTestTokenErrorError when solving GeeTest by token

Turnstile

EventDescription
onTurnstileTokenStartStart of the Turnstile solving by token
onTurnstileTokenSuccessSuccessful solution of Turnstile by token
onTurnstileTokenErrorError when solving Turnstile by token

Image captcha

EventDescription
onImageTokenStartStart of the Image captcha solving by token
onImageTokenSuccessSuccessful solving Image captcha by token
onImageTokenErrorError when solving Image captcha by token