{"id":13563067,"url":"https://github.com/dpapathanasiou/go-recaptcha","last_synced_at":"2025-07-16T18:34:24.149Z","repository":{"id":4174930,"uuid":"5291159","full_name":"dpapathanasiou/go-recaptcha","owner":"dpapathanasiou","description":"A package for handling reCaptcha (http://www.google.com/recaptcha) form submissions in Go (http://golang.org/).","archived":false,"fork":false,"pushed_at":"2020-04-06T08:18:43.000Z","size":25,"stargazers_count":120,"open_issues_count":4,"forks_count":47,"subscribers_count":6,"default_branch":"master","last_synced_at":"2025-05-20T05:02:13.397Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/dpapathanasiou.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2012-08-03T22:26:03.000Z","updated_at":"2025-05-07T16:27:31.000Z","dependencies_parsed_at":"2022-08-20T14:21:22.752Z","dependency_job_id":null,"html_url":"https://github.com/dpapathanasiou/go-recaptcha","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/dpapathanasiou/go-recaptcha","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dpapathanasiou%2Fgo-recaptcha","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dpapathanasiou%2Fgo-recaptcha/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dpapathanasiou%2Fgo-recaptcha/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dpapathanasiou%2Fgo-recaptcha/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/dpapathanasiou","download_url":"https://codeload.github.com/dpapathanasiou/go-recaptcha/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dpapathanasiou%2Fgo-recaptcha/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":265530896,"owners_count":23783148,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-08-01T13:01:14.822Z","updated_at":"2025-07-16T18:34:24.120Z","avatar_url":"https://github.com/dpapathanasiou.png","language":"Go","funding_links":[],"categories":["Go"],"sub_categories":[],"readme":"go-recaptcha\n============\n\nhttps://godoc.org/github.com/dpapathanasiou/go-recaptcha\n\nAbout\n-----\n\nThis package handles [reCaptcha](https://www.google.com/recaptcha) (API versions [2](https://developers.google.com/recaptcha/intro) and [3](https://developers.google.com/recaptcha/docs/v3)) form submissions in [Go](http://golang.org/).\n\nUsage\n-----\n\nInstall the package in your environment:\n\n```\ngo get github.com/dpapathanasiou/go-recaptcha\n```\n\nTo use it within your own code, import \u003ctt\u003egithub.com/dpapathanasiou/go-recaptcha\u003c/tt\u003e and call:\n\n```\nrecaptcha.Init (recaptchaPrivateKey)\n```\n\nonce, to set the reCaptcha private key for your domain, then:\n\n```\nrecaptcha.Confirm (clientIpAddress, recaptchaResponse)\n```\n\n### [reCAPTCHA v2](https://developers.google.com/recaptcha/intro)\nFor each reCaptcha form input you need to check, using the values obtained by reading the form's POST parameters (the \u003ctt\u003erecaptchaResponse\u003c/tt\u003e in the above corresponds to the value of \u003ctt\u003eg-recaptcha-response\u003c/tt\u003e sent by the reCaptcha server.)\n\nThe recaptcha.Confirm() function returns either true (i.e., the captcha was completed correctly) or false, along with any errors (from the HTTP io read or the attempt to unmarshal the JSON reply).\n\n### [reCAPTCHA v3](https://developers.google.com/recaptcha/docs/v3)\n\nVersion 3 works differently: instead of interrupting page visitors with a prompt, it runs in the background, computing a score.\n\nThis repo has been updated to handle the [score and action in the response](recaptcha.go#L20), but the usage example is still in terms of version 2.\n\nUsage Example\n-------------\n\nIncluded with this repo is [example.go](example/example.go), a simple HTTP server which creates the reCaptcha form and tests the input.\n\nSee the [instructions](example/README.md) for running the example for more details.\n\n## Donate\n\nIf you find this work useful, please consider making a donation:\n\n\u003ca href=\"bitcoin:14TM4ADKJbaGEi8Qr8dh4KfPBQmjTshkZ2\"\u003eBitcoin Donate\u003c/a\u003e `14TM4ADKJbaGEi8Qr8dh4KfPBQmjTshkZ2`\n\n![QR code](https://bitref.com/qr.php?data=14TM4ADKJbaGEi8Qr8dh4KfPBQmjTshkZ2)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdpapathanasiou%2Fgo-recaptcha","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdpapathanasiou%2Fgo-recaptcha","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdpapathanasiou%2Fgo-recaptcha/lists"}