Skip to content

Commit 9ee6ac6

Browse files
authored
Update README.md
1 parent f42b154 commit 9ee6ac6

File tree

1 file changed

+20
-1
lines changed

1 file changed

+20
-1
lines changed

README.md

Lines changed: 20 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -125,7 +125,26 @@ You can also customise your own template under googlerecaptchav3 folder.
125125
```
126126

127127
- $actionName: if its NULL, the package won't verify action with google response.
128-
128+
129+
#### Facade Usage
130+
131+
You can also directly use registered service by calling the following method.
132+
- setAction() is optional only if you want to verify if the action is matched.
133+
- verifyResponse() which accepts the token value from your form. This return Google reCAPTCHA Response object.
134+
135+
``` php
136+
GoogleReCaptchaV3::setAction($action)->verifyResponse($value)
137+
```
138+
139+
Example Usage
140+
141+
``` php
142+
GoogleReCaptchaV3::verifyResponse($value)->getMessage();
143+
GoogleReCaptchaV3::verifyResponse($value)->isSuccess();
144+
GoogleReCaptchaV3::verifyResponse($value)->toArray();
145+
GoogleReCaptchaV3::setAction($action)->verifyResponse($value)->isSuccess);
146+
```
147+
129148
#### Facade Class
130149

131150

0 commit comments

Comments
 (0)