Get Usage Metrics
get
/rest/v16/companies/usage
This endpoint returns usage metrics for a site.
Request
Query Parameters
-
q(required): string
Criteria to filter the usage statistics. Filter criteria are type (single value or multiple values using $in), company (single value only), and timestamp (start date using $gt or $gte and end date using $lt or $lte). Multiple filter criteria may be defined using $and.
Response
Supported Media Types
- application/json
Default Response
The JSON data for all usage metrics, or a subset of the usage metrics, depending on the input request.
Root Schema : usage-collection
Type:
Show Source
object
-
items:
array List of usage statistics
Title:
List of usage statistics
List of usage statistics
Nested Schema : List of usage statistics
Type:
array
Title:
List of usage statistics
List of usage statistics
Show Source
-
Array of:
object Usage
Title:
Usage
Usage data for a specific type of license
Nested Schema : Usage
Type:
object
Title:
Usage
Usage data for a specific type of license
Show Source
-
details:
array List of Partner Organization usage statistics
Title:
List of Partner Organization usage statistics
List of channel usage statistics for all Partner Organizations -
enabled:
integer
Title:
Enabled
Number of enabled Users -
exhausted:
integer
Title:
Exhausted
Number of exhausted licenses -
retention_date:
string
Title:
Retention Date
Earliest date in which Interact license usage is available -
total:
integer
Title:
Total
Number of allocated licenses -
type:
string
Title:
Type
Type of license -
usage:
number
Title:
Usage
Amount of disk space used
Nested Schema : List of Partner Organization usage statistics
Type:
array
Title:
List of Partner Organization usage statistics
List of channel usage statistics for all Partner Organizations
Show Source
-
Array of:
object Partner Organization Detail
Title:
Partner Organization Detail
Usage data for individual Partner Organization
Nested Schema : Partner Organization Detail
Type:
object
Title:
Partner Organization Detail
Usage data for individual Partner Organization
Show Source
-
company:
string
Title:
Company
Name of Partner Organization -
enabled:
integer
Title:
Enabled
Number of enabled Users -
total:
integer
Title:
Total
Number of allocated licenses
Examples
The following examples show how to search parts by submitting a GET request to the REST resource using cURL. For more information about cURL, see Use cURL.
curl - X GET - i - H "Authorization: Basic dXNlcm5hbWU6cGFzc3dvcmQg" - H "Content-type: application/json" https://sitename.oracle.com/rest/v16/companies/usage
Request Body Sample
"items": [{ "type": "internal", "total": 1000, "enabled": 540 }, { "type": "channel", "total": 1000, "enabled": 394 "details": [{ "company": "abcCompany", "total": 500, "enabled": 200 }, { "company": "defCompany", "total": 500, "enabled": 194 }, { "company": "ghiCompany", "total": -1 "enabled": 2 } }, { "type": "api", "total": 10000, "exhausted": 44938 }, { "type": "interact", "total": 1000, "exhausted": 345, "retention_date": "2021-05-17" }, { "type": "diskspace", "total": -1, "usage": 0.628 } ] }
Query Examples
- Return all license type usage information.
https://sitename.oracle.com/companies/usage?q={timestamp:{$gt:"2021-05-05",$lt:"2021-06-05"}}
- Return license usage information for multiple license types.
https://sitename.oracle.com/companies/usage?q={$and:[{type:{$in:["api","interact"]}},{timestamp:{$gt:"2021-01-05",$lt:"2021-02-05"}}]}
- Return a license usage information for a single license type.
https://sitename.oracle.com/companies/usage?q={$and:[type:"api"},{timestamp:{$gt:"2021-05-05",$lt:"2021-06-05"}}]}
- Return channel license usage information for a Partner Organization.
https://sitename.oracle.com/companies/usage?q={$and:[{type:"channel"},{company:"abcCompany"}]}
- Return disk space usage information.
https://sitename.oracle.com/companies/usage?q={"type:"diskspace"}