Summary
Add a new API endpoint to ConfirmEdit that:
- Receives an hCaptcha token and block ID from the client
- Verifies the token via HCaptcha::passCaptcha()
- Retrieves the risk score via HCaptcha::retrieveSessionScore(), and
- Fires a hook handled by MediaWiki-extensions-WikimediaEvents to record the score.
Acceptance Criteria
- A new endpoint is registered under ConfirmEdit that will retrieve the risk score
- The endpoint receives two required parameters riskScoreToken and blockIds
- The new endpoint uses the existing functionality in the HCaptcha class to verify the token (the class may need to be refactored to support that)
- The endpoint then fires a hook carrying the risk score, so that it can be consumed by MediaWiki-extensions-WikimediaEvents to record the score.