Open topic with navigation

# Get Licenses by Query

## Description

Returns a list of LoadRunner Enterprise licenses by query (filter).

## URL

    /Admin/rest/v1/licenses?query={<QUERY_NAME>["<YOUR_QUERY_VALUE>"]}

## License Query Values

QUERY_NAME options

-     ID

- `LicenseType` (previously `Type` in LoadRunner Enterprise 12.6x and earlier versions)

-     AssignedDate

-     FactoryLicense

-     ConcurrentRuns

-     ExpirationDate

-     ValidFromDate

-     Vusers

## Remarks

The license data can be passed as XML containing the equivalent data.

## HTTP Method

GET: Returns a list of licenses by query.

## Request

Headers:

Content-Type: application/xml

Accept: application/xml

Cookies:

Version 2020 (or later) | LWSSO_COOKIE_KEY={LwssoCookie};
Versions earlier than 2020 | LWSSO_COOKIE_KEY={LwssoCookie};QCSession={QCSessionCookie};

Request Body:

None

Request Example

    GET http://<LRE_Server>/Admin/rest/v1/licenses?query={ExpirationDate[<='2050-12-01%2000:00:00']}
    Content-Type: application/xml
    Accept: application/xml
    Cookie: LWSSO_COOKIE_KEY={LwssoCookie};

## Response

Headers:

Content-Type: application/xml

Cookies:

None

HTML Return Code:

One of the HTTP Return Codes.

HTML Body:

GET: Returns the data on the entity in the response. See license response.

## See Also

licenses (Get licenses)
licenses/{licenseID}
licenses (Get license summary)