Updates to Existing APIs
The following section describes updates that have occurred to existing APIs in this release.
Resource |
API Name/Endpoint |
Method |
Function Change Description |
Component |
Get Component version details /components/versions/{Id} |
GET |
The property userPreferredLicense has been added to details for each license associated with a given component version in the response. The true or false response for the property indicates whether the license is user-preferred—that is, selected by a user to be mapped to all future inventory generated by the system for the version. For more information, see Support for “user-preferred” License Mappings for Future Inventory. The following shows this property in an example Get Component version details response: { "data": { "id": 1122344, "name": "2.5.1", "componentId": 3243434, "licenses": [ { "id": "1313", "name": "BSD-Style License", "userPreferredLicense": true }... The following shows this property in an example Get Component response: "versionList": [ { "id": 16016865, "name": "3.6.1p2", "custom": false, "versionLicenses": [ { "id": 1916, "name": "389 Directory Server "shortName": "389-exception", "priority": "P3", "url": "https://spdx.org/licenses/389- "description": "", "familyName": null, "custom": false, "externalId": "", "userPreferredLicense": true }... |
Get Component /components/{componentId} |
|||
Inventory |
Get the inventories of file/folder Ids /inventories/search |
GET |
The inventory details returned in response now list the property dependencyScope, indicating whether the inventory item is a dependency required at runtime (Runtime) or not required at runtime (Non Runtime). The N/A value indicates that the inventory item cannot be classified as a runtime or non-runtime dependency. Such items include top-level inventory, dependencies for which Code Insight does not currently support the reporting of scope, and migrated inventory for which a scan has not been run. |
Get details of an inventory /inventories/{inventoryId} |
|||
Jobs |
Get jobs details based on filters /jobs |
GET |
Job details now include a new server property that provides the internal ID and alias of the server that performed the job. Note that for scans, the scan server’s alias is listed. For jobs performed on the Code Insight Core Server, the alias is Core Server. "server": { "id": 2, "aliasName": "scanner36" }, ... "server": { "id": 1, "aliasName": "Core Server" }, ... |
Get server information based on the jobId provided /jobs/{jobId} |
|||
The jobType property in the returned details for a Code Insight custom report now shows the actual name of the report. Additionally, the names of all reports—custom and standard—are prefaced with “Report -” (for example, "Report - Project Report"). |
|||
Remote Scan has been included as a new jobType. A job of this type is available in the Jobs queue as soon as the scan results from a scan agent plugin have been successfully sent to Code Insight for processing. The processing is then run in the background and tracked in the Jobs queue. |
|||
Project Import has been included is included as a new jobType so that project imports can run in the background and be tracked on the Jobs queue. |
|||
Project API |
Get Project Inventory /project/inventory/{projectID} |
GET |
The inventory details returned in response now list the property dependencyScope, indicating whether the inventory item is a dependency required at runtime (Runtime) or not required at runtime (Non Runtime). The N/A value indicates that the inventory item cannot be classified as a runtime or non-runtime dependency. Such items include top-level inventory, dependencies for which Code Insight does not currently support the reporting of scope, and migrated inventory for which a scan has not been run. |
Rules |
Get Rules /rules |
GET |
The response includes the new inventoryName property that has been added to the custom rule definition. This property shows the custom name that is given to the inventory items created by the rule. The custom name overwrites the default component version (license) name that the rule normally assigns to the inventory item. If no inventoryName value has been defined, the property shows N/A. Inventory items created by the rule are assigned the default name when no custom name is specified. |
Get Rule By Id /rules/{ruleId} |
|||
Create Rule /rules |
POST |
The request includes the new inventoryName property that has been added to the custom rule definition. This property enables you to specify a custom name (or update an existing one) that will be given to any new inventory items created by the rule. The custom name overwrites the default component version (license) name that the rule normally assigns to the inventory items it creates. If no inventoryName value is defined for the rule, the property shows N/A whenever the rule details are retrieved. Inventory items created by a rule are assigned the default name when no custom name is specified. |
|
Update Rule /rules |
PUT |