Skip to content
This repository has been archived by the owner on Sep 5, 2023. It is now read-only.

Commit

Permalink
Integrate Python GAPIC Microgenerator in googleapis. This PR uses usi…
Browse files Browse the repository at this point in the history
…ng documentai as an example. Depends on googleapis/gapic-generator-python#402

PiperOrigin-RevId: 309824146

Source-Author: Google APIs <noreply@google.com>
Source-Date: Mon May 4 15:06:44 2020 -0700
Source-Repo: googleapis/googleapis
Source-Sha: e0f9d9e1f9de890db765be46f45ca8490723e3eb
Source-Link: googleapis/googleapis@e0f9d9e
  • Loading branch information
yoshi-automation committed Jun 25, 2020
1 parent eca6fae commit 324fb3d
Show file tree
Hide file tree
Showing 8 changed files with 684 additions and 22 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -163,9 +163,14 @@ def search_hashes(self):
def create_submission(self):
"""Return the gRPC stub for :meth:`WebRiskServiceClient.create_submission`.
The maximum size in number of entries. The diff will not contain
more entries than this value. This should be a power of 2 between
2\ **10 and 2**\ 20. If zero, no diff size limit is set.
Creates a Submission of a URI suspected of containing phishing
content to be reviewed. If the result verifies the existence of
malicious phishing content, the site will be added to the `Google's
Social Engineering
lists <https://support.google.com/webmasters/answer/6350487/>`__ in
order to protect users that could get exposed to this threat in the
future. Only projects with CREATE_SUBMISSION_USERS visibility can use
this method.
Returns:
Callable: A callable which accepts the appropriate
Expand Down
17 changes: 10 additions & 7 deletions google/cloud/webrisk_v1/gapic/web_risk_service_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -416,9 +416,14 @@ def create_submission(
metadata=None,
):
"""
The maximum size in number of entries. The diff will not contain
more entries than this value. This should be a power of 2 between
2\ **10 and 2**\ 20. If zero, no diff size limit is set.
Creates a Submission of a URI suspected of containing phishing
content to be reviewed. If the result verifies the existence of
malicious phishing content, the site will be added to the `Google's
Social Engineering
lists <https://support.google.com/webmasters/answer/6350487/>`__ in
order to protect users that could get exposed to this threat in the
future. Only projects with CREATE_SUBMISSION_USERS visibility can use
this method.
Example:
>>> from google.cloud import webrisk_v1
Expand All @@ -433,10 +438,8 @@ def create_submission(
>>> response = client.create_submission(parent, submission)
Args:
parent (str): The encoded local, lexicographically-sorted list indices, using a
Golomb-Rice encoding. Used for sending compressed removal indices. The
removal indices (uint32) are sorted in ascending order, then delta
encoded and stored as encoded_data.
parent (str): Required. The name of the project that is making the submission.
This string is in the format "projects/{project_number}".
submission (Union[dict, ~google.cloud.webrisk_v1.types.Submission]): Required. The submission that contains the content of the phishing report.
If a dict is provided, it must be of the same form as the protobuf
Expand Down
Loading

0 comments on commit 324fb3d

Please sign in to comment.