Get a Limit Resource Availability
get
/20190729/services/{service_name}/limits/{limit_name}/resourceAvailability
For a given compartment OCID, resource limit name, and scope, return the following:The number of available resources associated with the given limit. The usage in the specified compartment for the given limit. If a subscription ID is provided, then usage for resources created in that subscription is returned.
Note that not all resource limits support this API. If the value is not available, the API returns a 404 response.
Request
Supported Media Types
- application/json
Path Parameters
-
limitName(required): string
The limit name for which to fetch the data.
-
serviceName(required): string
The service name of the target quota.
Query Parameters
-
availabilityDomain: string
This field is mandatory if the scopeType of the target resource limit is AD. Otherwise, this field should be omitted. If the above requirements are not met, the API returns a 400 - InvalidParameter response.
-
compartmentId(required): string
The OCID of the compartment for which data is being fetched.
-
subscriptionId: string
The OCID of the subscription assigned to tenant
Header Parameters
-
opc-request-id: string
Unique Oracle-assigned identifier for the request. Provide this request OCID if you need to contact Oracle about this request.
Response
Supported Media Types
- application/json
200 Response
Successfully retrieved the result for the given quota.
Headers
-
opc-request-id: string
Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, please provide the request ID.
Root Schema : ResourceAvailability
Type:
object
The availability of a given resource limit, based on the usage, tenant service limits, and quotas set for the tenancy. Note: We cannot guarantee this data for all the limits. In such cases, these fields will be empty.
Show Source
-
available:
integer(int64)
The count of available resources. To support resources with fractional counts, the field rounds down to the nearest integer.
-
effectiveQuotaValue:
number
The effective quota value for the given compartment. This field is only present if there is a current quota policy affecting the current resource in the target region or availability domain.
-
fractionalAvailability:
number
The most accurate count of available resources.
-
fractionalUsage:
number
The current most accurate usage in the given compartment.
-
used:
integer(int64)
The current usage in the given compartment. To support resources with fractional counts, the field rounds up to the nearest integer.
400 Response
A bad request was made or the request is not supported for the current tenant.
Headers
-
opc-request-id: string
Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, please provide the request ID.
Root Schema : Error
Type:
object
The properties that define an error.
Show Source
-
code(required):
string
A short error code that defines the error, meant for programmatic parsing. See [API Errors](https://docs.us-phoenix-1.oraclecloud.com/Content/API/References/apierrors.htm).
-
message(required):
string
A human-readable error string.
401 Response
User authentication has failed.
Headers
-
opc-request-id: string
Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, please provide the request ID.
Root Schema : Error
Type:
object
The properties that define an error.
Show Source
-
code(required):
string
A short error code that defines the error, meant for programmatic parsing. See [API Errors](https://docs.us-phoenix-1.oraclecloud.com/Content/API/References/apierrors.htm).
-
message(required):
string
A human-readable error string.
404 Response
Not authorized or not found.
Headers
-
opc-request-id: string
Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, please provide the request ID.
Root Schema : Error
Type:
object
The properties that define an error.
Show Source
-
code(required):
string
A short error code that defines the error, meant for programmatic parsing. See [API Errors](https://docs.us-phoenix-1.oraclecloud.com/Content/API/References/apierrors.htm).
-
message(required):
string
A human-readable error string.
429 Response
You have issued too many requests to the Oracle Cloud Infrastructure APIs in too short of an amount of time.
Headers
-
opc-request-id: string
Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, please provide the request ID.
Root Schema : Error
Type:
object
The properties that define an error.
Show Source
-
code(required):
string
A short error code that defines the error, meant for programmatic parsing. See [API Errors](https://docs.us-phoenix-1.oraclecloud.com/Content/API/References/apierrors.htm).
-
message(required):
string
A human-readable error string.
500 Response
Internal server error.
Headers
-
opc-request-id: string
Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, please provide the request ID.
Root Schema : Error
Type:
object
The properties that define an error.
Show Source
-
code(required):
string
A short error code that defines the error, meant for programmatic parsing. See [API Errors](https://docs.us-phoenix-1.oraclecloud.com/Content/API/References/apierrors.htm).
-
message(required):
string
A human-readable error string.
Default Response
An error has occurred.
Headers
-
opc-request-id: string
Unique Oracle-assigned identifier for the request. If you need to contact Oracle about a particular request, please provide the request ID.
Root Schema : Error
Type:
object
The properties that define an error.
Show Source
-
code(required):
string
A short error code that defines the error, meant for programmatic parsing. See [API Errors](https://docs.us-phoenix-1.oraclecloud.com/Content/API/References/apierrors.htm).
-
message(required):
string
A human-readable error string.