public virtual Task<AllocateQuotaResponse> AllocateQuota(AllocateQuotaRequest request, ServerCallContext context)
Attempts to allocate quota for the specified consumer. It should be called
before the operation is executed.
This method requires the servicemanagement.services.quota
permission on the specified service. For more information, see
Cloud IAM.
NOTE: The client must fail-open on server errors INTERNAL,
UNKNOWN, DEADLINE_EXCEEDED, and UNAVAILABLE. To ensure system
reliability, the server may inject these errors to prohibit any hard
dependency on the quota functionality.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-08-07 UTC."],[[["The latest version of the `QuotaControllerBase` is 2.4.0, with older versions available down to 1.0.0."],["`QuotaControllerBase` is a base class for server-side implementations of `QuotaController`, inheriting from the `Object` class."],["The `AllocateQuota` method attempts to allocate quota for a consumer and should be called before an operation is executed, requiring the `servicemanagement.services.quota` permission."],["The `AllocateQuota` method accepts an `AllocateQuotaRequest` and `ServerCallContext` as parameters, returning a `Task\u003cAllocateQuotaResponse\u003e`."],["The server may inject errors like `INTERNAL`, `UNKNOWN`, `DEADLINE_EXCEEDED`, and `UNAVAILABLE` to ensure system reliability."]]],[]]