You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+46-12Lines changed: 46 additions & 12 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,6 +1,6 @@
1
1
# friendly-captcha-php
2
2
3
-
A PHP client for the [Friendly Captcha](https://friendlycaptcha.com) service. This client allows for easy integration and verification of captcha responses with the Friendly Captcha API.
3
+
A PHP client for the [Friendly Captcha](https://friendlycaptcha.com) service. This client makes it easy to connect to the Friendly Captcha API for captcha verification or [Risk Intelligence](https://developer.friendlycaptcha.com/docs/v2/risk-intelligence/) retrieval.
4
4
5
5
> Note, this is for [Friendly Captcha v2](https://developer.friendlycaptcha.com) only.
// You can also specify which endpoint to use, for example `"global"` or `"eu"`.
28
-
// $config->setEndpoint("eu")
32
+
// $config->setApiEndpoint("eu")
29
33
30
34
$captchaClient = new Client($config)
31
35
```
32
36
33
-
Then use it in the endpoint you want to protect
37
+
### Verifying a Captcha Response
34
38
35
39
```php
36
40
function handleLoginRequest() {
@@ -61,6 +65,38 @@ function handleLoginRequest() {
61
65
}
62
66
```
63
67
68
+
### Retrieving Risk Intelligence
69
+
70
+
You can retrieve [Risk Intelligence](https://developer.friendlycaptcha.com/docs/v2/risk-intelligence/) data using a token. This data provides detailed information about the risk profile of a request, including network data, geolocation, browser details, and risk scores.
Then follow the steps above starting with [**Install Composer**](#install-composer). You can run `./friendly-captcha-sdk-testserver serve` outside the Docker container.
158
+
125
159
### Some features you can't use to be compatible with PHP 7.1
Copy file name to clipboardExpand all lines: examples/form/README.md
+2-2Lines changed: 2 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,6 +1,6 @@
1
1
# form
2
2
3
-
Example of using the Friendly Captcha SDK for PHP.
3
+
Example of using the Friendly Captcha SDK for PHP. It displays a form with a captcha and verifies the captcha response on the back-end. If the application has [**Risk Intelligence**](https://developer.friendlycaptcha.com/docs/v2/risk-intelligence/) enabled, it will also generate a token and use it to retrieve the Risk Intelligence data.
0 commit comments