# Licenses These endpoints allow you to add licenses to a provider and perform license lookups. Please note that a license lookup may take some time depending on the load and performance of the external data source. It is generally recommended to wait at least 2 seconds before polling for an update or use one of the notification mechanisms we provide (TBD). License verification result will have the basic information about the license such as license number, licenseType, status, issued date, expiry date, etc. In addition, the disciplinary actions and other additional information that is captured from the source site is represented through the disciplinaryActions and additionalProperties fields. The disciplinary actions and additional properties fields describe the type of data that is getting represented and are using the [Flexible Data Model](/reference/overview/#section/Common-Concepts/Flexible-data-model). ## List provider licenses - [GET /provider-licenses](https://test-docs.discovery-staging.verifiable.com/references/development/deprecated/api/licenses/listproviderlicenses.md): Returns a page of provider licenses. ## Trigger a new license verification - [POST /providers/{providerId}/licenses/{licenseId}/verify](https://test-docs.discovery-staging.verifiable.com/references/development/deprecated/api/licenses/triggerlicenseverification.md): By executing this endpoint a new license verification is scheduled and executed for the specified license. ## Trigger license verifications - [POST /providers/{providerId}/licenses/verify](https://test-docs.discovery-staging.verifiable.com/references/development/deprecated/api/licenses/triggerlicenseverifications.md): By executing this endpoint a license verifications is scheduled and executed for specified licenses for the provider. ## Detach a license from a provider - [DELETE /providers/{providerId}/licenses/{licenseId}](https://test-docs.discovery-staging.verifiable.com/references/development/deprecated/api/licenses/detachlicense.md): This will delete the license and associated verification records for the specified provider. This will also delete any related data such as screenshots, attachments, export reports, alerts etc. ## Get a specific license from a provider - [GET /providers/{providerId}/licenses/{licenseId}](https://test-docs.discovery-staging.verifiable.com/references/development/deprecated/api/licenses/getlicense.md): Returns the data and latest verification for a specific license attached to a specific provider. ## Get a specific license verification - [GET /providers/{providerId}/licenses/{licenseId}/verifications/{verificationId}](https://test-docs.discovery-staging.verifiable.com/references/development/deprecated/api/licenses/getlicenseverification.md): Returns the data for a specific previously executed license verification. This endpoint can be used to retrieve historical results on older license verifications. ## Resolve problems with a license verification - [PATCH /providers/{providerId}/licenses/{licenseId}/verifications/{verificationId}](https://test-docs.discovery-staging.verifiable.com/references/development/deprecated/api/licenses/resolvelicenseverificationproblems.md): After a license verification is executed we sometimes are uncertain about the results we get from the source. For example when the source returns more than 1 match or the name of the license does not match the name that was used for the provider. In such cases we mark the license status as NeedsReview. It is expected that this status is resolved by the end user. The resolution can be patched by using this endpoint. ## Diff two license verifications - [GET /providers/{providerId}/licenses/{licenseId}/verifications/{verificationId}/diff](https://test-docs.discovery-staging.verifiable.com/references/development/deprecated/api/licenses/getlicenseverificationdiff.md): Returns the diff according to jsondiffpatch format between the specified verification and the previous successful verification. ## List all verifications for a license - [GET /providers/{providerId}/licenses/{licenseId}/verifications](https://test-docs.discovery-staging.verifiable.com/references/development/deprecated/api/licenses/listlicenseverifications.md): It is possible to perform more than one verification for any given license. In order to go back in history you can use this endpoint to get a list of all verifications for the specified license. ## List license types - [GET /licensetypes](https://test-docs.discovery-staging.verifiable.com/references/development/deprecated/api/licenses/listsimplifiedlicensetypes.md): Returns a list of all license types that are currently supported and used for license verifications. ## List license source status - [GET /licensetypes/status](https://test-docs.discovery-staging.verifiable.com/references/development/deprecated/api/licenses/listsimplifiedlicensetypesstatus.md): Returns the license source status information for one or more license types. ## Attach a license to a provider - [POST /providers/{providerId}/licenses](https://test-docs.discovery-staging.verifiable.com/references/development/deprecated/api/licenses/attachlicense.md): To perform a license verification you must first attach a license to a provider. The first time you do this will automatically trigger a license verification on that provider. Once attached you can reverify the same license without reattaching it. A provider can have more than one license attached. ## List all licenses from a provider - [GET /providers/{providerId}/licenses](https://test-docs.discovery-staging.verifiable.com/references/development/deprecated/api/licenses/listlicenses.md): Returns a list of all licenses previously attached to the specified provider. ## Get provider licenses aggregations - [GET /provider-licenses/aggregations](https://test-docs.discovery-staging.verifiable.com/references/development/deprecated/api/licenses/getproviderlicensesaggregations.md): Returns aggregated counts for provider licenses with different statuses. ## Patch an existing license - [PATCH /licenses/{licenseId}](https://test-docs.discovery-staging.verifiable.com/references/development/deprecated/api/licenses/patchlicense.md): Allows you to change a license's restriction or approved status.