Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

ParameterRequiredTypeDescription
${featureId}Yesinteger

Specifies ID of the feature for which you want to view denied requests.

${returnType}YesstringSpecifies the format in which the data should be returned. The format can be one of the following: json, csv, xls or pdf.
sdYesstringSpecifies the starting date from which you want to generate the report. The date and time format is YYYY-MM-DD; for example, 2017-01-20.
ed

Yes

stringSpecifies the end date from which you want to generate the report. The date and time format is YYYY-MM-DD; for example, 2017-01-20. The date is inclusive, meaning that all data from a particular day will be included in the report.
fieldsVisibility Nojson/string

Specifies field visibility settings, for example:

Code Block
languagejs
firstline1
linenumberstrue
{"un": "1", "hn": "1", "ldt": "1", "ldtc":"1"}

where number "1" indicates that a specific field is visible.
Note that the order of the settings you make is important – when exported, the fields will be visible in exactly the same order you specify here.

rnNostringSpecifies the name of the report that will be displayed once the report has been exported to PDF or XLS. For CSV and JSON formats this parameter will be ignored.
If you don't pass this parameter, it will be generated automatically for PDF and XLS types. If provided, it cannot be left empty.
filterNojson/string

Applies filtering license usage data on all fields.

To filter by string column, use the following format:

Code Block
languagejs
firstline1
linenumberstrue
[
	{ 
		"type": "string",
		"field": "${un | hn | ldt}",
		"value": "${value}"
	}
]
To filter by numeric column, use the following format: 
Code Block
languagejs
firstline1
[
	{ 
		"type": "numeric", 
		"comparison": "${gt | lt | eq}", 
		"field": "ldtc",
		"value": "${value}" 
	}
]
limitNointegerDetermines the maximum number of data records that can be returned. The value must be greater than zero.
offsetNointegerSpecifies the offset of the first row to return.
orderByNostring

Specifies the field by which you want to order your data records. The field name can be one of the following: un, hn, ldt, ldtc.

orderDirectionNostringDetermines whether the sorting results will be displayed in an ascending (ASC) or a descending (DESC) order.

...

FieldTypeDescription

un

string

Username.

hn

string

Hostname.

ldt

string

License Denial Time in YYYY-MM-DD format

 Date on which the denial took place in YYYY-MM-DD format?.

ldtc

string

Total number of denied license checkout requests.License Denial Total Count.

msg

string

Error message returned on failure.

success

boolean

Indicates whether the API request was successfully processed. 

codeinteger

Error code if success == falseError code for unsuccessful request.?

totalCountinteger

Total number of all matching results.

Count of all matching results.


Example 1

Say you would like to view denials for feature 3 over some period of time. To generate such data, enter a command similar to the following:

...

Code Block
languagejs
firstline1
linenumberstrue
curl --data "orderBy=un" --data "orderDirection=ASC" --data "sd=2015-01-01" --data "ed=2015-01-02" -H "X-Auth-token: token" "http://yourdomain/api/v1/report/feature/3/denials/json"

Example 3

Let's say Say you're interested in viewing the first 100 denials for feature 3 over a specific period of time. To do this, enter a command that is similar to the following:

Code Block
languagejs
firstline1
linenumberstrue
curl --data "limit=100" --data "offset=0" --data "sd=2015-01-01" --data "ed=2015-01-02" -H "X-Auth-token: token" "http://yourdomain/api/v1/report/feature/3/denials/json"

...

json"


Keep in mind that you can also put parameters directly into the URL, e.g. to generate data for the above example, the command would look like this:

Code Block
languagejs
firstline1
linenumberstrue
curl -H "X-Auth-token: token" "http://yourdomain/api/v1/report/feature/3/denials/json?limit=100&offset=0&sd=2014-12-01&ed=2015-01-02"

...

FieldTypeDescription

ldt

string

Indicates period of time for which usage information is generated, i.e. date and time for hourly usage and dates for the remaining granularity options.

ldtc

string

License Denial Total CountTotal number of denied license checkout requests.

msg

string

Error message returned on failure.

success

boolean

Indicates if the API request was successfully processed.

msg

string

Error message returned on failure.

codeinteger

Error code if success == falseError code for unsuccessful request.?

totalCountintegerCount of all matching results.Total number of denied license checkout requests.


Example 1

Say you would like to view denials for feature 3 grouped by month. To generate such data, enter a command similar to this one:

...

Code Block
languagejs
firstline1
linenumberstrue
curl --data "limit=100" --data "offset=0" --data "sd=2013-01-01" --data "ed=2015-01-02" --data "grat=6" -H "X-Auth-token: token" "http://yourdomain/api/v1/report/feature/3/denials/grouped/json"

...

Keep in mind that you can also put parameters directly into the URL, e.g. to generate data for the above example, the command would look like this:

Code Block
languagejs
firstline1
linenumberstrue
curl -H "X-Auth-token: token" "http://yourdomain/api/v1/report/feature/3/denials/grouped/json?limit=5&offset=2&sd=2013-01-01&ed=2015-01-02&grat=6"