Search documentation of polar_express

# PolarExpress.Services.LicenseKeysService (polar_express v0.1.5)

Copy Markdown View Source

LicenseKeys

LicenseKeys API operations.

## Summary

### Functions

activate_license_key(client, params \\ %{}, opts \\ [])

Activate License Key

deactivate_license_key(client, params \\ %{}, opts \\ [])

Deactivate License Key

get_activation(client, id, activation_id, params \\ %{}, opts \\ [])

Get Activation

get_license_key(client, id, params \\ %{}, opts \\ [])

Get License Key

list_license_keys(client, params \\ %{}, opts \\ [])

List License Keys

update_license_key(client, id, params \\ %{}, opts \\ [])

Update License Key

validate_license_key(client, params \\ %{}, opts \\ [])

Validate License Key

## Functions

# activate_license_key(client, params \\ %{}, opts \\ [])

    @spec activate_license_key(PolarExpress.Client.t(), map(), keyword()) ::
      {:ok, PolarExpress.Schemas.LicenseKeyActivationRead.t()}
      | {:error, PolarExpress.Error.t()}

Activate License Key

Activate a license key instance.

Scopes: `license_keys:write`

See `PolarExpress.Params.LicenseKeysActivateLicenseKeyParams` for parameter details.

# deactivate_license_key(client, params \\ %{}, opts \\ [])

    @spec deactivate_license_key(PolarExpress.Client.t(), map(), keyword()) ::
      {:ok, term()} | {:error, PolarExpress.Error.t()}

Deactivate License Key

Deactivate a license key instance.

Scopes: `license_keys:write`

See `PolarExpress.Params.LicenseKeysDeactivateLicenseKeyParams` for parameter details.

# get_activation(client, id, activation_id, params \\ %{}, opts \\ [])

    @spec get_activation(
      PolarExpress.Client.t(),
      String.t(),
      String.t(),
      map(),
      keyword()
    ) ::
      {:ok, PolarExpress.Schemas.LicenseKeyActivationRead.t()}
      | {:error, PolarExpress.Error.t()}

Get Activation

Get a license key activation.

Scopes: `license_keys:read` `license_keys:write`

See `PolarExpress.Params.LicenseKeysGetActivationParams` for parameter details.

# get_license_key(client, id, params \\ %{}, opts \\ [])

    @spec get_license_key(PolarExpress.Client.t(), String.t(), map(), keyword()) ::
      {:ok, PolarExpress.Schemas.LicenseKeyWithActivations.t()}
      | {:error, PolarExpress.Error.t()}

Get License Key

Get a license key.

Scopes: `license_keys:read` `license_keys:write`

See `PolarExpress.Params.LicenseKeysGetLicenseKeyParams` for parameter details.

# list_license_keys(client, params \\ %{}, opts \\ [])

    @spec list_license_keys(PolarExpress.Client.t(), map(), keyword()) ::
      {:ok, PolarExpress.ListObject.t()} | {:error, PolarExpress.Error.t()}

List License Keys

Get license keys connected to the given organization & filters.

Scopes: `license_keys:read` `license_keys:write`

See `PolarExpress.Params.LicenseKeysListLicenseKeysParams` for parameter details.

# update_license_key(client, id, params \\ %{}, opts \\ [])

    @spec update_license_key(PolarExpress.Client.t(), String.t(), map(), keyword()) ::
      {:ok, PolarExpress.Schemas.LicenseKeyRead.t()}
      | {:error, PolarExpress.Error.t()}

Update License Key

Update a license key.

Scopes: `license_keys:write`

See `PolarExpress.Params.LicenseKeysUpdateLicenseKeyParams` for parameter details.

# validate_license_key(client, params \\ %{}, opts \\ [])

    @spec validate_license_key(PolarExpress.Client.t(), map(), keyword()) ::
      {:ok, PolarExpress.Schemas.ValidatedLicenseKey.t()}
      | {:error, PolarExpress.Error.t()}

Validate License Key

Validate a license key.

Scopes: `license_keys:write`

See `PolarExpress.Params.LicenseKeysValidateLicenseKeyParams` for parameter details.