class UsageRule extends Message

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

Protobuf type Google\Api\UsageRule

Methods

__construct()

No description

string
getSelector()

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

setSelector(string $var)

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

bool
getAllowUnregisteredCalls()

True, if the method allows unregistered calls; false otherwise.

setAllowUnregisteredCalls(bool $var)

True, if the method allows unregistered calls; false otherwise.

bool
getSkipServiceControl()

True, if the method should skip service control. If so, no control plane feature (like quota and billing) will be enabled.

setSkipServiceControl(bool $var)

True, if the method should skip service control. If so, no control plane feature (like quota and billing) will be enabled.

Details

at line 57
__construct()

at line 70
string getSelector()

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.

Generated from protobuf field string selector = 1;

Return Value

string

at line 83
setSelector(string $var)

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.

Generated from protobuf field string selector = 1;

Parameters

string $var

at line 95
bool getAllowUnregisteredCalls()

True, if the method allows unregistered calls; false otherwise.

Generated from protobuf field bool allow_unregistered_calls = 2;

Return Value

bool

at line 106
setAllowUnregisteredCalls(bool $var)

True, if the method allows unregistered calls; false otherwise.

Generated from protobuf field bool allow_unregistered_calls = 2;

Parameters

bool $var

at line 119
bool getSkipServiceControl()

True, if the method should skip service control. If so, no control plane feature (like quota and billing) will be enabled.

Generated from protobuf field bool skip_service_control = 3;

Return Value

bool

at line 131
setSkipServiceControl(bool $var)

True, if the method should skip service control. If so, no control plane feature (like quota and billing) will be enabled.

Generated from protobuf field bool skip_service_control = 3;

Parameters

bool $var