sda.api.graph_sharepoint_ids ============================ .. py:module:: sda.api.graph_sharepoint_ids .. autoapi-nested-parse:: Hardcoded SharePoint site and drive identifiers for Spark Cleantech. These values are organisation-wide constants — they do not vary per machine or per user, so they are baked into the library rather than kept in ``~/sda.json``. How to find the IDs for a new SharePoint site ---------------------------------------------- 1. **site_id** — query the Graph API with the site's hostname and path:: GET https://graph.microsoft.com/v1.0/sites/spark-cleantech.sharepoint.com:/sites/ Copy the ``"id"`` field from the response. 2. **drive_id** — list the drives for that site:: GET https://graph.microsoft.com/v1.0/sites/{site_id}/drives Find the "Documents" document library entry and copy its ``"id"``. Use `Graph Explorer `_ for interactive testing (sign in with your Spark account). Updating for a new year ----------------------- When a new SharePoint library is created (e.g. "6. DATA 2027"), add an entry to :data:`SHAREPOINT_SITE_MAP` below and update ``sda/api/file_discovery._get_test_site_info()`` with the corresponding T-number range. Attributes ---------- .. autoapisummary:: sda.api.graph_sharepoint_ids.SPARK_TENANT_ID sda.api.graph_sharepoint_ids.SPARK_DESKTOP_CLIENT_ID sda.api.graph_sharepoint_ids.SPARK_PUBLIC_CLIENT_ID sda.api.graph_sharepoint_ids.SHAREPOINT_SITE_MAP Module Contents --------------- .. py:data:: SPARK_TENANT_ID :type: str :value: '879d77f0-ea47-46a0-abf6-2d1b4085efe6' Azure AD tenant ID for Spark Cleantech. Fill in after app registration. .. py:data:: SPARK_DESKTOP_CLIENT_ID :type: str :value: 'a8628225-7a4b-4d8e-90ba-d241a3da49d6' public client for CLI / interactive / device-code. :type: Entra app **SDA-Desktop** .. py:data:: SPARK_PUBLIC_CLIENT_ID :type: str :value: 'a8628225-7a4b-4d8e-90ba-d241a3da49d6' Alias of :data:`SPARK_DESKTOP_CLIENT_ID` for older code and tests. .. py:data:: SHAREPOINT_SITE_MAP :type: dict[str, dict[str, str]]