Google Cloud Web Risk v1 API - Class WebRiskServiceClientImpl (2.1.0)

public sealed class WebRiskServiceClientImpl : WebRiskServiceClient

Reference documentation and code samples for the Google Cloud Web Risk v1 API class WebRiskServiceClientImpl.

WebRiskService client wrapper implementation, for convenient use.

Inheritance

Object > WebRiskServiceClient > WebRiskServiceClientImpl

Namespace

Google.Cloud.WebRisk.V1

Assembly

Google.Cloud.WebRisk.V1.dll

Remarks

Web Risk API defines an interface to detect malicious URLs on your website and in client applications.

Constructors

WebRiskServiceClientImpl(WebRiskService.WebRiskServiceClient, WebRiskServiceSettings, ILogger)

public WebRiskServiceClientImpl(WebRiskService.WebRiskServiceClient grpcClient, WebRiskServiceSettings settings, ILogger logger)

Constructs a client wrapper for the WebRiskService service, with the specified gRPC client and settings.

Parameters
NameDescription
grpcClientWebRiskService.WebRiskServiceClient

The underlying gRPC client.

settingsWebRiskServiceSettings

The base WebRiskServiceSettings used within this client.

loggerILogger

Optional ILogger to use within this client.

Properties

GrpcClient

public override WebRiskService.WebRiskServiceClient GrpcClient { get; }

The underlying gRPC WebRiskService client

Property Value
TypeDescription
WebRiskService.WebRiskServiceClient
Overrides

Methods

ComputeThreatListDiff(ComputeThreatListDiffRequest, CallSettings)

public override ComputeThreatListDiffResponse ComputeThreatListDiff(ComputeThreatListDiffRequest request, CallSettings callSettings = null)

Gets the most recent threat list diffs. These diffs should be applied to a local database of hashes to keep it up-to-date. If the local database is empty or excessively out-of-date, a complete snapshot of the database will be returned. This Method only updates a single ThreatList at a time. To update multiple ThreatList databases, this method needs to be called once for each list.

Parameters
NameDescription
requestComputeThreatListDiffRequest

The request object containing all of the parameters for the API call.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
ComputeThreatListDiffResponse

The RPC response.

Overrides

ComputeThreatListDiffAsync(ComputeThreatListDiffRequest, CallSettings)

public override Task<ComputeThreatListDiffResponse> ComputeThreatListDiffAsync(ComputeThreatListDiffRequest request, CallSettings callSettings = null)

Gets the most recent threat list diffs. These diffs should be applied to a local database of hashes to keep it up-to-date. If the local database is empty or excessively out-of-date, a complete snapshot of the database will be returned. This Method only updates a single ThreatList at a time. To update multiple ThreatList databases, this method needs to be called once for each list.

Parameters
NameDescription
requestComputeThreatListDiffRequest

The request object containing all of the parameters for the API call.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Task<ComputeThreatListDiffResponse>

A Task containing the RPC response.

Overrides

CreateSubmission(CreateSubmissionRequest, CallSettings)

public override Submission CreateSubmission(CreateSubmissionRequest request, CallSettings callSettings = null)

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 in order to protect users that could get exposed to this threat in the future. Only allowlisted projects can use this method during Early Access. Please reach out to Sales or your customer engineer to obtain access.

Parameters
NameDescription
requestCreateSubmissionRequest

The request object containing all of the parameters for the API call.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Submission

The RPC response.

Overrides

CreateSubmissionAsync(CreateSubmissionRequest, CallSettings)

public override Task<Submission> CreateSubmissionAsync(CreateSubmissionRequest request, CallSettings callSettings = null)

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 in order to protect users that could get exposed to this threat in the future. Only allowlisted projects can use this method during Early Access. Please reach out to Sales or your customer engineer to obtain access.

Parameters
NameDescription
requestCreateSubmissionRequest

The request object containing all of the parameters for the API call.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Task<Submission>

A Task containing the RPC response.

Overrides

SearchHashes(SearchHashesRequest, CallSettings)

public override SearchHashesResponse SearchHashes(SearchHashesRequest request, CallSettings callSettings = null)

Gets the full hashes that match the requested hash prefix. This is used after a hash prefix is looked up in a threatList and there is a match. The client side threatList only holds partial hashes so the client must query this method to determine if there is a full hash match of a threat.

Parameters
NameDescription
requestSearchHashesRequest

The request object containing all of the parameters for the API call.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
SearchHashesResponse

The RPC response.

Overrides

SearchHashesAsync(SearchHashesRequest, CallSettings)

public override Task<SearchHashesResponse> SearchHashesAsync(SearchHashesRequest request, CallSettings callSettings = null)

Gets the full hashes that match the requested hash prefix. This is used after a hash prefix is looked up in a threatList and there is a match. The client side threatList only holds partial hashes so the client must query this method to determine if there is a full hash match of a threat.

Parameters
NameDescription
requestSearchHashesRequest

The request object containing all of the parameters for the API call.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Task<SearchHashesResponse>

A Task containing the RPC response.

Overrides

SearchUris(SearchUrisRequest, CallSettings)

public override SearchUrisResponse SearchUris(SearchUrisRequest request, CallSettings callSettings = null)

This method is used to check whether a URI is on a given threatList. Multiple threatLists may be searched in a single query. The response will list all requested threatLists the URI was found to match. If the URI is not found on any of the requested ThreatList an empty response will be returned.

Parameters
NameDescription
requestSearchUrisRequest

The request object containing all of the parameters for the API call.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
SearchUrisResponse

The RPC response.

Overrides

SearchUrisAsync(SearchUrisRequest, CallSettings)

public override Task<SearchUrisResponse> SearchUrisAsync(SearchUrisRequest request, CallSettings callSettings = null)

This method is used to check whether a URI is on a given threatList. Multiple threatLists may be searched in a single query. The response will list all requested threatLists the URI was found to match. If the URI is not found on any of the requested ThreatList an empty response will be returned.

Parameters
NameDescription
requestSearchUrisRequest

The request object containing all of the parameters for the API call.

callSettingsCallSettings

If not null, applies overrides to this RPC call.

Returns
TypeDescription
Task<SearchUrisResponse>

A Task containing the RPC response.

Overrides