Utiliser les fonctionnalités reCAPTCHA après la migration
Restez organisé à l'aide des collections
Enregistrez et classez les contenus selon vos préférences.
Cette page explique comment modifier une intégration reCAPTCHA existante pour utiliser les fonctionnalités de reCAPTCHA, telles que l'authentification multifacteur (MFA) et la protection des mots de passe après la migration à partir de reCAPTCHA Classic. La modification d'une intégration reCAPTCHA existante implique l'instrumentation des pages Web et la migration des appels de backend.
Pour utiliser les fonctionnalités de reCAPTCHA, vous devez migrer vos appels de backend vers les nouveaux points de terminaison et configurer l'authentification:
Remplacez les appels de backend à https://www.google.com/recaptcha/api/siteverify par des appels équivalents à recaptchaenterprise.googleapis.com. Pour obtenir l'URL complète et le format de données POST, consultez Créer une évaluation pour votre site Web.
Configurez l'authentification auprès de reCAPTCHA.
La méthode d'authentification que vous choisissez dépend de l'environnement dans lequel reCAPTCHA est configuré. Le tableau suivant vous aide à choisir la méthode d'authentification appropriée et l'interface compatible pour configurer l'authentification:
Sauf indication contraire, le contenu de cette page est régi par une licence Creative Commons Attribution 4.0, et les échantillons de code sont régis par une licence Apache 2.0. Pour en savoir plus, consultez les Règles du site Google Developers. Java est une marque déposée d'Oracle et/ou de ses sociétés affiliées.
Dernière mise à jour le 2025/09/04 (UTC).
[[["Facile à comprendre","easyToUnderstand","thumb-up"],["J'ai pu résoudre mon problème","solvedMyProblem","thumb-up"],["Autre","otherUp","thumb-up"]],[["Difficile à comprendre","hardToUnderstand","thumb-down"],["Informations ou exemple de code incorrects","incorrectInformationOrSampleCode","thumb-down"],["Il n'y a pas l'information/les exemples dont j'ai besoin","missingTheInformationSamplesINeed","thumb-down"],["Problème de traduction","translationIssue","thumb-down"],["Autre","otherDown","thumb-down"]],["Dernière mise à jour le 2025/09/04 (UTC)."],[],[],null,["# Use reCAPTCHA features after migration\n\nThis page explains how to modify an existing reCAPTCHA integration to use\nreCAPTCHA features, such as Multi-factor\nauthentication (MFA) and Password defense after migrating from\nreCAPTCHA Classic. Modifying an existing reCAPTCHA\nintegration involves instrumenting the web pages and migrating the backend calls.\n\nBefore you begin\n----------------\n\n[Migrate to reCAPTCHA](/recaptcha/docs/migrate-recaptcha).\n\nInstrument the web pages\n------------------------\n\nTo instrument the web pages with the reCAPTCHA scripts and\ncalls, do the following:\n\n1. Verify that you have the following script included in your web pages: `https://www.google.com/recaptcha/api.js`.\n2. In your web pages, replace `https://www.google.com/recaptcha/api.js`\n with `https://www.google.com/recaptcha/enterprise.js`.\n\n | **Note:** If your web pages have the `https://www.recaptcha.net/recaptcha/api.js` script, then replace it with `https://www.recaptcha.net/recaptcha/enterprise.js`.\n3. If you programmatically invoke the API, then replace the following calls:\n\n - `grecaptcha.execute()` -\\\u003e `grecaptcha.enterprise.execute()`\n - `grecaptcha.getResponse()` -\\\u003e `grecaptcha.enterprise.getResponse()`\n - `grecaptcha.ready()` -\\\u003e `grecaptcha.enterprise.ready()`\n - `grecaptcha.render()` -\\\u003e `grecaptcha.enterprise.render()`\n - `grecaptcha.reset()` -\\\u003e `grecaptcha.enterprise.reset()`\n\nMigrate the backend calls\n-------------------------\n\nTo use reCAPTCHA features, you must migrate your backend calls to\nthe new endpoints and set up authentication:\n\n1. Replace backend calls to `https://www.google.com/recaptcha/api/siteverify`\n with equivalent calls to `recaptchaenterprise.googleapis.com`. For the complete\n URL and the POST data format, see [Create an assessment for your website](/recaptcha/docs/create-assessment-website).\n\n2.\n\n Set up authentication to reCAPTCHA.\n\n The authentication method you choose depends on the environment where\n reCAPTCHA is set up. The following table helps you choose the\n appropriate authentication method and the supported interface to set up\n authentication:\n\n \u003cbr /\u003e\n\nWhat's next\n-----------\n\n- [Create an assessment for your website](/recaptcha/docs/create-assessment-website)"]]