mirror of
https://github.com/OMGeeky/google-apis-rs.git
synced 2026-02-23 15:49:49 +01:00
regen all APIs
This commit is contained in:
@@ -4,12 +4,12 @@
|
||||
[package]
|
||||
|
||||
name = "google-safebrowsing4"
|
||||
version = "5.0.3+20230108"
|
||||
version = "5.0.3+20240225"
|
||||
authors = ["Sebastian Thiel <byronimo@gmail.com>"]
|
||||
description = "A complete library to interact with Safebrowsing (protocol v4)"
|
||||
repository = "https://github.com/Byron/google-apis-rs/tree/main/gen/safebrowsing4"
|
||||
homepage = "https://developers.google.com/safe-browsing/"
|
||||
documentation = "https://docs.rs/google-safebrowsing4/5.0.3+20230108"
|
||||
documentation = "https://docs.rs/google-safebrowsing4/5.0.3+20240225"
|
||||
license = "MIT"
|
||||
keywords = ["safebrowsing", "google", "protocol", "web", "api"]
|
||||
autobins = false
|
||||
|
||||
@@ -5,28 +5,28 @@ DO NOT EDIT !
|
||||
-->
|
||||
The `google-safebrowsing4` library allows access to all features of the *Google Safebrowsing* service.
|
||||
|
||||
This documentation was generated from *Safebrowsing* crate version *5.0.3+20230108*, where *20230108* is the exact revision of the *safebrowsing:v4* schema built by the [mako](http://www.makotemplates.org/) code generator *v5.0.3*.
|
||||
This documentation was generated from *Safebrowsing* crate version *5.0.3+20240225*, where *20240225* is the exact revision of the *safebrowsing:v4* schema built by the [mako](http://www.makotemplates.org/) code generator *v5.0.3*.
|
||||
|
||||
Everything else about the *Safebrowsing* *v4* API can be found at the
|
||||
[official documentation site](https://developers.google.com/safe-browsing/).
|
||||
# Features
|
||||
|
||||
Handle the following *Resources* with ease from the central [hub](https://docs.rs/google-safebrowsing4/5.0.3+20230108/google_safebrowsing4/Safebrowsing) ...
|
||||
Handle the following *Resources* with ease from the central [hub](https://docs.rs/google-safebrowsing4/5.0.3+20240225/google_safebrowsing4/Safebrowsing) ...
|
||||
|
||||
* encoded full hashes
|
||||
* [*get*](https://docs.rs/google-safebrowsing4/5.0.3+20230108/google_safebrowsing4/api::EncodedFullHashGetCall)
|
||||
* [*get*](https://docs.rs/google-safebrowsing4/5.0.3+20240225/google_safebrowsing4/api::EncodedFullHashGetCall)
|
||||
* encoded updates
|
||||
* [*get*](https://docs.rs/google-safebrowsing4/5.0.3+20230108/google_safebrowsing4/api::EncodedUpdateGetCall)
|
||||
* [*get*](https://docs.rs/google-safebrowsing4/5.0.3+20240225/google_safebrowsing4/api::EncodedUpdateGetCall)
|
||||
* full hashes
|
||||
* [*find*](https://docs.rs/google-safebrowsing4/5.0.3+20230108/google_safebrowsing4/api::FullHashFindCall)
|
||||
* [*find*](https://docs.rs/google-safebrowsing4/5.0.3+20240225/google_safebrowsing4/api::FullHashFindCall)
|
||||
* threat hits
|
||||
* [*create*](https://docs.rs/google-safebrowsing4/5.0.3+20230108/google_safebrowsing4/api::ThreatHitCreateCall)
|
||||
* [*create*](https://docs.rs/google-safebrowsing4/5.0.3+20240225/google_safebrowsing4/api::ThreatHitCreateCall)
|
||||
* threat list updates
|
||||
* [*fetch*](https://docs.rs/google-safebrowsing4/5.0.3+20230108/google_safebrowsing4/api::ThreatListUpdateFetchCall)
|
||||
* [*fetch*](https://docs.rs/google-safebrowsing4/5.0.3+20240225/google_safebrowsing4/api::ThreatListUpdateFetchCall)
|
||||
* threat lists
|
||||
* [*list*](https://docs.rs/google-safebrowsing4/5.0.3+20230108/google_safebrowsing4/api::ThreatListListCall)
|
||||
* [*list*](https://docs.rs/google-safebrowsing4/5.0.3+20240225/google_safebrowsing4/api::ThreatListListCall)
|
||||
* threat matches
|
||||
* [*find*](https://docs.rs/google-safebrowsing4/5.0.3+20230108/google_safebrowsing4/api::ThreatMatchFindCall)
|
||||
* [*find*](https://docs.rs/google-safebrowsing4/5.0.3+20240225/google_safebrowsing4/api::ThreatMatchFindCall)
|
||||
|
||||
|
||||
|
||||
@@ -35,17 +35,17 @@ Handle the following *Resources* with ease from the central [hub](https://docs.r
|
||||
|
||||
The API is structured into the following primary items:
|
||||
|
||||
* **[Hub](https://docs.rs/google-safebrowsing4/5.0.3+20230108/google_safebrowsing4/Safebrowsing)**
|
||||
* **[Hub](https://docs.rs/google-safebrowsing4/5.0.3+20240225/google_safebrowsing4/Safebrowsing)**
|
||||
* a central object to maintain state and allow accessing all *Activities*
|
||||
* creates [*Method Builders*](https://docs.rs/google-safebrowsing4/5.0.3+20230108/google_safebrowsing4/client::MethodsBuilder) which in turn
|
||||
allow access to individual [*Call Builders*](https://docs.rs/google-safebrowsing4/5.0.3+20230108/google_safebrowsing4/client::CallBuilder)
|
||||
* **[Resources](https://docs.rs/google-safebrowsing4/5.0.3+20230108/google_safebrowsing4/client::Resource)**
|
||||
* creates [*Method Builders*](https://docs.rs/google-safebrowsing4/5.0.3+20240225/google_safebrowsing4/client::MethodsBuilder) which in turn
|
||||
allow access to individual [*Call Builders*](https://docs.rs/google-safebrowsing4/5.0.3+20240225/google_safebrowsing4/client::CallBuilder)
|
||||
* **[Resources](https://docs.rs/google-safebrowsing4/5.0.3+20240225/google_safebrowsing4/client::Resource)**
|
||||
* primary types that you can apply *Activities* to
|
||||
* a collection of properties and *Parts*
|
||||
* **[Parts](https://docs.rs/google-safebrowsing4/5.0.3+20230108/google_safebrowsing4/client::Part)**
|
||||
* **[Parts](https://docs.rs/google-safebrowsing4/5.0.3+20240225/google_safebrowsing4/client::Part)**
|
||||
* a collection of properties
|
||||
* never directly used in *Activities*
|
||||
* **[Activities](https://docs.rs/google-safebrowsing4/5.0.3+20230108/google_safebrowsing4/client::CallBuilder)**
|
||||
* **[Activities](https://docs.rs/google-safebrowsing4/5.0.3+20240225/google_safebrowsing4/client::CallBuilder)**
|
||||
* operations to apply to *Resources*
|
||||
|
||||
All *structures* are marked with applicable traits to further categorize them and ease browsing.
|
||||
@@ -133,17 +133,17 @@ match result {
|
||||
```
|
||||
## Handling Errors
|
||||
|
||||
All errors produced by the system are provided either as [Result](https://docs.rs/google-safebrowsing4/5.0.3+20230108/google_safebrowsing4/client::Result) enumeration as return value of
|
||||
All errors produced by the system are provided either as [Result](https://docs.rs/google-safebrowsing4/5.0.3+20240225/google_safebrowsing4/client::Result) enumeration as return value of
|
||||
the doit() methods, or handed as possibly intermediate results to either the
|
||||
[Hub Delegate](https://docs.rs/google-safebrowsing4/5.0.3+20230108/google_safebrowsing4/client::Delegate), or the [Authenticator Delegate](https://docs.rs/yup-oauth2/*/yup_oauth2/trait.AuthenticatorDelegate.html).
|
||||
[Hub Delegate](https://docs.rs/google-safebrowsing4/5.0.3+20240225/google_safebrowsing4/client::Delegate), or the [Authenticator Delegate](https://docs.rs/yup-oauth2/*/yup_oauth2/trait.AuthenticatorDelegate.html).
|
||||
|
||||
When delegates handle errors or intermediate values, they may have a chance to instruct the system to retry. This
|
||||
makes the system potentially resilient to all kinds of errors.
|
||||
|
||||
## Uploads and Downloads
|
||||
If a method supports downloads, the response body, which is part of the [Result](https://docs.rs/google-safebrowsing4/5.0.3+20230108/google_safebrowsing4/client::Result), should be
|
||||
If a method supports downloads, the response body, which is part of the [Result](https://docs.rs/google-safebrowsing4/5.0.3+20240225/google_safebrowsing4/client::Result), should be
|
||||
read by you to obtain the media.
|
||||
If such a method also supports a [Response Result](https://docs.rs/google-safebrowsing4/5.0.3+20230108/google_safebrowsing4/client::ResponseResult), it will return that by default.
|
||||
If such a method also supports a [Response Result](https://docs.rs/google-safebrowsing4/5.0.3+20240225/google_safebrowsing4/client::ResponseResult), it will return that by default.
|
||||
You can see it as meta-data for the actual media. To trigger a media download, you will have to set up the builder by making
|
||||
this call: `.param("alt", "media")`.
|
||||
|
||||
@@ -153,29 +153,29 @@ Methods supporting uploads can do so using up to 2 different protocols:
|
||||
|
||||
## Customization and Callbacks
|
||||
|
||||
You may alter the way an `doit()` method is called by providing a [delegate](https://docs.rs/google-safebrowsing4/5.0.3+20230108/google_safebrowsing4/client::Delegate) to the
|
||||
[Method Builder](https://docs.rs/google-safebrowsing4/5.0.3+20230108/google_safebrowsing4/client::CallBuilder) before making the final `doit()` call.
|
||||
You may alter the way an `doit()` method is called by providing a [delegate](https://docs.rs/google-safebrowsing4/5.0.3+20240225/google_safebrowsing4/client::Delegate) to the
|
||||
[Method Builder](https://docs.rs/google-safebrowsing4/5.0.3+20240225/google_safebrowsing4/client::CallBuilder) before making the final `doit()` call.
|
||||
Respective methods will be called to provide progress information, as well as determine whether the system should
|
||||
retry on failure.
|
||||
|
||||
The [delegate trait](https://docs.rs/google-safebrowsing4/5.0.3+20230108/google_safebrowsing4/client::Delegate) is default-implemented, allowing you to customize it with minimal effort.
|
||||
The [delegate trait](https://docs.rs/google-safebrowsing4/5.0.3+20240225/google_safebrowsing4/client::Delegate) is default-implemented, allowing you to customize it with minimal effort.
|
||||
|
||||
## Optional Parts in Server-Requests
|
||||
|
||||
All structures provided by this library are made to be [encodable](https://docs.rs/google-safebrowsing4/5.0.3+20230108/google_safebrowsing4/client::RequestValue) and
|
||||
[decodable](https://docs.rs/google-safebrowsing4/5.0.3+20230108/google_safebrowsing4/client::ResponseResult) via *json*. Optionals are used to indicate that partial requests are responses
|
||||
All structures provided by this library are made to be [encodable](https://docs.rs/google-safebrowsing4/5.0.3+20240225/google_safebrowsing4/client::RequestValue) and
|
||||
[decodable](https://docs.rs/google-safebrowsing4/5.0.3+20240225/google_safebrowsing4/client::ResponseResult) via *json*. Optionals are used to indicate that partial requests are responses
|
||||
are valid.
|
||||
Most optionals are are considered [Parts](https://docs.rs/google-safebrowsing4/5.0.3+20230108/google_safebrowsing4/client::Part) which are identifiable by name, which will be sent to
|
||||
Most optionals are are considered [Parts](https://docs.rs/google-safebrowsing4/5.0.3+20240225/google_safebrowsing4/client::Part) which are identifiable by name, which will be sent to
|
||||
the server to indicate either the set parts of the request or the desired parts in the response.
|
||||
|
||||
## Builder Arguments
|
||||
|
||||
Using [method builders](https://docs.rs/google-safebrowsing4/5.0.3+20230108/google_safebrowsing4/client::CallBuilder), you are able to prepare an action call by repeatedly calling it's methods.
|
||||
Using [method builders](https://docs.rs/google-safebrowsing4/5.0.3+20240225/google_safebrowsing4/client::CallBuilder), you are able to prepare an action call by repeatedly calling it's methods.
|
||||
These will always take a single argument, for which the following statements are true.
|
||||
|
||||
* [PODs][wiki-pod] are handed by copy
|
||||
* strings are passed as `&str`
|
||||
* [request values](https://docs.rs/google-safebrowsing4/5.0.3+20230108/google_safebrowsing4/client::RequestValue) are moved
|
||||
* [request values](https://docs.rs/google-safebrowsing4/5.0.3+20240225/google_safebrowsing4/client::RequestValue) are moved
|
||||
|
||||
Arguments will always be copied or cloned into the builder, to make them independent of their original life times.
|
||||
|
||||
|
||||
@@ -180,7 +180,7 @@ impl client::ResponseResult for GoogleProtobufEmpty {}
|
||||
pub struct GoogleSecuritySafebrowsingV4Checksum {
|
||||
/// The SHA256 hash of the client state; that is, of the sorted list of all hashes present in the database.
|
||||
|
||||
#[serde_as(as = "Option<::client::serde::urlsafe_base64::Wrapper>")]
|
||||
#[serde_as(as = "Option<::client::serde::standard_base64::Wrapper>")]
|
||||
pub sha256: Option<Vec<u8>>,
|
||||
}
|
||||
|
||||
@@ -246,7 +246,7 @@ pub struct GoogleSecuritySafebrowsingV4FetchThreatListUpdatesRequestListUpdateRe
|
||||
pub platform_type: Option<String>,
|
||||
/// The current state of the client for the requested list (the encrypted client state that was received from the last successful list update).
|
||||
|
||||
#[serde_as(as = "Option<::client::serde::urlsafe_base64::Wrapper>")]
|
||||
#[serde_as(as = "Option<::client::serde::standard_base64::Wrapper>")]
|
||||
pub state: Option<Vec<u8>>,
|
||||
/// The types of entries present in the list.
|
||||
#[serde(rename="threatEntryType")]
|
||||
@@ -337,7 +337,7 @@ pub struct GoogleSecuritySafebrowsingV4FetchThreatListUpdatesResponseListUpdateR
|
||||
/// The new client state, in encrypted format. Opaque to clients.
|
||||
#[serde(rename="newClientState")]
|
||||
|
||||
#[serde_as(as = "Option<::client::serde::urlsafe_base64::Wrapper>")]
|
||||
#[serde_as(as = "Option<::client::serde::standard_base64::Wrapper>")]
|
||||
pub new_client_state: Option<Vec<u8>>,
|
||||
/// The platform type for which data is returned.
|
||||
#[serde(rename="platformType")]
|
||||
@@ -384,7 +384,7 @@ pub struct GoogleSecuritySafebrowsingV4FindFullHashesRequest {
|
||||
/// The current client states for each of the client's local threat lists.
|
||||
#[serde(rename="clientStates")]
|
||||
|
||||
#[serde_as(as = "Option<Vec<::client::serde::urlsafe_base64::Wrapper>>")]
|
||||
#[serde_as(as = "Option<Vec<::client::serde::standard_base64::Wrapper>>")]
|
||||
pub client_states: Option<Vec<Vec<u8>>>,
|
||||
/// The lists and hashes to be checked.
|
||||
#[serde(rename="threatInfo")]
|
||||
@@ -501,7 +501,7 @@ pub struct GoogleSecuritySafebrowsingV4RawHashes {
|
||||
/// The hashes, in binary format, concatenated into one long string. Hashes are sorted in lexicographic order. For JSON API users, hashes are base64-encoded.
|
||||
#[serde(rename="rawHashes")]
|
||||
|
||||
#[serde_as(as = "Option<::client::serde::urlsafe_base64::Wrapper>")]
|
||||
#[serde_as(as = "Option<::client::serde::standard_base64::Wrapper>")]
|
||||
pub raw_hashes: Option<Vec<u8>>,
|
||||
}
|
||||
|
||||
@@ -533,7 +533,7 @@ pub struct GoogleSecuritySafebrowsingV4RiceDeltaEncoding {
|
||||
/// The encoded deltas that are encoded using the Golomb-Rice coder.
|
||||
#[serde(rename="encodedData")]
|
||||
|
||||
#[serde_as(as = "Option<::client::serde::urlsafe_base64::Wrapper>")]
|
||||
#[serde_as(as = "Option<::client::serde::standard_base64::Wrapper>")]
|
||||
pub encoded_data: Option<Vec<u8>>,
|
||||
/// The offset of the first entry in the encoded data, or, if only a single integer was encoded, that single integer's value. If the field is empty or missing, assume zero.
|
||||
#[serde(rename="firstValue")]
|
||||
@@ -562,11 +562,11 @@ impl client::Part for GoogleSecuritySafebrowsingV4RiceDeltaEncoding {}
|
||||
pub struct GoogleSecuritySafebrowsingV4ThreatEntry {
|
||||
/// The digest of an executable in SHA256 format. The API supports both binary and hex digests. For JSON requests, digests are base64-encoded.
|
||||
|
||||
#[serde_as(as = "Option<::client::serde::urlsafe_base64::Wrapper>")]
|
||||
#[serde_as(as = "Option<::client::serde::standard_base64::Wrapper>")]
|
||||
pub digest: Option<Vec<u8>>,
|
||||
/// A hash prefix, consisting of the most significant 4-32 bytes of a SHA256 hash. This field is in binary format. For JSON requests, hashes are base64-encoded.
|
||||
|
||||
#[serde_as(as = "Option<::client::serde::urlsafe_base64::Wrapper>")]
|
||||
#[serde_as(as = "Option<::client::serde::standard_base64::Wrapper>")]
|
||||
pub hash: Option<Vec<u8>>,
|
||||
/// A URL.
|
||||
|
||||
@@ -600,11 +600,11 @@ impl client::Part for GoogleSecuritySafebrowsingV4ThreatEntryMetadata {}
|
||||
pub struct GoogleSecuritySafebrowsingV4ThreatEntryMetadataMetadataEntry {
|
||||
/// The metadata entry key. For JSON requests, the key is base64-encoded.
|
||||
|
||||
#[serde_as(as = "Option<::client::serde::urlsafe_base64::Wrapper>")]
|
||||
#[serde_as(as = "Option<::client::serde::standard_base64::Wrapper>")]
|
||||
pub key: Option<Vec<u8>>,
|
||||
/// The metadata entry value. For JSON requests, the value is base64-encoded.
|
||||
|
||||
#[serde_as(as = "Option<::client::serde::urlsafe_base64::Wrapper>")]
|
||||
#[serde_as(as = "Option<::client::serde::standard_base64::Wrapper>")]
|
||||
pub value: Option<Vec<u8>>,
|
||||
}
|
||||
|
||||
@@ -721,7 +721,7 @@ pub struct GoogleSecuritySafebrowsingV4ThreatHitUserInfo {
|
||||
/// Unique user identifier defined by the client.
|
||||
#[serde(rename="userId")]
|
||||
|
||||
#[serde_as(as = "Option<::client::serde::urlsafe_base64::Wrapper>")]
|
||||
#[serde_as(as = "Option<::client::serde::standard_base64::Wrapper>")]
|
||||
pub user_id: Option<Vec<u8>>,
|
||||
}
|
||||
|
||||
@@ -1299,7 +1299,7 @@ where
|
||||
}
|
||||
|
||||
let mut params = Params::with_capacity(5 + self._additional_params.len());
|
||||
params.push("encodedRequest", ::client::serde::urlsafe_base64::to_string(&self._encoded_request));
|
||||
params.push("encodedRequest", ::client::serde::standard_base64::to_string(&self._encoded_request));
|
||||
if let Some(value) = self._client_version.as_ref() {
|
||||
params.push("clientVersion", value);
|
||||
}
|
||||
@@ -1540,7 +1540,7 @@ where
|
||||
}
|
||||
|
||||
let mut params = Params::with_capacity(5 + self._additional_params.len());
|
||||
params.push("encodedRequest", ::client::serde::urlsafe_base64::to_string(&self._encoded_request));
|
||||
params.push("encodedRequest", ::client::serde::standard_base64::to_string(&self._encoded_request));
|
||||
if let Some(value) = self._client_version.as_ref() {
|
||||
params.push("clientVersion", value);
|
||||
}
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
// This file was generated automatically from 'src/generator/templates/api/lib.rs.mako'
|
||||
// DO NOT EDIT !
|
||||
|
||||
//! This documentation was generated from *Safebrowsing* crate version *5.0.3+20230108*, where *20230108* is the exact revision of the *safebrowsing:v4* schema built by the [mako](http://www.makotemplates.org/) code generator *v5.0.3*.
|
||||
//! This documentation was generated from *Safebrowsing* crate version *5.0.3+20240225*, where *20240225* is the exact revision of the *safebrowsing:v4* schema built by the [mako](http://www.makotemplates.org/) code generator *v5.0.3*.
|
||||
//!
|
||||
//! Everything else about the *Safebrowsing* *v4* API can be found at the
|
||||
//! [official documentation site](https://developers.google.com/safe-browsing/).
|
||||
|
||||
Reference in New Issue
Block a user