Skip to content

Commit

Permalink
feat: [recaptchaenterprise] add reCAPTCHA Enterprise Fraud Prevention…
Browse files Browse the repository at this point in the history
… API (#4095)

* feat: add reCAPTCHA Enterprise Fraud Prevention API

This cl adds API features for Fraud Prevention including the FraudPreventionAssessment.

PiperOrigin-RevId: 517166403

Source-Link: googleapis/googleapis@5947146

Source-Link: googleapis/googleapis-gen@85b29f6
Copy-Tag: eyJwIjoicGFja2FnZXMvZ29vZ2xlLWNsb3VkLXJlY2FwdGNoYWVudGVycHJpc2UvLk93bEJvdC55YW1sIiwiaCI6Ijg1YjI5ZjZhMDMyODQ2OGIzNzc1MzE1NDI2MzM0OTBjMjRmNDExZDYifQ==

* 🦉 Updates from OwlBot post-processor

See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md

* feat: add reCAPTCHA Enterprise Fraud Prevention API

This cl adds API features for Fraud Prevention including the FraudPreventionAssessment.

PiperOrigin-RevId: 517508635

Source-Link: googleapis/googleapis@f3c3f38

Source-Link: googleapis/googleapis-gen@892d539
Copy-Tag: eyJwIjoicGFja2FnZXMvZ29vZ2xlLWNsb3VkLXJlY2FwdGNoYWVudGVycHJpc2UvLk93bEJvdC55YW1sIiwiaCI6Ijg5MmQ1Mzk2YTQyMzJhMWVmZmU3OGY1MzBkZWQzNDQ1ZDhiOWJiOGMifQ==

* 🦉 Updates from OwlBot post-processor

See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md

---------

Co-authored-by: Owl Bot <gcf-owl-bot[bot]@users.noreply.github.com>
Co-authored-by: sofisl <55454395+sofisl@users.noreply.github.com>
  • Loading branch information
3 people authored Mar 21, 2023
1 parent d4d00ec commit d6f04cb
Show file tree
Hide file tree
Showing 11 changed files with 12,406 additions and 2,886 deletions.

Large diffs are not rendered by default.

Large diffs are not rendered by default.

2,355 changes: 2,306 additions & 49 deletions packages/google-cloud-recaptchaenterprise/protos/protos.d.ts

Large diffs are not rendered by default.

11,523 changes: 8,765 additions & 2,758 deletions packages/google-cloud-recaptchaenterprise/protos/protos.js

Large diffs are not rendered by default.

602 changes: 593 additions & 9 deletions packages/google-cloud-recaptchaenterprise/protos/protos.json

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,11 @@ function main(name) {
* using hmac-sha256 with stable secret.
*/
// const hashedAccountId = 'Buffer.from('string')'
/**
* Optional. If the assessment is part of a payment transaction, provide
* details on payment lifecycle events that occur in the transaction.
*/
// const transactionEvent = {}

// Imports the Recaptchaenterprise library
const {RecaptchaEnterpriseServiceClient} = require('@google-cloud/recaptcha-enterprise').v1;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"clientLibrary": {
"name": "nodejs-recaptchaenterprise",
"version": "3.3.0",
"version": "3.3.1",
"language": "TYPESCRIPT",
"apis": [
{
Expand Down Expand Up @@ -66,7 +66,7 @@
"segments": [
{
"start": 25,
"end": 73,
"end": 78,
"type": "FULL"
}
],
Expand All @@ -90,6 +90,10 @@
{
"name": "hashed_account_id",
"type": "TYPE_BYTES"
},
{
"name": "transaction_event",
"type": ".google.cloud.recaptchaenterprise.v1.TransactionEvent"
}
],
"resultType": ".google.cloud.recaptchaenterprise.v1.AnnotateAssessmentResponse",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,23 +34,29 @@ function main(name) {
*/
// const name = 'abc123'
/**
* Optional. The annotation that will be assigned to the Event. This field can be left
* empty to provide reasons that apply to an event without concluding whether
* the event is legitimate or fraudulent.
* Optional. The annotation that will be assigned to the Event. This field can
* be left empty to provide reasons that apply to an event without concluding
* whether the event is legitimate or fraudulent.
*/
// const annotation = {}
/**
* Optional. Optional reasons for the annotation that will be assigned to the Event.
* Optional. Optional reasons for the annotation that will be assigned to the
* Event.
*/
// const reasons = 1234
/**
* Optional. Optional unique stable hashed user identifier to apply to the assessment.
* This is an alternative to setting the hashed_account_id in
* Optional. Optional unique stable hashed user identifier to apply to the
* assessment. This is an alternative to setting the hashed_account_id in
* CreateAssessment, for example when the account identifier is not yet known
* in the initial request. It is recommended that the identifier is hashed
* using hmac-sha256 with stable secret.
*/
// const hashedAccountId = 'Buffer.from('string')'
/**
* Optional. If the assessment is part of a payment transaction, provide
* details on payment lifecycle events that occur in the transaction.
*/
// const transactionEvent = {}

// Imports the Recaptchaenterprise library
const {RecaptchaEnterpriseServiceV1Beta1Client} = require('@google-cloud/recaptcha-enterprise').v1beta1;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"clientLibrary": {
"name": "nodejs-recaptchaenterprise",
"version": "3.3.0",
"version": "3.3.1",
"language": "TYPESCRIPT",
"apis": [
{
Expand Down Expand Up @@ -66,7 +66,7 @@
"segments": [
{
"start": 25,
"end": 72,
"end": 78,
"type": "FULL"
}
],
Expand All @@ -90,6 +90,10 @@
{
"name": "hashed_account_id",
"type": "TYPE_BYTES"
},
{
"name": "transaction_event",
"type": ".google.cloud.recaptchaenterprise.v1beta1.TransactionEvent"
}
],
"resultType": ".google.cloud.recaptchaenterprise.v1beta1.AnnotateAssessmentResponse",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -495,6 +495,9 @@ export class RecaptchaEnterpriseServiceClient {
* CreateAssessment, for example when the account identifier is not yet known
* in the initial request. It is recommended that the identifier is hashed
* using hmac-sha256 with stable secret.
* @param {google.cloud.recaptchaenterprise.v1.TransactionEvent} [request.transactionEvent]
* Optional. If the assessment is part of a payment transaction, provide
* details on payment lifecycle events that occur in the transaction.
* @param {object} [options]
* Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details.
* @returns {Promise} - The promise which resolves to an array.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -431,17 +431,21 @@ export class RecaptchaEnterpriseServiceV1Beta1Client {
* Required. The resource name of the Assessment, in the format
* "projects/{project_number}/assessments/{assessment_id}".
* @param {google.cloud.recaptchaenterprise.v1beta1.AnnotateAssessmentRequest.Annotation} [request.annotation]
* Optional. The annotation that will be assigned to the Event. This field can be left
* empty to provide reasons that apply to an event without concluding whether
* the event is legitimate or fraudulent.
* Optional. The annotation that will be assigned to the Event. This field can
* be left empty to provide reasons that apply to an event without concluding
* whether the event is legitimate or fraudulent.
* @param {number[]} [request.reasons]
* Optional. Optional reasons for the annotation that will be assigned to the Event.
* Optional. Optional reasons for the annotation that will be assigned to the
* Event.
* @param {Buffer} [request.hashedAccountId]
* Optional. Optional unique stable hashed user identifier to apply to the assessment.
* This is an alternative to setting the hashed_account_id in
* Optional. Optional unique stable hashed user identifier to apply to the
* assessment. This is an alternative to setting the hashed_account_id in
* CreateAssessment, for example when the account identifier is not yet known
* in the initial request. It is recommended that the identifier is hashed
* using hmac-sha256 with stable secret.
* @param {google.cloud.recaptchaenterprise.v1beta1.TransactionEvent} [request.transactionEvent]
* Optional. If the assessment is part of a payment transaction, provide
* details on payment lifecycle events that occur in the transaction.
* @param {object} [options]
* Call options. See {@link https://googleapis.dev/nodejs/google-gax/latest/interfaces/CallOptions.html|CallOptions} for more details.
* @returns {Promise} - The promise which resolves to an array.
Expand Down

0 comments on commit d6f04cb

Please sign in to comment.