@terminal3/t3n-sdk 4.7.0 → 4.8.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.ts CHANGED
@@ -2272,6 +2272,33 @@ declare class T3nClient {
2272
2272
  * a JSON array.
2273
2273
  */
2274
2274
  getWalletHistory(walletAddress: string): Promise<unknown[]>;
2275
+ /**
2276
+ * Return the organisations the authenticated user is a member of, as
2277
+ * canonical `did:t3n:<40-hex>` strings.
2278
+ *
2279
+ * Backed by `tee:user/my-organisations`, which reads the caller's
2280
+ * membership set (`UserOrganisations`) keyed on the session DID — the
2281
+ * request carries no body, and a user cannot query anyone else's
2282
+ * memberships. An **empty array means the user belongs to no
2283
+ * organisation**; this is the intended signal for an org-scoped app to
2284
+ * gate entry on (authentication itself is org-agnostic — a user in no
2285
+ * org still authenticates successfully).
2286
+ *
2287
+ * Note this reflects *affiliation*, not per-contract authorisation:
2288
+ * membership does not by itself grant admin rights or a scope grant.
2289
+ * Org-scoped operations remain gated server-side (403) on the org's
2290
+ * admin list / grants regardless of what this returns.
2291
+ *
2292
+ * `my-organisations` is an additive export, so any registered
2293
+ * user-contract version exposes it; {@link executeUserContract}
2294
+ * resolves `"latest"` to the current version so this wrapper doesn't
2295
+ * drift on every `CONTRACT_VERSION` bump.
2296
+ *
2297
+ * @returns the caller's organisation DIDs (`did:t3n:<40-hex>`), possibly empty.
2298
+ * @throws if unauthenticated, if the node rejects the action, or if the
2299
+ * response shape is unexpected.
2300
+ */
2301
+ myOrgs(): Promise<Did[]>;
2275
2302
  /**
2276
2303
  * Remove the authenticated user's account AND explicitly abandon
2277
2304
  * any wallets. Writes `Abandoned` audit rows to wallet history,