Skip to content

Commit

Permalink
feat(recaptchaenterprise): update the API
Browse files Browse the repository at this point in the history
#### recaptchaenterprise:v1

The following keys were added:
- resources.projects.resources.firewallpolicies.methods.reorder.description
- resources.projects.resources.firewallpolicies.methods.reorder.flatPath
- resources.projects.resources.firewallpolicies.methods.reorder.httpMethod
- resources.projects.resources.firewallpolicies.methods.reorder.id
- resources.projects.resources.firewallpolicies.methods.reorder.parameterOrder
- resources.projects.resources.firewallpolicies.methods.reorder.parameters.parent.description
- resources.projects.resources.firewallpolicies.methods.reorder.parameters.parent.location
- resources.projects.resources.firewallpolicies.methods.reorder.parameters.parent.pattern
- resources.projects.resources.firewallpolicies.methods.reorder.parameters.parent.required
- resources.projects.resources.firewallpolicies.methods.reorder.parameters.parent.type
- resources.projects.resources.firewallpolicies.methods.reorder.path
- resources.projects.resources.firewallpolicies.methods.reorder.request.$ref
- resources.projects.resources.firewallpolicies.methods.reorder.response.$ref
- resources.projects.resources.firewallpolicies.methods.reorder.scopes
- schemas.GoogleCloudRecaptchaenterpriseV1ReorderFirewallPoliciesRequest.description
- schemas.GoogleCloudRecaptchaenterpriseV1ReorderFirewallPoliciesRequest.id
- schemas.GoogleCloudRecaptchaenterpriseV1ReorderFirewallPoliciesRequest.properties.names.description
- schemas.GoogleCloudRecaptchaenterpriseV1ReorderFirewallPoliciesRequest.properties.names.items.type
- schemas.GoogleCloudRecaptchaenterpriseV1ReorderFirewallPoliciesRequest.properties.names.type
- schemas.GoogleCloudRecaptchaenterpriseV1ReorderFirewallPoliciesRequest.type
- schemas.GoogleCloudRecaptchaenterpriseV1ReorderFirewallPoliciesResponse.description
- schemas.GoogleCloudRecaptchaenterpriseV1ReorderFirewallPoliciesResponse.id
- schemas.GoogleCloudRecaptchaenterpriseV1ReorderFirewallPoliciesResponse.type

The following keys were changed:
- schemas.GoogleCloudRecaptchaenterpriseV1AccountVerificationInfo.properties.username.description
  • Loading branch information
yoshi-automation authored and bcoe committed Feb 2, 2024
1 parent a84da31 commit abe83f6
Show file tree
Hide file tree
Showing 2 changed files with 173 additions and 3 deletions.
52 changes: 50 additions & 2 deletions discovery/recaptchaenterprise-v1.json
Original file line number Diff line number Diff line change
Expand Up @@ -316,6 +316,34 @@
"scopes": [
"https://www.googleapis.com/auth/cloud-platform"
]
},
"reorder": {
"description": "Reorders all firewall policies.",
"flatPath": "v1/projects/{projectsId}/firewallpolicies:reorder",
"httpMethod": "POST",
"id": "recaptchaenterprise.projects.firewallpolicies.reorder",
"parameterOrder": [
"parent"
],
"parameters": {
"parent": {
"description": "Required. The name of the project to list the policies for, in the format `projects/{project}`.",
"location": "path",
"pattern": "^projects/[^/]+$",
"required": true,
"type": "string"
}
},
"path": "v1/{+parent}/firewallpolicies:reorder",
"request": {
"$ref": "GoogleCloudRecaptchaenterpriseV1ReorderFirewallPoliciesRequest"
},
"response": {
"$ref": "GoogleCloudRecaptchaenterpriseV1ReorderFirewallPoliciesResponse"
},
"scopes": [
"https://www.googleapis.com/auth/cloud-platform"
]
}
}
},
Expand Down Expand Up @@ -666,7 +694,7 @@
}
}
},
"revision": "20231214",
"revision": "20240120",
"rootUrl": "https://recaptchaenterprise.googleapis.com/",
"schemas": {
"GoogleCloudRecaptchaenterpriseV1AccountDefenderAssessment": {
Expand Down Expand Up @@ -744,7 +772,7 @@
},
"username": {
"deprecated": true,
"description": "Username of the account that is being verified. Deprecated. Customers should now provide the hashed account ID field in Event.",
"description": "Username of the account that is being verified. Deprecated. Customers should now provide the `account_id` field in `event.user_info`.",
"type": "string"
}
},
Expand Down Expand Up @@ -1554,6 +1582,26 @@
},
"type": "object"
},
"GoogleCloudRecaptchaenterpriseV1ReorderFirewallPoliciesRequest": {
"description": "The reorder firewall policies request message.",
"id": "GoogleCloudRecaptchaenterpriseV1ReorderFirewallPoliciesRequest",
"properties": {
"names": {
"description": "Required. A list containing all policy names, in the new order. Each name is in the format `projects/{project}/firewallpolicies/{firewallpolicy}`.",
"items": {
"type": "string"
},
"type": "array"
}
},
"type": "object"
},
"GoogleCloudRecaptchaenterpriseV1ReorderFirewallPoliciesResponse": {
"description": "The reorder firewall policies response message.",
"id": "GoogleCloudRecaptchaenterpriseV1ReorderFirewallPoliciesResponse",
"properties": {},
"type": "object"
},
"GoogleCloudRecaptchaenterpriseV1RetrieveLegacySecretKeyResponse": {
"description": "Secret key is used only in legacy reCAPTCHA. It must be used in a 3rd party integration with legacy reCAPTCHA.",
"id": "GoogleCloudRecaptchaenterpriseV1RetrieveLegacySecretKeyResponse",
Expand Down
124 changes: 123 additions & 1 deletion src/apis/recaptchaenterprise/v1.ts
Original file line number Diff line number Diff line change
Expand Up @@ -150,7 +150,7 @@ export namespace recaptchaenterprise_v1 {
*/
latestVerificationResult?: string | null;
/**
* Username of the account that is being verified. Deprecated. Customers should now provide the hashed account ID field in Event.
* Username of the account that is being verified. Deprecated. Customers should now provide the `account_id` field in `event.user_info`.
*/
username?: string | null;
}
Expand Down Expand Up @@ -732,6 +732,19 @@ export namespace recaptchaenterprise_v1 {
*/
name?: string | null;
}
/**
* The reorder firewall policies request message.
*/
export interface Schema$GoogleCloudRecaptchaenterpriseV1ReorderFirewallPoliciesRequest {
/**
* Required. A list containing all policy names, in the new order. Each name is in the format `projects/{project\}/firewallpolicies/{firewallpolicy\}`.
*/
names?: string[] | null;
}
/**
* The reorder firewall policies response message.
*/
export interface Schema$GoogleCloudRecaptchaenterpriseV1ReorderFirewallPoliciesResponse {}
/**
* Secret key is used only in legacy reCAPTCHA. It must be used in a 3rd party integration with legacy reCAPTCHA.
*/
Expand Down Expand Up @@ -1857,6 +1870,103 @@ export namespace recaptchaenterprise_v1 {
);
}
}

/**
* Reorders all firewall policies.
*
* @param params - Parameters for request
* @param options - Optionally override request options, such as `url`, `method`, and `encoding`.
* @param callback - Optional callback that handles the response.
* @returns A promise if used with async/await, or void if used with a callback.
*/
reorder(
params: Params$Resource$Projects$Firewallpolicies$Reorder,
options: StreamMethodOptions
): GaxiosPromise<Readable>;
reorder(
params?: Params$Resource$Projects$Firewallpolicies$Reorder,
options?: MethodOptions
): GaxiosPromise<Schema$GoogleCloudRecaptchaenterpriseV1ReorderFirewallPoliciesResponse>;
reorder(
params: Params$Resource$Projects$Firewallpolicies$Reorder,
options: StreamMethodOptions | BodyResponseCallback<Readable>,
callback: BodyResponseCallback<Readable>
): void;
reorder(
params: Params$Resource$Projects$Firewallpolicies$Reorder,
options:
| MethodOptions
| BodyResponseCallback<Schema$GoogleCloudRecaptchaenterpriseV1ReorderFirewallPoliciesResponse>,
callback: BodyResponseCallback<Schema$GoogleCloudRecaptchaenterpriseV1ReorderFirewallPoliciesResponse>
): void;
reorder(
params: Params$Resource$Projects$Firewallpolicies$Reorder,
callback: BodyResponseCallback<Schema$GoogleCloudRecaptchaenterpriseV1ReorderFirewallPoliciesResponse>
): void;
reorder(
callback: BodyResponseCallback<Schema$GoogleCloudRecaptchaenterpriseV1ReorderFirewallPoliciesResponse>
): void;
reorder(
paramsOrCallback?:
| Params$Resource$Projects$Firewallpolicies$Reorder
| BodyResponseCallback<Schema$GoogleCloudRecaptchaenterpriseV1ReorderFirewallPoliciesResponse>
| BodyResponseCallback<Readable>,
optionsOrCallback?:
| MethodOptions
| StreamMethodOptions
| BodyResponseCallback<Schema$GoogleCloudRecaptchaenterpriseV1ReorderFirewallPoliciesResponse>
| BodyResponseCallback<Readable>,
callback?:
| BodyResponseCallback<Schema$GoogleCloudRecaptchaenterpriseV1ReorderFirewallPoliciesResponse>
| BodyResponseCallback<Readable>
):
| void
| GaxiosPromise<Schema$GoogleCloudRecaptchaenterpriseV1ReorderFirewallPoliciesResponse>
| GaxiosPromise<Readable> {
let params = (paramsOrCallback ||
{}) as Params$Resource$Projects$Firewallpolicies$Reorder;
let options = (optionsOrCallback || {}) as MethodOptions;

if (typeof paramsOrCallback === 'function') {
callback = paramsOrCallback;
params = {} as Params$Resource$Projects$Firewallpolicies$Reorder;
options = {};
}

if (typeof optionsOrCallback === 'function') {
callback = optionsOrCallback;
options = {};
}

const rootUrl =
options.rootUrl || 'https://recaptchaenterprise.googleapis.com/';
const parameters = {
options: Object.assign(
{
url: (rootUrl + '/v1/{+parent}/firewallpolicies:reorder').replace(
/([^:]\/)\/+/g,
'$1'
),
method: 'POST',
},
options
),
params,
requiredParams: ['parent'],
pathParams: ['parent'],
context: this.context,
};
if (callback) {
createAPIRequest<Schema$GoogleCloudRecaptchaenterpriseV1ReorderFirewallPoliciesResponse>(
parameters,
callback as BodyResponseCallback<unknown>
);
} else {
return createAPIRequest<Schema$GoogleCloudRecaptchaenterpriseV1ReorderFirewallPoliciesResponse>(
parameters
);
}
}
}

export interface Params$Resource$Projects$Firewallpolicies$Create
Expand Down Expand Up @@ -1916,6 +2026,18 @@ export namespace recaptchaenterprise_v1 {
*/
requestBody?: Schema$GoogleCloudRecaptchaenterpriseV1FirewallPolicy;
}
export interface Params$Resource$Projects$Firewallpolicies$Reorder
extends StandardParameters {
/**
* Required. The name of the project to list the policies for, in the format `projects/{project\}`.
*/
parent?: string;

/**
* Request body metadata
*/
requestBody?: Schema$GoogleCloudRecaptchaenterpriseV1ReorderFirewallPoliciesRequest;
}

export class Resource$Projects$Keys {
context: APIRequestContext;
Expand Down

0 comments on commit abe83f6

Please sign in to comment.