Liking cljdoc? Tell your friends :D

goog.workspace.licensing

Clojure wrapper for the Google Apps Licensing API.

Provides idiomatic Clojure functions for reading per-user Workspace SKU assignments (Business Standard, Enterprise, Plus, etc.).

Auth: use csl/scoped-delegated-credentials with the appropriate scope and a super-admin impersonation target:

  • LicensingScopes/APPS_LICENSING (read + write — see SCOPE NOTE below)

All list functions return {:data [...] :next-page-token "..."}. :next-page-token is absent when there are no further pages.

SCOPE NOTE apps.licensing is the only scope exposed by Google for this API; it grants read + write. This wrapper only exposes list/get (LicenseAssignments). Write counterparts (insert, update, delete, transfer) are intentionally not wrapped here; a future write consumer files its own FR.

Workspace product/SKU id strings (e.g. product "Google-Apps", SKU "Google-Apps-For-Business") are documented externally by Google's Workspace SKU catalog. The wrapper passes them through unchanged.

All functions return {:data ...} on success or {:error ...} on failure.

Clojure wrapper for the Google Apps Licensing API.

Provides idiomatic Clojure functions for reading per-user Workspace
SKU assignments (Business Standard, Enterprise, Plus, etc.).

Auth: use csl/scoped-delegated-credentials with the appropriate scope
and a super-admin impersonation target:
- LicensingScopes/APPS_LICENSING  (read + write — see SCOPE NOTE below)

All list functions return {:data [...] :next-page-token "..."}.
:next-page-token is absent when there are no further pages.

SCOPE NOTE
`apps.licensing` is the only scope exposed by Google for this API;
it grants read + write. This wrapper only exposes list/get
(LicenseAssignments). Write counterparts (`insert`, `update`,
`delete`, `transfer`) are intentionally not wrapped here; a future
write consumer files its own FR.

Workspace product/SKU id strings (e.g. product "Google-Apps", SKU
"Google-Apps-For-Business") are documented externally by Google's
Workspace SKU catalog. The wrapper passes them through unchanged.

All functions return {:data ...} on success or {:error ...} on failure.
raw docstring

get-license-assignmentclj

(get-license-assignment client product-id sku-id user-id & [opts])

Get a single license assignment for product/SKU/user.

opts:

  • :fields — partial response field mask string
Get a single license assignment for product/SKU/user.

opts:
- :fields — partial response field mask string
raw docstring

licensing-clientclj

(licensing-client credentials)
(licensing-client credentials opts)

Build an authenticated Apps Licensing client.

credentials — a com.google.auth.oauth2.GoogleCredentials instance, typically from csl/scoped-delegated-credentials with a super-admin impersonation target.

opts (optional):

  • :read-timeout-ms per-client default read timeout (default 120000 / 120s)
  • :connect-timeout-ms per-client default connect timeout (default 30000 / 30s)

Per-request opts on individual call sites override the client-level defaults.

Build an authenticated Apps Licensing client.

credentials — a com.google.auth.oauth2.GoogleCredentials instance, typically
from csl/scoped-delegated-credentials with a super-admin impersonation target.

opts (optional):
- :read-timeout-ms     per-client default read timeout (default 120000 / 120s)
- :connect-timeout-ms  per-client default connect timeout (default 30000 / 30s)

Per-request opts on individual call sites override the client-level defaults.
raw docstring

list-license-assignmentsclj

(list-license-assignments client product-id sku-id customer-id & [opts])

List license assignments for a product+SKU pair in the given customer.

product-id and sku-id are Google's externally-documented Workspace SKU identifier strings (e.g. "Google-Apps" + "Google-Apps-For-Business"). customer-id is either the customer's primary domain or its unique identifier (required by the Google API).

opts:

  • :max-results — page size (1..1000; default 100)
  • :page-token — token from a previous response
  • :fields — partial response field mask string
List license assignments for a product+SKU pair in the given customer.

`product-id` and `sku-id` are Google's externally-documented Workspace
SKU identifier strings (e.g. "Google-Apps" + "Google-Apps-For-Business").
`customer-id` is either the customer's primary domain or its unique
identifier (required by the Google API).

opts:
- :max-results — page size (1..1000; default 100)
- :page-token  — token from a previous response
- :fields      — partial response field mask string
raw docstring

list-license-assignments-for-productclj

(list-license-assignments-for-product client product-id customer-id & [opts])

List license assignments for a product (across all SKUs) in the given customer.

product-id is Google's externally-documented Workspace product identifier string (e.g. "Google-Apps"). customer-id is either the customer's primary domain or its unique identifier (required by the Google API).

opts:

  • :max-results — page size (1..1000; default 100)
  • :page-token — token from a previous response
  • :fields — partial response field mask string
List license assignments for a product (across all SKUs) in the given customer.

`product-id` is Google's externally-documented Workspace product
identifier string (e.g. "Google-Apps"). `customer-id` is either the
customer's primary domain or its unique identifier (required by the
Google API).

opts:
- :max-results — page size (1..1000; default 100)
- :page-token  — token from a previous response
- :fields      — partial response field mask string
raw docstring

cljdoc builds & hosts documentation for Clojure/Script libraries

Keyboard shortcuts
Ctrl+kJump to recent docs
Move to previous article
Move to next article
Ctrl+/Jump to the search field
× close