/** This is spectacularly generated code by spectacular based on Qlik Cloud Services APIs */ import Auth from '../auth/auth.js'; import type { Config } from '../types/types.js'; /** @param autoAssignCreateSharedSpacesRoleToProfessionals - @param autoAssignDataServicesContributorRoleToProfessionals - @param autoAssignPrivateAnalyticsContentCreatorRoleToProfessionals - @param created - The timestamp for when the tenant record was created (1970-01-01T00:00:00.001Z for static tenants). @param createdByUser - The user ID who created the tenant. @param datacenter - The datacenter where the tenant is located. @param enableAnalyticCreation - @param hostnames - List of case insensitive hostnames that are mapped to the tenant. The first record maps to the display name and the subsequent entries are aliases. @param id - The unique tenant identifier. @param lastUpdated - The timestamp for when the tenant record was last updated (1970-01-01T00:00:00.001Z for static tenants). @param links - @param name - The display name of the tenant. @param status - The status of the tenant. @param auth - Auth object used to make requests */ export declare class Tenant { auth: Auth; autoAssignCreateSharedSpacesRoleToProfessionals?: boolean; autoAssignDataServicesContributorRoleToProfessionals?: boolean; autoAssignPrivateAnalyticsContentCreatorRoleToProfessionals?: boolean; created?: string; createdByUser?: string; datacenter?: string; enableAnalyticCreation?: boolean; hostnames?: Array; id: string; lastUpdated?: string; links?: { self: { href: string; }; }; name: string; status?: 'active' | 'disabled' | 'deleted' | string; [key: string]: any; constructor({ autoAssignCreateSharedSpacesRoleToProfessionals, autoAssignDataServicesContributorRoleToProfessionals, autoAssignPrivateAnalyticsContentCreatorRoleToProfessionals, created, createdByUser, datacenter, enableAnalyticCreation, hostnames, id, lastUpdated, links, name, status, ...rest }: { autoAssignCreateSharedSpacesRoleToProfessionals?: boolean; autoAssignDataServicesContributorRoleToProfessionals?: boolean; autoAssignPrivateAnalyticsContentCreatorRoleToProfessionals?: boolean; created?: string; createdByUser?: string; datacenter?: string; enableAnalyticCreation?: boolean; hostnames?: Array; id: string; lastUpdated?: string; links?: { self: { href: string; }; }; name: string; status?: 'active' | 'disabled' | 'deleted' | string; }, auth?: Auth); /** Deactivates a tenant. Deactivate a tenant @param qlik-confirm-hostname - A confirmation string that should match the hostname associated with the tenant resource to be deactivated. Example: unicorn.eu.qlikcloud.com @param data - A request to deactivate a tenant. */ deactivate(qlikConfirmHostname: string, data: TenantDeactivateRequest): Promise; /** Reactivates a disabled tenant. Reactivates a tenant @param qlik-confirm-hostname - A confirmation string that should match one of the hostnames of the tenant resource to be reactivated. Example: unicorn.eu.qlikcloud.com */ reactivate(qlikConfirmHostname: string): Promise; /** Update a tenant by id. @param data - */ patch(data: TenantPatchSchema): Promise; } export type TenantCreationRequest = { /** The datacenter where the tenant is located. @example "us-east-1" */ datacenter?: string; /** The hostnames of the created tenant. Can only create with a single entry that lines up wtih the tenant name. @example ["bk1672h181jm1b1.us.qlikcloud.com"] */ hostnames?: Array; /** The signed license key of the license that will be associated with the created tenant. @example 1234567890 */ licenseKey?: string; /** The name of the created tenant, provided by the onboarding service. @example "bk1672h181jm1b1" */ name?: string; [key: string]: any; }; export type TenantDeactivateRequest = { /** Sets the number of days to purge the tenant after deactivation. Only available to OEMs. @defaultValue 30 */ purgeAfterDays?: number; [key: string]: any; }; export type TenantDeactivateResponse = { /** The estimated date time of when tenant will be purged. @example "2023-08-18T00:00:00.000Z" */ estimatedPurgeDate?: string; /** The unique tenant identifier. @example "TiQ8GPVr8qI714Lp5ChAAFFaU24MJy69" */ id?: string; /** The status of the tenant. */ status?: 'disabled' | string; [key: string]: any; }; export type TenantPatchSchema = Array; export type TenantPatchSchemaElement = { /** The operation to be performed. */ op: 'replace' | string; /** A JSON Pointer value that references a location within the target document where the operation is performed. */ path: '/name' | '/hostnames/1' | '/autoAssignCreateSharedSpacesRoleToProfessionals' | '/autoAssignPrivateAnalyticsContentCreatorRoleToProfessionals' | '/autoAssignDataServicesContributorRoleToProfessionals' | '/enableAnalyticCreation' | string; /** The value to be used for this operation. */ value: string | boolean; [key: string]: any; }; export declare class Tenants { auth: Auth; config: Config; constructor(config: Config | Auth); /** Redirects to current tenant. */ getMe(): Promise; /** Retrieve a single tenant by id. @param tenantId - The id of the tenant to retrieve */ get(tenantId: string): Promise; /** Creates a Tenant @param data - */ create(data: TenantCreationRequest): Promise; }