/** This is spectacularly generated code by spectacular based on Qlik Cloud Services APIs */ import Auth from '../auth/auth.js'; import ListableResource from '../listable.js'; import type { Config } from '../types/types.js'; export type AssignmentsActionsAddRequest = { add: { name?: string; subject: string; type: string; userId?: string; }[]; [key: string]: any; }; export type AssignmentsActionsAddResponse = { data: { code?: string; status: number; subject: string; title?: string; type?: string; }[]; [key: string]: any; }; export type AssignmentsActionsDeleteRequest = { delete: { subject: string; type: string; }[]; [key: string]: any; }; export type AssignmentsActionsDeleteResponse = { data: { code?: string; status: number; subject?: string; title?: string; type?: string; }[]; [key: string]: any; }; export type AssignmentsActionsUpdateRequest = { update: { sourceType: string; subject: string; type: string; }[]; [key: string]: any; }; export type AssignmentsActionsUpdateResponse = { data: { code?: string; sourceType?: string; status: number; subject?: string; title?: string; type?: string; }[]; [key: string]: any; }; export type AssignmentsResponseData = { /** Assignment created date. */ created: string; /** Assignment excess status. */ excess: boolean; /** User name */ name?: string; /** Subject */ subject: string; /** Allotment type */ type: string; /** User ID */ userId?: string; [key: string]: any; }; export type ConsumptionEventsResponseData = { /** Allotment ID */ allotmentId?: string; /** App ID */ appId?: string; /** Analyzer capacity chunks consumed. */ capacityUsed?: number; /** Engine session duration. */ duration?: string; /** Engine session end time. */ endTime?: string; /** ID */ id?: string; /** License usage */ licenseUsage?: string; /** Analyzer capacity minutes consumed. */ minutesUsed?: number; /** Engine session ID. */ sessionId?: string; /** User ID */ userId?: string; [key: string]: any; }; export type LicenseOverview = { allotments: { name: 'professional' | 'analyzer' | 'analyzer_time' | string; overage?: number; units: number; unitsUsed: number; usageClass: string; }[]; /** An ISO 8601 timestamp for when the license was last changed. */ changeTime?: string; /** An ISO 8601 timestamp for when the latest time the license has been known to be valid, a missing value indicates the indefinite future. */ latestValidTime?: string; licenseKey: string; licenseNumber: string; licenseType?: string; /** Origin of license key. */ origin: 'Internal' | 'External' | string; /** The license parameters. */ parameters: { access?: { allotment?: string; }; name: string; valid: string; values?: {}; }[]; /** The product the license is valid for. */ product: string; /** The secondary number of a definition. */ secondaryNumber: string; /** Enum with status of license. Only status Ok grants license. access. */ status: 'Ok' | 'Blacklisted' | 'Expired' | string; /** Boolean indicating if it is a trial license. */ trial: boolean; /** An ISO 8601 timestamp for when the license was last updated. */ updated: string; /** Period that the license is currently set to be active. Represented as an ISO 8601 time interval with start and end. */ valid: string; [key: string]: any; }; export type LicenseStatus = { /** Origin of license key. */ origin: 'Internal' | 'External' | string; /** The product the license is valid for. */ product: string; /** Enum with status of license. Only status Ok grants license. access. */ status: 'Ok' | 'Blacklisted' | 'Expired' | 'Missing' | string; /** Boolean indicating if it is a trial license. */ trial: boolean; /** Type of license key. */ type: 'Signed' | 'Plain' | string; /** Period that the license is currently set to be active. Represented as an ISO 8601 time interval with start and end. */ valid: string; [key: string]: any; }; export type SettingsBody = { /** If analyzer users are available, they will be automatically assigned. Otherwise, analyzer capacity will be assigned, if available. */ autoAssignAnalyzer?: boolean; /** If professional users are available, they will be automatically assigned. Otherwise, analyzer capacity will be assigned, if available. */ autoAssignProfessional?: boolean; [key: string]: any; }; export declare class Licenses { auth: Auth; config: Config; constructor(config: Config | Auth); /** Assigns license access to the given users @param data - List of subjects to allocate assignments for. */ addAssignments(data: AssignmentsActionsAddRequest): Promise; /** Removes license access for the given users @param data - List of assignments to delete. */ deleteAssignments(data: AssignmentsActionsDeleteRequest): Promise; /** Updates license access for the given users @param data - List of assignments to update. */ updateAssignments(data: AssignmentsActionsUpdateRequest): Promise; /** Retrieves assignments for the current tenant @param filter - The filter for finding entries. @param limit - The preferred number of entries to return. @param page - The requested page. @param sort - The field to sort on; can be prefixed with +/- for ascending/descending sort order. */ getAssignments(queryParams?: { filter?: string; limit?: number; page?: string; sort?: string; }): Promise>; /** Retrieves license consumption for the current tenant @param filter - The filter for finding entries. @param limit - The preferred number of entries to return. @param page - The requested page. @param sort - The field to sort on; can be prefixed with +/- for ascending/descending sort order. */ getConsumptions(queryParams?: { filter?: string; limit?: number; page?: string; sort?: string; }): Promise>; /** Gets the general information of the license applied to the current tenant */ getOverview(): Promise; /** Get auto assign settings for tenant. */ getSettings(): Promise; /** Set auto assign settings for tenant @param data - Dynamic assignment settings for professional and analyzer users. If professional users and analyzer users are both set, professional users will be automatically assigned, if available. Otherwise, analyzer users will be assigned. If neither of those users are available, analyzer capacity will be assigned, if available. */ setSettings(data: SettingsBody): Promise; /** Gets the license status information of the current tenant */ getStatus(): Promise; }