Struct gapi_grpc::google::api::UsageRule[][src]

pub struct UsageRule {
    pub selector: String,
    pub allow_unregistered_calls: bool,
    pub skip_service_control: bool,
}

Usage configuration rules for the service.

NOTE: Under development.

Use this rule to configure unregistered calls for the service. Unregistered calls are calls that do not contain consumer project identity. (Example: calls that do not contain an API key). By default, API methods do not allow unregistered calls, and each method call must be identified by a consumer project identity. Use this rule to allow/disallow unregistered calls.

Example of an API that wants to allow unregistered calls for entire service.

usage:
  rules:
  - selector: "*"
    allow_unregistered_calls: true

Example of a method that wants to allow unregistered calls.

usage:
  rules:
  - selector: "google.example.library.v1.LibraryService.CreateBook"
    allow_unregistered_calls: true

Fields

selector: String

Selects the methods to which this rule applies. Use ‘*’ to indicate all methods in all APIs.

Refer to [selector][google.api.DocumentationRule.selector] for syntax details.

allow_unregistered_calls: bool

If true, the selected method allows unregistered calls, e.g. calls that don’t identify any user or application.

skip_service_control: bool

If true, the selected method should skip service control and the control plane features, such as quota and billing, will not be available. This flag is used by Google Cloud Endpoints to bypass checks for internal methods, such as service health check methods.

Trait Implementations

impl Clone for UsageRule[src]

impl Debug for UsageRule[src]

impl Default for UsageRule[src]

impl Message for UsageRule[src]

impl PartialEq<UsageRule> for UsageRule[src]

impl StructuralPartialEq for UsageRule[src]

Auto Trait Implementations

impl RefUnwindSafe for UsageRule

impl Send for UsageRule

impl Sync for UsageRule

impl Unpin for UsageRule

impl UnwindSafe for UsageRule

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T> Instrument for T[src]

impl<T> Instrument for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> IntoRequest<T> for T[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<V, T> VZip<V> for T where
    V: MultiLane<T>, 
[src]

impl<T> WithSubscriber for T[src]