synology_apm.sdk.collections.saas module

SaasCollection — collection interface for SaaS applications (Cloud Applications).

class synology_apm.sdk.collections.saas.SaasCollection(session)

Bases: object

Lists all SaaS applications connected to APM (M365 + GWS).

Accessed via APMClient.saas; should not be instantiated directly.

async get_m365_tenant(tenant_id)

Fetch details for a specific M365 tenant.

Parameters:

tenant_id (str) – Azure AD tenant UUID.

Returns:

M365TenantInfo with protected_data_bytes set to 0 (usage data is not available for this lookup).

Raises:

ResourceNotFoundError – The specified tenant was not found.

Return type:

M365TenantInfo

async get_gws_domain(domain)

Fetch details for a specific GWS domain.

Parameters:

domain (str) – Google Workspace domain.

Returns:

GWSDomainInfo for the domain.

Raises:

ResourceNotFoundError – The specified domain was not found.

Return type:

GWSDomainInfo

async list(keyword=None, limit=500, offset=0)

List all connected SaaS applications (M365 + GWS).

Parameters:
  • keyword (str | None) – Name keyword (partial match).

  • limit (int) – Maximum records to return (default 500).

  • offset (int) – Pagination start offset (default 0).

Returns:

(list of M365TenantInfo / GWSDomainInfo (M365 first, GWS after), total count)

Return type:

ListResult[M365TenantInfo | GWSDomainInfo]