Polarex.LicenseKeys (Polarex v0.2.8)
View SourceProvides API endpoints related to license keys
Summary
Functions
Activate License Key
Deactivate License Key
Get License Key
List License Keys
Validate License Key
Activate License Key
Deactivate License Key
Get License Key
Get Activation
List License Keys
Update License Key
Validate License Key
Functions
@spec customer_portal_license_keys_activate( Polarex.LicenseKeyActivate.t(), keyword() ) :: {:ok, Polarex.LicenseKeyActivationRead.t()} | {:error, Polarex.HTTPValidationError.t() | Polarex.NotPermitted.t() | Polarex.ResourceNotFound.t()}
Activate License Key
Activate a license key instance.
This endpoint doesn't require authentication and can be safely used on a public client, like a desktop application or a mobile app. If you plan to validate a license key on a server, use the
/v1/license-keys/activateendpoint instead.
@spec customer_portal_license_keys_deactivate( Polarex.LicenseKeyDeactivate.t(), keyword() ) :: :ok | {:error, Polarex.HTTPValidationError.t() | Polarex.ResourceNotFound.t()}
Deactivate License Key
Deactivate a license key instance.
This endpoint doesn't require authentication and can be safely used on a public client, like a desktop application or a mobile app. If you plan to validate a license key on a server, use the
/v1/license-keys/deactivateendpoint instead.
@spec customer_portal_license_keys_get( String.t(), keyword() ) :: {:ok, Polarex.LicenseKeyWithActivations.t()} | {:error, Polarex.HTTPValidationError.t() | Polarex.ResourceNotFound.t()}
Get License Key
Get a license key.
Scopes: customer_portal:read customer_portal:write
@spec customer_portal_license_keys_list(keyword()) :: {:ok, Polarex.ListResourceLicenseKeyRead.t()} | {:error, Polarex.HTTPValidationError.t() | Polarex.ResourceNotFound.t() | Polarex.Unauthorized.t()}
List License Keys
Scopes: customer_portal:read customer_portal:write
Options
benefit_id: Filter by a specific benefitpage: Page number, defaults to 1.limit: Size of a page, defaults to 10. Maximum is 100.
@spec customer_portal_license_keys_validate( Polarex.LicenseKeyValidate.t(), keyword() ) :: {:ok, Polarex.ValidatedLicenseKey.t()} | {:error, Polarex.HTTPValidationError.t() | Polarex.ResourceNotFound.t()}
Validate License Key
Validate a license key.
This endpoint doesn't require authentication and can be safely used on a public client, like a desktop application or a mobile app. If you plan to validate a license key on a server, use the
/v1/license-keys/validateendpoint instead.
@spec license_keys_activate( Polarex.LicenseKeyActivate.t(), keyword() ) :: {:ok, Polarex.LicenseKeyActivationRead.t()} | {:error, Polarex.HTTPValidationError.t() | Polarex.NotPermitted.t() | Polarex.ResourceNotFound.t()}
Activate License Key
Activate a license key instance.
Scopes: license_keys:write
@spec license_keys_deactivate( Polarex.LicenseKeyDeactivate.t(), keyword() ) :: :ok | {:error, Polarex.HTTPValidationError.t() | Polarex.ResourceNotFound.t()}
Deactivate License Key
Deactivate a license key instance.
Scopes: license_keys:write
@spec license_keys_get( String.t(), keyword() ) :: {:ok, Polarex.LicenseKeyWithActivations.t()} | {:error, Polarex.HTTPValidationError.t() | Polarex.ResourceNotFound.t() | Polarex.Unauthorized.t()}
Get License Key
Get a license key.
Scopes: license_keys:read license_keys:write
@spec license_keys_get_activation(String.t(), String.t(), keyword()) :: {:ok, Polarex.LicenseKeyActivationRead.t()} | {:error, Polarex.HTTPValidationError.t() | Polarex.ResourceNotFound.t() | Polarex.Unauthorized.t()}
Get Activation
Get a license key activation.
Scopes: license_keys:read license_keys:write
@spec license_keys_list(keyword()) :: {:ok, Polarex.ListResourceLicenseKeyRead.t()} | {:error, Polarex.HTTPValidationError.t() | Polarex.ResourceNotFound.t() | Polarex.Unauthorized.t()}
List License Keys
Get license keys connected to the given organization & filters.
Scopes: license_keys:read license_keys:write
Options
organization_id: Filter by organization ID.benefit_id: Filter by benefit ID.page: Page number, defaults to 1.limit: Size of a page, defaults to 10. Maximum is 100.
@spec license_keys_update(String.t(), Polarex.LicenseKeyUpdate.t(), keyword()) :: {:ok, Polarex.LicenseKeyRead.t()} | {:error, Polarex.HTTPValidationError.t() | Polarex.ResourceNotFound.t() | Polarex.Unauthorized.t()}
Update License Key
Update a license key.
Scopes: license_keys:write
@spec license_keys_validate( Polarex.LicenseKeyValidate.t(), keyword() ) :: {:ok, Polarex.ValidatedLicenseKey.t()} | {:error, Polarex.HTTPValidationError.t() | Polarex.ResourceNotFound.t()}
Validate License Key
Validate a license key.
Scopes: license_keys:write