GET /api/apps/versions/{AppVersionID}/licensereport

Returns the report definition relating to licenses for the specified app version, for the specified ReportType.

Authorization Roles/Permissions: Must be logged in. Must be a user with Monitor permission for the app; an App team member, Business Admin, or API Admin for an API that has a contract with the app.

This topic includes the following sections:

HTTP Method

GET

Back to top

URL

https://{hostname}/api/apps/versions/{AppVersionID}/licensereport

Back to top

Sample Request

The example below shows a request for a specific license report for the specified app version.

Request URL

https://{hostname}/api/apps/apps/versions/3Bq6K4CcMGb6YYpaMxJ2miAk.acmepaymentscorp/licensereport?ReportType=app.usage.api.quotas

Sample request headers

Accept: application/json
X-Csrf-Token_acmepaymentscorp":"TokenID%3D8ed70a13-8469-11e8-b37a-b155e4eabeb8%2CexpirationTime%3D153...

Sample request body

Not applicable.

Back to top

Request Headers

For general information on request header values, refer to HTTP Request Headers.

Header Description
Accept

application/json, application/xml

application/vnd.soa.v71+json, application/vnd.soa.v71+xml

application/vnd.soa.v72+json, application/vnd.soa.v72+xml

application/vnd.soa.v80+json, application/vnd.soa.v80+xml

application/vnd.soa.v81+json, application/vnd.soa.v81+xml

X-Csrf-Token_{fedmemberID} The CSRF prevention header; may or may not be required, depending on platform settings. See CSRF Prevention on the Platform. By default, the CSRF header is not required for GET operations and is required for all others, with a few exceptions relating to user login.

Back to top

Request Parameters

Parameter Parm Type Data Type Required Description
AppVersionID Query string Required The unique ID for a specific app version.
LicenseID Query string Optional The unique ID for a specific license.
ApiVersionID Path string Optional The unique ID for a specific API version.
MetricName Query string Optional The name for a specific metric.
ReportType Query string Required The type of metric information used in the license report. For valid values, see ReportType: License Report.
Environment Query string Optional The environment (implementation) (Sandbox or Production). If not specified, defaults to Production.
StartDate Query string Optional The beginning point for the date range of metric information requested. Format: YYYY-MM-DD:THH:MM:SS. Example: StartDate=2011-01-01T11:55:22. If StartDate is not specified, the operation uses EndDate minus Duration. If both StartDate and EndDate are unspecified, the operation returns information for the Duration value, and if Duration is also unspecified it returns default Duration value of 2 hours.
EndDate Query string Optional The ending point for the date range of metric information requested. Format: YYYY-MM-DD:THH:MM:SS. Example: EndDate=2011-01-02T11:55:22. If not specified, defaults to the current date/time of the API call.
TimeZone Query string Optional The time zone for the information. If a time zone isn't specified, the information is returned in GMT. For more information, refer to Working with Time Zones and Time Intervals.
Duration Query string Optional The duration for the metric information. If not specified, defaults to one day (1d). The StartDate, EndDate, and Duration fields work together to define the information to be returned.

Back to top

Response

If successful, this operation returns HTTP status code 200, with the information for the license report.

Back to top

Sample Response

The sample response below returns information for the app.usage.api.quotas report.

Sample response headers: application/json

Status Code: 200 OK
Content-Type: application/json
Expires: Wed, 22 Apr 2015 19:29:14 GMT

Sample response body: application/json

{
  "ReferencedObjects" : {
    "APIVersion" : [ {
      "APIVersionID" : "8cd656b4-a585-4e79-b669-db693fca46cf.acmepaymentscorp",
      "APIID" : "02b2c3c9-90c0-4dce-8b3a-71f578c19ba0.acmepaymentscorp",
      "Name" : "v2",
      "Description" : "v2",
      "Type" : "shttp",
      "Tag" : [ "payments" ],
      "Visibility" : "Public",
      "Created" : "2015-04-22T19:48:47Z",
      "Updated" : "2015-04-23T00:13:42Z",
      "State" : "com.soa.api.state.open",
      "ProductionEndpointAccessAutoApproved" : true,
      "SandboxEndpointAccessAutoApproved" : true,
      "SandboxAnonymousAccessAllowed" : false,
      "ProductionAnonymousAccessAllowed" : false,
      "ResourceLevelPermissionsSupported" : true,
      "APIOwnedImplementations" : true,
      "ProductionServiceKey" : "uddi:976acd47-e928-11e4-bbb3-cf1bd1a9e489",
      "SandboxServiceKey" : "uddi:98b88338-e928-11e4-bbb3-cf1bd1a9e489"
    } ],
    "ApplicationVersion" : [ {
      "RuntimeID" : "3Bq6K4CcMGb6YYpaMxJ2miAk.acmepaymentscorp",
      "AppID" : "5d31dd70-a68a-424b-a9fc-3108587f5c20.acmepaymentscorp",
      "Name" : "1.0",
      "Description" : "s",
      "WebsiteAddress" : "",
      "Visibility" : "Public",
      "InitialEnvironment" : "Sandbox",
      "CurrentEnvironment" : "Sandbox",
      "Tag" : [ ],
      "HasKeyInfo" : false,
      "Created" : "2015-04-22T14:22:11Z",
      "Updated" : "2015-04-23T00:12:00Z",
      "State" : "com.soa.app.state.review",
      "SecurityMechanisms" : [ "com.soa.security.mechanism.sharedsecret" ],
      "Identity" : "acmepaymentscorp-3Bq6K4CcMGb6YYpaMxJ2miAk"
    } ],
    "Application" : [ {
      "AppID" : "5d31dd70-a68a-424b-a9fc-3108587f5c20.acmepaymentscorp",
      "Name" : "crosfhocal",
      "Description" : "s",
      "Visibility" : "Public",
      "DefaultVersionID" : "3Bq6K4CcMGb6YYpaMxJ2miAk.acmepaymentscorp",
      "IsFollowed" : true,
      "State" : "com.soa.app.state.active",
      "Created" : "2015-04-22T14:22:11Z",
      "Updated" : "2015-04-23T00:12:00Z",
      "AvatarURL" : "http://{hostname}/api/apps/5d31dd70-a68a-424b-a9fc-3108587f5c20.acmepaymentscorp/avatar",
      "TeamID" : "appteam-5d31dd70-a68a-424b-a9fc-3108587f5c20.acmepaymentscorp"
    } ]
  }
}

Back to top

Sample response headers: application/xml

Status Code: 200 OK
Content-Type: application/xml
Expires: Wed, 22 Apr 2015 19:31:25 GMT

Sample response body: application/xml

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<Report xmlns="http://soa.com/xsd/performance/1.0" xmlns:ns2="http://soa.com/xsd/business/1.0" 
xmlns:ns3="http://soa.com/xsd/contract/1.0" xmlns:ns4="http://soa.com/xsd/api/1.0" 
xmlns:ns5="http://soa.com/xsd/app/1.0" xmlns:ns6="http://soa.com/xsd/legals/1.0" 
xmlns:ns7="http://soa.com/xsd/dnmodel/1.0" xmlns:ns8="http://soa.com/xsd/resource/1.0">
  <ReferencedObjects>
    <ns4:APIVersion>
      <ns4:APIVersionID>8cd656b4-a585-4e79-b669-db693fca46cf.acmepaymentscorp</ns4:APIVersionID>
      <ns4:APIID>02b2c3c9-90c0-4dce-8b3a-71f578c19ba0.acmepaymentscorp</ns4:APIID>
      <ns4:Name>v2</ns4:Name>
      <ns4:Description>v2</ns4:Description>
      <ns4:Type>shttp</ns4:Type>
      <ns4:Tag>payments</ns4:Tag>
      <ns4:Visibility>Public</ns4:Visibility>
      <ns4:Created>2015-04-22T19:48:47Z</ns4:Created>
      <ns4:Updated>2015-04-23T00:13:42Z</ns4:Updated>
      <ns4:State>com.soa.api.state.open</ns4:State>
      <ns4:ProductionEndpointAccessAutoApproved>true</ns4:ProductionEndpointAccessAutoApproved>
      <ns4:SandboxEndpointAccessAutoApproved>true</ns4:SandboxEndpointAccessAutoApproved>
      <ns4:SandboxAnonymousAccessAllowed>false</ns4:SandboxAnonymousAccessAllowed>
      <ns4:ProductionAnonymousAccessAllowed>false</ns4:ProductionAnonymousAccessAllowed>
      <ns4:ResourceLevelPermissionsSupported>true</ns4:ResourceLevelPermissionsSupported>
      <ns4:APIOwnedImplementations>true</ns4:APIOwnedImplementations>
      <ns4:ProductionServiceKey>uddi:976acd47-e928-11e4-bbb3-cf1bd1a9e489</ns4:ProductionServiceKey>
      <ns4:SandboxServiceKey>uddi:98b88338-e928-11e4-bbb3-cf1bd1a9e489</ns4:SandboxServiceKey>
    </ns4:APIVersion>
    <ns5:ApplicationVersion>
      <ns5:RuntimeID>3Bq6K4CcMGb6YYpaMxJ2miAk.acmepaymentscorp</ns5:RuntimeID>
      <ns5:AppID>5d31dd70-a68a-424b-a9fc-3108587f5c20.acmepaymentscorp</ns5:AppID>
      <ns5:Name>1.0</ns5:Name>
      <ns5:Description>s</ns5:Description>
      <ns5:WebsiteAddress></ns5:WebsiteAddress>
      <ns5:Visibility>Public</ns5:Visibility>
      <ns5:InitialEnvironment>Sandbox</ns5:InitialEnvironment>
      <ns5:CurrentEnvironment>Sandbox</ns5:CurrentEnvironment>
      <ns5:HasKeyInfo>false</ns5:HasKeyInfo>
      <ns5:Created>2015-04-22T14:22:11Z</ns5:Created>
      <ns5:Updated>2015-04-23T00:12:00Z</ns5:Updated>
      <ns5:State>com.soa.app.state.review</ns5:State>
      <ns5:SecurityMechanisms>com.soa.security.mechanism.sharedsecret</ns5:SecurityMechanisms>
      <ns5:Identity>acmepaymentscorp-3Bq6K4CcMGb6YYpaMxJ2miAk</ns5:Identity>
    </ns5:ApplicationVersion>
    <ns5:Application>
      <ns5:AppID>5d31dd70-a68a-424b-a9fc-3108587f5c20.acmepaymentscorp</ns5:AppID>
      <ns5:Name>crosfhocal</ns5:Name>
      <ns5:Description>s</ns5:Description>
      <ns5:Visibility>Public</ns5:Visibility>
      <ns5:DefaultVersionID>3Bq6K4CcMGb6YYpaMxJ2miAk.acmepaymentscorp</ns5:DefaultVersionID>
      <ns5:IsFollowed>true</ns5:IsFollowed>
      <ns5:State>com.soa.app.state.active</ns5:State>
      <ns5:Created>2015-04-22T14:22:11Z</ns5:Created>
      <ns5:Updated>2015-04-23T00:12:00Z</ns5:Updated>
      <ns5:AvatarURL>http://{hostname}/api/apps/5d31dd70-a68a-424b-a9fc-3108587f5c20.acmepaymentscorp/avatar</ns5:AvatarURL>
      <ns5:TeamID>appteam-5d31dd70-a68a-424b-a9fc-3108587f5c20.acmepaymentscorp</ns5:TeamID>
    </ns5:Application>
  </ReferencedObjects>
</Report>

Back to top

Response Headers

For general information on response header values, refer to HTTP Response Headers.

Header Description
Content-Type

application/json, application/xml

application/vnd.soa.v71+json, application/vnd.soa.v71+xml

application/vnd.soa.v72+json, application/vnd.soa.v72+xml

application/vnd.soa.v80+json, application/vnd.soa.v80+xml

application/vnd.soa.v81+json, application/vnd.soa.v81+xml

Back to top

Response Body

Name Type Description
Report Report Contains information about a performance report for an app or API.

Back to top

Error Codes/Messages

If the call is unsuccessful an error code/message is returned. One or more examples of possible errors for this operation are shown below.

Item Value
400 Bad request: Returned if the client sends invalid parameters or body content. For example, you might get this response if you didn't include the required ReportType parameter in the request.
401 Unauthorized. For example, you would get this response if you didn't include the custom X-Csrf-Token_{fedmemberID} header in the request, when it was required by the platform settings; or if you included an invalid or expired value for this header. You would also get this response for any operation that requires login (almost all) if the login cookie was missing.
500 An error occurred processing the call.

More information about Akana API Platform API error messages.

Back to top

Related Topics