blob: aba86c82a64fc082d70d707476062d61321496b8 [file] [log] [blame]
yoshi-code-botc2cd3262021-05-16 02:16:04 -07001<html><body>
2<style>
3
4body, h1, h2, h3, div, span, p, pre, a {
5 margin: 0;
6 padding: 0;
7 border: 0;
8 font-weight: inherit;
9 font-style: inherit;
10 font-size: 100%;
11 font-family: inherit;
12 vertical-align: baseline;
13}
14
15body {
16 font-size: 13px;
17 padding: 1em;
18}
19
20h1 {
21 font-size: 26px;
22 margin-bottom: 1em;
23}
24
25h2 {
26 font-size: 24px;
27 margin-bottom: 1em;
28}
29
30h3 {
31 font-size: 20px;
32 margin-bottom: 1em;
33 margin-top: 1em;
34}
35
36pre, code {
37 line-height: 1.5;
38 font-family: Monaco, 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Lucida Console', monospace;
39}
40
41pre {
42 margin-top: 0.5em;
43}
44
45h1, h2, h3, p {
46 font-family: Arial, sans serif;
47}
48
49h1, h2, h3 {
50 border-bottom: solid #CCC 1px;
51}
52
53.toc_element {
54 margin-top: 0.5em;
55}
56
57.firstline {
58 margin-left: 2 em;
59}
60
61.method {
62 margin-top: 1em;
63 border: solid 1px #CCC;
64 padding: 1em;
65 background: #EEE;
66}
67
68.details {
69 font-weight: bold;
70 font-size: 14px;
71}
72
73</style>
74
75<h1><a href="recaptchaenterprise_v1.html">reCAPTCHA Enterprise API</a> . <a href="recaptchaenterprise_v1.projects.html">projects</a> . <a href="recaptchaenterprise_v1.projects.keys.html">keys</a></h1>
76<h2>Instance Methods</h2>
77<p class="toc_element">
78 <code><a href="#close">close()</a></code></p>
79<p class="firstline">Close httplib2 connections.</p>
80<p class="toc_element">
81 <code><a href="#create">create(parent, body=None, x__xgafv=None)</a></code></p>
82<p class="firstline">Creates a new reCAPTCHA Enterprise key.</p>
83<p class="toc_element">
84 <code><a href="#delete">delete(name, x__xgafv=None)</a></code></p>
85<p class="firstline">Deletes the specified key.</p>
86<p class="toc_element">
87 <code><a href="#get">get(name, x__xgafv=None)</a></code></p>
88<p class="firstline">Returns the specified key.</p>
89<p class="toc_element">
90 <code><a href="#getMetrics">getMetrics(name, x__xgafv=None)</a></code></p>
91<p class="firstline">Get some aggregated metrics for a Key. This data can be used to build dashboards.</p>
92<p class="toc_element">
93 <code><a href="#list">list(parent, pageSize=None, pageToken=None, x__xgafv=None)</a></code></p>
94<p class="firstline">Returns the list of all keys that belong to a project.</p>
95<p class="toc_element">
96 <code><a href="#list_next">list_next(previous_request, previous_response)</a></code></p>
97<p class="firstline">Retrieves the next page of results.</p>
98<p class="toc_element">
99 <code><a href="#migrate">migrate(name, body=None, x__xgafv=None)</a></code></p>
yoshi-code-bot7700bbf2021-05-20 04:44:03 -0700100<p class="firstline">Migrates an existing key from reCAPTCHA to reCAPTCHA Enterprise. Once a key is migrated, it can be used from either product. SiteVerify requests are billed as CreateAssessment calls. You must be authenticated as one of the current owners of the reCAPTCHA Site Key, and your user must have the reCAPTCHA Enterprise Admin IAM role in the destination project.</p>
yoshi-code-botc2cd3262021-05-16 02:16:04 -0700101<p class="toc_element">
102 <code><a href="#patch">patch(name, body=None, updateMask=None, x__xgafv=None)</a></code></p>
103<p class="firstline">Updates the specified key.</p>
104<h3>Method Details</h3>
105<div class="method">
106 <code class="details" id="close">close()</code>
107 <pre>Close httplib2 connections.</pre>
108</div>
109
110<div class="method">
111 <code class="details" id="create">create(parent, body=None, x__xgafv=None)</code>
112 <pre>Creates a new reCAPTCHA Enterprise key.
113
114Args:
115 parent: string, Required. The name of the project in which the key will be created, in the format &quot;projects/{project}&quot;. (required)
116 body: object, The request body.
117 The object takes the form of:
118
119{ # A key used to identify and configure applications (web and/or mobile) that use reCAPTCHA Enterprise.
120 &quot;androidSettings&quot;: { # Settings specific to keys that can be used by Android apps. # Settings for keys that can be used by Android apps.
yoshi-code-bota41c7b92021-11-02 00:26:17 -0700121 &quot;allowAllPackageNames&quot;: True or False, # If set to true, allowed_package_names are not enforced.
yoshi-code-botc2cd3262021-05-16 02:16:04 -0700122 &quot;allowedPackageNames&quot;: [ # Android package names of apps allowed to use the key. Example: &#x27;com.companyname.appname&#x27;
123 &quot;A String&quot;,
124 ],
125 },
126 &quot;createTime&quot;: &quot;A String&quot;, # The timestamp corresponding to the creation of this Key.
127 &quot;displayName&quot;: &quot;A String&quot;, # Human-readable display name of this key. Modifiable by user.
128 &quot;iosSettings&quot;: { # Settings specific to keys that can be used by iOS apps. # Settings for keys that can be used by iOS apps.
yoshi-code-bota41c7b92021-11-02 00:26:17 -0700129 &quot;allowAllBundleIds&quot;: True or False, # If set to true, allowed_bundle_ids are not enforced.
yoshi-code-botc2cd3262021-05-16 02:16:04 -0700130 &quot;allowedBundleIds&quot;: [ # iOS bundle ids of apps allowed to use the key. Example: &#x27;com.companyname.productname.appname&#x27;
131 &quot;A String&quot;,
132 ],
133 },
134 &quot;labels&quot;: { # See Creating and managing labels.
135 &quot;a_key&quot;: &quot;A String&quot;,
136 },
137 &quot;name&quot;: &quot;A String&quot;, # The resource name for the Key in the format &quot;projects/{project}/keys/{key}&quot;.
138 &quot;testingOptions&quot;: { # Options for user acceptance testing. # Options for user acceptance testing.
139 &quot;testingChallenge&quot;: &quot;A String&quot;, # For challenge-based keys only (CHECKBOX, INVISIBLE), all challenge requests for this site will return nocaptcha if NOCAPTCHA, or an unsolvable challenge if CHALLENGE.
140 &quot;testingScore&quot;: 3.14, # All assessments for this Key will return this score. Must be between 0 (likely not legitimate) and 1 (likely legitimate) inclusive.
141 },
142 &quot;webSettings&quot;: { # Settings specific to keys that can be used by websites. # Settings for keys that can be used by websites.
143 &quot;allowAllDomains&quot;: True or False, # If set to true, it means allowed_domains will not be enforced.
yoshi-code-bota41c7b92021-11-02 00:26:17 -0700144 &quot;allowAmpTraffic&quot;: True or False, # If set to true, the key can be used on AMP (Accelerated Mobile Pages) websites. This is supported only for the SCORE integration type.
yoshi-code-botc2cd3262021-05-16 02:16:04 -0700145 &quot;allowedDomains&quot;: [ # Domains or subdomains of websites allowed to use the key. All subdomains of an allowed domain are automatically allowed. A valid domain requires a host and must not include any path, port, query or fragment. Examples: &#x27;example.com&#x27; or &#x27;subdomain.example.com&#x27;
146 &quot;A String&quot;,
147 ],
148 &quot;challengeSecurityPreference&quot;: &quot;A String&quot;, # Settings for the frequency and difficulty at which this key triggers captcha challenges. This should only be specified for IntegrationTypes CHECKBOX and INVISIBLE.
149 &quot;integrationType&quot;: &quot;A String&quot;, # Required. Describes how this key is integrated with the website.
150 },
151}
152
153 x__xgafv: string, V1 error format.
154 Allowed values
155 1 - v1 error format
156 2 - v2 error format
157
158Returns:
159 An object of the form:
160
161 { # A key used to identify and configure applications (web and/or mobile) that use reCAPTCHA Enterprise.
162 &quot;androidSettings&quot;: { # Settings specific to keys that can be used by Android apps. # Settings for keys that can be used by Android apps.
yoshi-code-bota41c7b92021-11-02 00:26:17 -0700163 &quot;allowAllPackageNames&quot;: True or False, # If set to true, allowed_package_names are not enforced.
yoshi-code-botc2cd3262021-05-16 02:16:04 -0700164 &quot;allowedPackageNames&quot;: [ # Android package names of apps allowed to use the key. Example: &#x27;com.companyname.appname&#x27;
165 &quot;A String&quot;,
166 ],
167 },
168 &quot;createTime&quot;: &quot;A String&quot;, # The timestamp corresponding to the creation of this Key.
169 &quot;displayName&quot;: &quot;A String&quot;, # Human-readable display name of this key. Modifiable by user.
170 &quot;iosSettings&quot;: { # Settings specific to keys that can be used by iOS apps. # Settings for keys that can be used by iOS apps.
yoshi-code-bota41c7b92021-11-02 00:26:17 -0700171 &quot;allowAllBundleIds&quot;: True or False, # If set to true, allowed_bundle_ids are not enforced.
yoshi-code-botc2cd3262021-05-16 02:16:04 -0700172 &quot;allowedBundleIds&quot;: [ # iOS bundle ids of apps allowed to use the key. Example: &#x27;com.companyname.productname.appname&#x27;
173 &quot;A String&quot;,
174 ],
175 },
176 &quot;labels&quot;: { # See Creating and managing labels.
177 &quot;a_key&quot;: &quot;A String&quot;,
178 },
179 &quot;name&quot;: &quot;A String&quot;, # The resource name for the Key in the format &quot;projects/{project}/keys/{key}&quot;.
180 &quot;testingOptions&quot;: { # Options for user acceptance testing. # Options for user acceptance testing.
181 &quot;testingChallenge&quot;: &quot;A String&quot;, # For challenge-based keys only (CHECKBOX, INVISIBLE), all challenge requests for this site will return nocaptcha if NOCAPTCHA, or an unsolvable challenge if CHALLENGE.
182 &quot;testingScore&quot;: 3.14, # All assessments for this Key will return this score. Must be between 0 (likely not legitimate) and 1 (likely legitimate) inclusive.
183 },
184 &quot;webSettings&quot;: { # Settings specific to keys that can be used by websites. # Settings for keys that can be used by websites.
185 &quot;allowAllDomains&quot;: True or False, # If set to true, it means allowed_domains will not be enforced.
yoshi-code-bota41c7b92021-11-02 00:26:17 -0700186 &quot;allowAmpTraffic&quot;: True or False, # If set to true, the key can be used on AMP (Accelerated Mobile Pages) websites. This is supported only for the SCORE integration type.
yoshi-code-botc2cd3262021-05-16 02:16:04 -0700187 &quot;allowedDomains&quot;: [ # Domains or subdomains of websites allowed to use the key. All subdomains of an allowed domain are automatically allowed. A valid domain requires a host and must not include any path, port, query or fragment. Examples: &#x27;example.com&#x27; or &#x27;subdomain.example.com&#x27;
188 &quot;A String&quot;,
189 ],
190 &quot;challengeSecurityPreference&quot;: &quot;A String&quot;, # Settings for the frequency and difficulty at which this key triggers captcha challenges. This should only be specified for IntegrationTypes CHECKBOX and INVISIBLE.
191 &quot;integrationType&quot;: &quot;A String&quot;, # Required. Describes how this key is integrated with the website.
192 },
193}</pre>
194</div>
195
196<div class="method">
197 <code class="details" id="delete">delete(name, x__xgafv=None)</code>
198 <pre>Deletes the specified key.
199
200Args:
201 name: string, Required. The name of the key to be deleted, in the format &quot;projects/{project}/keys/{key}&quot;. (required)
202 x__xgafv: string, V1 error format.
203 Allowed values
204 1 - v1 error format
205 2 - v2 error format
206
207Returns:
208 An object of the form:
209
210 { # A generic empty message that you can re-use to avoid defining duplicated empty messages in your APIs. A typical example is to use it as the request or the response type of an API method. For instance: service Foo { rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty); } The JSON representation for `Empty` is empty JSON object `{}`.
211}</pre>
212</div>
213
214<div class="method">
215 <code class="details" id="get">get(name, x__xgafv=None)</code>
216 <pre>Returns the specified key.
217
218Args:
219 name: string, Required. The name of the requested key, in the format &quot;projects/{project}/keys/{key}&quot;. (required)
220 x__xgafv: string, V1 error format.
221 Allowed values
222 1 - v1 error format
223 2 - v2 error format
224
225Returns:
226 An object of the form:
227
228 { # A key used to identify and configure applications (web and/or mobile) that use reCAPTCHA Enterprise.
229 &quot;androidSettings&quot;: { # Settings specific to keys that can be used by Android apps. # Settings for keys that can be used by Android apps.
yoshi-code-bota41c7b92021-11-02 00:26:17 -0700230 &quot;allowAllPackageNames&quot;: True or False, # If set to true, allowed_package_names are not enforced.
yoshi-code-botc2cd3262021-05-16 02:16:04 -0700231 &quot;allowedPackageNames&quot;: [ # Android package names of apps allowed to use the key. Example: &#x27;com.companyname.appname&#x27;
232 &quot;A String&quot;,
233 ],
234 },
235 &quot;createTime&quot;: &quot;A String&quot;, # The timestamp corresponding to the creation of this Key.
236 &quot;displayName&quot;: &quot;A String&quot;, # Human-readable display name of this key. Modifiable by user.
237 &quot;iosSettings&quot;: { # Settings specific to keys that can be used by iOS apps. # Settings for keys that can be used by iOS apps.
yoshi-code-bota41c7b92021-11-02 00:26:17 -0700238 &quot;allowAllBundleIds&quot;: True or False, # If set to true, allowed_bundle_ids are not enforced.
yoshi-code-botc2cd3262021-05-16 02:16:04 -0700239 &quot;allowedBundleIds&quot;: [ # iOS bundle ids of apps allowed to use the key. Example: &#x27;com.companyname.productname.appname&#x27;
240 &quot;A String&quot;,
241 ],
242 },
243 &quot;labels&quot;: { # See Creating and managing labels.
244 &quot;a_key&quot;: &quot;A String&quot;,
245 },
246 &quot;name&quot;: &quot;A String&quot;, # The resource name for the Key in the format &quot;projects/{project}/keys/{key}&quot;.
247 &quot;testingOptions&quot;: { # Options for user acceptance testing. # Options for user acceptance testing.
248 &quot;testingChallenge&quot;: &quot;A String&quot;, # For challenge-based keys only (CHECKBOX, INVISIBLE), all challenge requests for this site will return nocaptcha if NOCAPTCHA, or an unsolvable challenge if CHALLENGE.
249 &quot;testingScore&quot;: 3.14, # All assessments for this Key will return this score. Must be between 0 (likely not legitimate) and 1 (likely legitimate) inclusive.
250 },
251 &quot;webSettings&quot;: { # Settings specific to keys that can be used by websites. # Settings for keys that can be used by websites.
252 &quot;allowAllDomains&quot;: True or False, # If set to true, it means allowed_domains will not be enforced.
yoshi-code-bota41c7b92021-11-02 00:26:17 -0700253 &quot;allowAmpTraffic&quot;: True or False, # If set to true, the key can be used on AMP (Accelerated Mobile Pages) websites. This is supported only for the SCORE integration type.
yoshi-code-botc2cd3262021-05-16 02:16:04 -0700254 &quot;allowedDomains&quot;: [ # Domains or subdomains of websites allowed to use the key. All subdomains of an allowed domain are automatically allowed. A valid domain requires a host and must not include any path, port, query or fragment. Examples: &#x27;example.com&#x27; or &#x27;subdomain.example.com&#x27;
255 &quot;A String&quot;,
256 ],
257 &quot;challengeSecurityPreference&quot;: &quot;A String&quot;, # Settings for the frequency and difficulty at which this key triggers captcha challenges. This should only be specified for IntegrationTypes CHECKBOX and INVISIBLE.
258 &quot;integrationType&quot;: &quot;A String&quot;, # Required. Describes how this key is integrated with the website.
259 },
260}</pre>
261</div>
262
263<div class="method">
264 <code class="details" id="getMetrics">getMetrics(name, x__xgafv=None)</code>
265 <pre>Get some aggregated metrics for a Key. This data can be used to build dashboards.
266
267Args:
268 name: string, Required. The name of the requested metrics, in the format &quot;projects/{project}/keys/{key}/metrics&quot;. (required)
269 x__xgafv: string, V1 error format.
270 Allowed values
271 1 - v1 error format
272 2 - v2 error format
273
274Returns:
275 An object of the form:
276
277 { # Metrics for a single Key.
278 &quot;challengeMetrics&quot;: [ # Metrics will be continuous and in order by dates, and in the granularity of day. Only challenge-based keys (CHECKBOX, INVISIBLE), will have challenge-based data.
279 { # Metrics related to challenges.
280 &quot;failedCount&quot;: &quot;A String&quot;, # Count of submitted challenge solutions that were incorrect or otherwise deemed suspicious such that a subsequent challenge was triggered.
281 &quot;nocaptchaCount&quot;: &quot;A String&quot;, # Count of nocaptchas (successful verification without a challenge) issued.
282 &quot;pageloadCount&quot;: &quot;A String&quot;, # Count of reCAPTCHA checkboxes or badges rendered. This is mostly equivalent to a count of pageloads for pages that include reCAPTCHA.
283 &quot;passedCount&quot;: &quot;A String&quot;, # Count of nocaptchas (successful verification without a challenge) plus submitted challenge solutions that were correct and resulted in verification.
284 },
285 ],
yoshi-code-bot3e4b5db2021-08-10 00:22:29 -0700286 &quot;name&quot;: &quot;A String&quot;, # Output only. The name of the metrics, in the format &quot;projects/{project}/keys/{key}/metrics&quot;.
yoshi-code-botc2cd3262021-05-16 02:16:04 -0700287 &quot;scoreMetrics&quot;: [ # Metrics will be continuous and in order by dates, and in the granularity of day. All Key types should have score-based data.
288 { # Metrics related to scoring.
289 &quot;actionMetrics&quot;: { # Action-based metrics. The map key is the action name which specified by the site owners at time of the &quot;execute&quot; client-side call. Populated only for SCORE keys.
290 &quot;a_key&quot;: { # Score distribution.
291 &quot;scoreBuckets&quot;: { # Map key is score value multiplied by 100. The scores are discrete values between [0, 1]. The maximum number of buckets is on order of a few dozen, but typically much lower (ie. 10).
292 &quot;a_key&quot;: &quot;A String&quot;,
293 },
294 },
295 },
296 &quot;overallMetrics&quot;: { # Score distribution. # Aggregated score metrics for all traffic.
297 &quot;scoreBuckets&quot;: { # Map key is score value multiplied by 100. The scores are discrete values between [0, 1]. The maximum number of buckets is on order of a few dozen, but typically much lower (ie. 10).
298 &quot;a_key&quot;: &quot;A String&quot;,
299 },
300 },
301 },
302 ],
303 &quot;startTime&quot;: &quot;A String&quot;, # Inclusive start time aligned to a day (UTC).
304}</pre>
305</div>
306
307<div class="method">
308 <code class="details" id="list">list(parent, pageSize=None, pageToken=None, x__xgafv=None)</code>
309 <pre>Returns the list of all keys that belong to a project.
310
311Args:
312 parent: string, Required. The name of the project that contains the keys that will be listed, in the format &quot;projects/{project}&quot;. (required)
313 pageSize: integer, Optional. The maximum number of keys to return. Default is 10. Max limit is 1000.
314 pageToken: string, Optional. The next_page_token value returned from a previous. ListKeysRequest, if any.
315 x__xgafv: string, V1 error format.
316 Allowed values
317 1 - v1 error format
318 2 - v2 error format
319
320Returns:
321 An object of the form:
322
323 { # Response to request to list keys in a project.
324 &quot;keys&quot;: [ # Key details.
325 { # A key used to identify and configure applications (web and/or mobile) that use reCAPTCHA Enterprise.
326 &quot;androidSettings&quot;: { # Settings specific to keys that can be used by Android apps. # Settings for keys that can be used by Android apps.
yoshi-code-bota41c7b92021-11-02 00:26:17 -0700327 &quot;allowAllPackageNames&quot;: True or False, # If set to true, allowed_package_names are not enforced.
yoshi-code-botc2cd3262021-05-16 02:16:04 -0700328 &quot;allowedPackageNames&quot;: [ # Android package names of apps allowed to use the key. Example: &#x27;com.companyname.appname&#x27;
329 &quot;A String&quot;,
330 ],
331 },
332 &quot;createTime&quot;: &quot;A String&quot;, # The timestamp corresponding to the creation of this Key.
333 &quot;displayName&quot;: &quot;A String&quot;, # Human-readable display name of this key. Modifiable by user.
334 &quot;iosSettings&quot;: { # Settings specific to keys that can be used by iOS apps. # Settings for keys that can be used by iOS apps.
yoshi-code-bota41c7b92021-11-02 00:26:17 -0700335 &quot;allowAllBundleIds&quot;: True or False, # If set to true, allowed_bundle_ids are not enforced.
yoshi-code-botc2cd3262021-05-16 02:16:04 -0700336 &quot;allowedBundleIds&quot;: [ # iOS bundle ids of apps allowed to use the key. Example: &#x27;com.companyname.productname.appname&#x27;
337 &quot;A String&quot;,
338 ],
339 },
340 &quot;labels&quot;: { # See Creating and managing labels.
341 &quot;a_key&quot;: &quot;A String&quot;,
342 },
343 &quot;name&quot;: &quot;A String&quot;, # The resource name for the Key in the format &quot;projects/{project}/keys/{key}&quot;.
344 &quot;testingOptions&quot;: { # Options for user acceptance testing. # Options for user acceptance testing.
345 &quot;testingChallenge&quot;: &quot;A String&quot;, # For challenge-based keys only (CHECKBOX, INVISIBLE), all challenge requests for this site will return nocaptcha if NOCAPTCHA, or an unsolvable challenge if CHALLENGE.
346 &quot;testingScore&quot;: 3.14, # All assessments for this Key will return this score. Must be between 0 (likely not legitimate) and 1 (likely legitimate) inclusive.
347 },
348 &quot;webSettings&quot;: { # Settings specific to keys that can be used by websites. # Settings for keys that can be used by websites.
349 &quot;allowAllDomains&quot;: True or False, # If set to true, it means allowed_domains will not be enforced.
yoshi-code-bota41c7b92021-11-02 00:26:17 -0700350 &quot;allowAmpTraffic&quot;: True or False, # If set to true, the key can be used on AMP (Accelerated Mobile Pages) websites. This is supported only for the SCORE integration type.
yoshi-code-botc2cd3262021-05-16 02:16:04 -0700351 &quot;allowedDomains&quot;: [ # Domains or subdomains of websites allowed to use the key. All subdomains of an allowed domain are automatically allowed. A valid domain requires a host and must not include any path, port, query or fragment. Examples: &#x27;example.com&#x27; or &#x27;subdomain.example.com&#x27;
352 &quot;A String&quot;,
353 ],
354 &quot;challengeSecurityPreference&quot;: &quot;A String&quot;, # Settings for the frequency and difficulty at which this key triggers captcha challenges. This should only be specified for IntegrationTypes CHECKBOX and INVISIBLE.
355 &quot;integrationType&quot;: &quot;A String&quot;, # Required. Describes how this key is integrated with the website.
356 },
357 },
358 ],
359 &quot;nextPageToken&quot;: &quot;A String&quot;, # Token to retrieve the next page of results. It is set to empty if no keys remain in results.
360}</pre>
361</div>
362
363<div class="method">
364 <code class="details" id="list_next">list_next(previous_request, previous_response)</code>
365 <pre>Retrieves the next page of results.
366
367Args:
368 previous_request: The request for the previous page. (required)
369 previous_response: The response from the request for the previous page. (required)
370
371Returns:
372 A request object that you can call &#x27;execute()&#x27; on to request the next
373 page. Returns None if there are no more items in the collection.
374 </pre>
375</div>
376
377<div class="method">
378 <code class="details" id="migrate">migrate(name, body=None, x__xgafv=None)</code>
yoshi-code-bot7700bbf2021-05-20 04:44:03 -0700379 <pre>Migrates an existing key from reCAPTCHA to reCAPTCHA Enterprise. Once a key is migrated, it can be used from either product. SiteVerify requests are billed as CreateAssessment calls. You must be authenticated as one of the current owners of the reCAPTCHA Site Key, and your user must have the reCAPTCHA Enterprise Admin IAM role in the destination project.
yoshi-code-botc2cd3262021-05-16 02:16:04 -0700380
381Args:
382 name: string, Required. The name of the key to be migrated, in the format &quot;projects/{project}/keys/{key}&quot;. (required)
383 body: object, The request body.
384 The object takes the form of:
385
386{ # The migrate key request message.
387}
388
389 x__xgafv: string, V1 error format.
390 Allowed values
391 1 - v1 error format
392 2 - v2 error format
393
394Returns:
395 An object of the form:
396
397 { # A key used to identify and configure applications (web and/or mobile) that use reCAPTCHA Enterprise.
398 &quot;androidSettings&quot;: { # Settings specific to keys that can be used by Android apps. # Settings for keys that can be used by Android apps.
yoshi-code-bota41c7b92021-11-02 00:26:17 -0700399 &quot;allowAllPackageNames&quot;: True or False, # If set to true, allowed_package_names are not enforced.
yoshi-code-botc2cd3262021-05-16 02:16:04 -0700400 &quot;allowedPackageNames&quot;: [ # Android package names of apps allowed to use the key. Example: &#x27;com.companyname.appname&#x27;
401 &quot;A String&quot;,
402 ],
403 },
404 &quot;createTime&quot;: &quot;A String&quot;, # The timestamp corresponding to the creation of this Key.
405 &quot;displayName&quot;: &quot;A String&quot;, # Human-readable display name of this key. Modifiable by user.
406 &quot;iosSettings&quot;: { # Settings specific to keys that can be used by iOS apps. # Settings for keys that can be used by iOS apps.
yoshi-code-bota41c7b92021-11-02 00:26:17 -0700407 &quot;allowAllBundleIds&quot;: True or False, # If set to true, allowed_bundle_ids are not enforced.
yoshi-code-botc2cd3262021-05-16 02:16:04 -0700408 &quot;allowedBundleIds&quot;: [ # iOS bundle ids of apps allowed to use the key. Example: &#x27;com.companyname.productname.appname&#x27;
409 &quot;A String&quot;,
410 ],
411 },
412 &quot;labels&quot;: { # See Creating and managing labels.
413 &quot;a_key&quot;: &quot;A String&quot;,
414 },
415 &quot;name&quot;: &quot;A String&quot;, # The resource name for the Key in the format &quot;projects/{project}/keys/{key}&quot;.
416 &quot;testingOptions&quot;: { # Options for user acceptance testing. # Options for user acceptance testing.
417 &quot;testingChallenge&quot;: &quot;A String&quot;, # For challenge-based keys only (CHECKBOX, INVISIBLE), all challenge requests for this site will return nocaptcha if NOCAPTCHA, or an unsolvable challenge if CHALLENGE.
418 &quot;testingScore&quot;: 3.14, # All assessments for this Key will return this score. Must be between 0 (likely not legitimate) and 1 (likely legitimate) inclusive.
419 },
420 &quot;webSettings&quot;: { # Settings specific to keys that can be used by websites. # Settings for keys that can be used by websites.
421 &quot;allowAllDomains&quot;: True or False, # If set to true, it means allowed_domains will not be enforced.
yoshi-code-bota41c7b92021-11-02 00:26:17 -0700422 &quot;allowAmpTraffic&quot;: True or False, # If set to true, the key can be used on AMP (Accelerated Mobile Pages) websites. This is supported only for the SCORE integration type.
yoshi-code-botc2cd3262021-05-16 02:16:04 -0700423 &quot;allowedDomains&quot;: [ # Domains or subdomains of websites allowed to use the key. All subdomains of an allowed domain are automatically allowed. A valid domain requires a host and must not include any path, port, query or fragment. Examples: &#x27;example.com&#x27; or &#x27;subdomain.example.com&#x27;
424 &quot;A String&quot;,
425 ],
426 &quot;challengeSecurityPreference&quot;: &quot;A String&quot;, # Settings for the frequency and difficulty at which this key triggers captcha challenges. This should only be specified for IntegrationTypes CHECKBOX and INVISIBLE.
427 &quot;integrationType&quot;: &quot;A String&quot;, # Required. Describes how this key is integrated with the website.
428 },
429}</pre>
430</div>
431
432<div class="method">
433 <code class="details" id="patch">patch(name, body=None, updateMask=None, x__xgafv=None)</code>
434 <pre>Updates the specified key.
435
436Args:
437 name: string, The resource name for the Key in the format &quot;projects/{project}/keys/{key}&quot;. (required)
438 body: object, The request body.
439 The object takes the form of:
440
441{ # A key used to identify and configure applications (web and/or mobile) that use reCAPTCHA Enterprise.
442 &quot;androidSettings&quot;: { # Settings specific to keys that can be used by Android apps. # Settings for keys that can be used by Android apps.
yoshi-code-bota41c7b92021-11-02 00:26:17 -0700443 &quot;allowAllPackageNames&quot;: True or False, # If set to true, allowed_package_names are not enforced.
yoshi-code-botc2cd3262021-05-16 02:16:04 -0700444 &quot;allowedPackageNames&quot;: [ # Android package names of apps allowed to use the key. Example: &#x27;com.companyname.appname&#x27;
445 &quot;A String&quot;,
446 ],
447 },
448 &quot;createTime&quot;: &quot;A String&quot;, # The timestamp corresponding to the creation of this Key.
449 &quot;displayName&quot;: &quot;A String&quot;, # Human-readable display name of this key. Modifiable by user.
450 &quot;iosSettings&quot;: { # Settings specific to keys that can be used by iOS apps. # Settings for keys that can be used by iOS apps.
yoshi-code-bota41c7b92021-11-02 00:26:17 -0700451 &quot;allowAllBundleIds&quot;: True or False, # If set to true, allowed_bundle_ids are not enforced.
yoshi-code-botc2cd3262021-05-16 02:16:04 -0700452 &quot;allowedBundleIds&quot;: [ # iOS bundle ids of apps allowed to use the key. Example: &#x27;com.companyname.productname.appname&#x27;
453 &quot;A String&quot;,
454 ],
455 },
456 &quot;labels&quot;: { # See Creating and managing labels.
457 &quot;a_key&quot;: &quot;A String&quot;,
458 },
459 &quot;name&quot;: &quot;A String&quot;, # The resource name for the Key in the format &quot;projects/{project}/keys/{key}&quot;.
460 &quot;testingOptions&quot;: { # Options for user acceptance testing. # Options for user acceptance testing.
461 &quot;testingChallenge&quot;: &quot;A String&quot;, # For challenge-based keys only (CHECKBOX, INVISIBLE), all challenge requests for this site will return nocaptcha if NOCAPTCHA, or an unsolvable challenge if CHALLENGE.
462 &quot;testingScore&quot;: 3.14, # All assessments for this Key will return this score. Must be between 0 (likely not legitimate) and 1 (likely legitimate) inclusive.
463 },
464 &quot;webSettings&quot;: { # Settings specific to keys that can be used by websites. # Settings for keys that can be used by websites.
465 &quot;allowAllDomains&quot;: True or False, # If set to true, it means allowed_domains will not be enforced.
yoshi-code-bota41c7b92021-11-02 00:26:17 -0700466 &quot;allowAmpTraffic&quot;: True or False, # If set to true, the key can be used on AMP (Accelerated Mobile Pages) websites. This is supported only for the SCORE integration type.
yoshi-code-botc2cd3262021-05-16 02:16:04 -0700467 &quot;allowedDomains&quot;: [ # Domains or subdomains of websites allowed to use the key. All subdomains of an allowed domain are automatically allowed. A valid domain requires a host and must not include any path, port, query or fragment. Examples: &#x27;example.com&#x27; or &#x27;subdomain.example.com&#x27;
468 &quot;A String&quot;,
469 ],
470 &quot;challengeSecurityPreference&quot;: &quot;A String&quot;, # Settings for the frequency and difficulty at which this key triggers captcha challenges. This should only be specified for IntegrationTypes CHECKBOX and INVISIBLE.
471 &quot;integrationType&quot;: &quot;A String&quot;, # Required. Describes how this key is integrated with the website.
472 },
473}
474
yoshi-code-bot7700bbf2021-05-20 04:44:03 -0700475 updateMask: string, Optional. The mask to control which fields of the key get updated. If the mask is not present, all fields will be updated.
yoshi-code-botc2cd3262021-05-16 02:16:04 -0700476 x__xgafv: string, V1 error format.
477 Allowed values
478 1 - v1 error format
479 2 - v2 error format
480
481Returns:
482 An object of the form:
483
484 { # A key used to identify and configure applications (web and/or mobile) that use reCAPTCHA Enterprise.
485 &quot;androidSettings&quot;: { # Settings specific to keys that can be used by Android apps. # Settings for keys that can be used by Android apps.
yoshi-code-bota41c7b92021-11-02 00:26:17 -0700486 &quot;allowAllPackageNames&quot;: True or False, # If set to true, allowed_package_names are not enforced.
yoshi-code-botc2cd3262021-05-16 02:16:04 -0700487 &quot;allowedPackageNames&quot;: [ # Android package names of apps allowed to use the key. Example: &#x27;com.companyname.appname&#x27;
488 &quot;A String&quot;,
489 ],
490 },
491 &quot;createTime&quot;: &quot;A String&quot;, # The timestamp corresponding to the creation of this Key.
492 &quot;displayName&quot;: &quot;A String&quot;, # Human-readable display name of this key. Modifiable by user.
493 &quot;iosSettings&quot;: { # Settings specific to keys that can be used by iOS apps. # Settings for keys that can be used by iOS apps.
yoshi-code-bota41c7b92021-11-02 00:26:17 -0700494 &quot;allowAllBundleIds&quot;: True or False, # If set to true, allowed_bundle_ids are not enforced.
yoshi-code-botc2cd3262021-05-16 02:16:04 -0700495 &quot;allowedBundleIds&quot;: [ # iOS bundle ids of apps allowed to use the key. Example: &#x27;com.companyname.productname.appname&#x27;
496 &quot;A String&quot;,
497 ],
498 },
499 &quot;labels&quot;: { # See Creating and managing labels.
500 &quot;a_key&quot;: &quot;A String&quot;,
501 },
502 &quot;name&quot;: &quot;A String&quot;, # The resource name for the Key in the format &quot;projects/{project}/keys/{key}&quot;.
503 &quot;testingOptions&quot;: { # Options for user acceptance testing. # Options for user acceptance testing.
504 &quot;testingChallenge&quot;: &quot;A String&quot;, # For challenge-based keys only (CHECKBOX, INVISIBLE), all challenge requests for this site will return nocaptcha if NOCAPTCHA, or an unsolvable challenge if CHALLENGE.
505 &quot;testingScore&quot;: 3.14, # All assessments for this Key will return this score. Must be between 0 (likely not legitimate) and 1 (likely legitimate) inclusive.
506 },
507 &quot;webSettings&quot;: { # Settings specific to keys that can be used by websites. # Settings for keys that can be used by websites.
508 &quot;allowAllDomains&quot;: True or False, # If set to true, it means allowed_domains will not be enforced.
yoshi-code-bota41c7b92021-11-02 00:26:17 -0700509 &quot;allowAmpTraffic&quot;: True or False, # If set to true, the key can be used on AMP (Accelerated Mobile Pages) websites. This is supported only for the SCORE integration type.
yoshi-code-botc2cd3262021-05-16 02:16:04 -0700510 &quot;allowedDomains&quot;: [ # Domains or subdomains of websites allowed to use the key. All subdomains of an allowed domain are automatically allowed. A valid domain requires a host and must not include any path, port, query or fragment. Examples: &#x27;example.com&#x27; or &#x27;subdomain.example.com&#x27;
511 &quot;A String&quot;,
512 ],
513 &quot;challengeSecurityPreference&quot;: &quot;A String&quot;, # Settings for the frequency and difficulty at which this key triggers captcha challenges. This should only be specified for IntegrationTypes CHECKBOX and INVISIBLE.
514 &quot;integrationType&quot;: &quot;A String&quot;, # Required. Describes how this key is integrated with the website.
515 },
516}</pre>
517</div>
518
519</body></html>