@arbidocs/sdk 0.4.92 → 0.4.95

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.cjs CHANGED
@@ -6589,8 +6589,12 @@ function currentSessionId(accessToken) {
6589
6589
  // src/operations/profile.ts
6590
6590
  var profile_exports = {};
6591
6591
  __export(profile_exports, {
6592
+ getCurrentUser: () => getCurrentUser,
6592
6593
  updateProfile: () => updateProfile
6593
6594
  });
6595
+ async function getCurrentUser(arbi) {
6596
+ return requireData(await arbi.fetch.GET("/v1/user/me"), "Failed to fetch the current user");
6597
+ }
6594
6598
  async function updateProfile(arbi, body) {
6595
6599
  return requireData(
6596
6600
  await arbi.fetch.PATCH("/v1/user/profile", { body }),
@@ -8171,7 +8175,12 @@ var Arbi = class {
8171
8175
  return () => this.profileListeners.delete(listener);
8172
8176
  },
8173
8177
  /** Today's deployment-wide credit spend for the current user. */
8174
- usageToday: () => getUserUsageToday(this.requireClient())
8178
+ usageToday: () => getUserUsageToday(this.requireClient()),
8179
+ /**
8180
+ * The signed-in user from the server, with `can_create_projects`: false on deployments where
8181
+ * only firm members may create projects and workspaces and this user is not one (yet).
8182
+ */
8183
+ me: () => getCurrentUser(this.requireClient())
8175
8184
  };
8176
8185
  // ── Profile ───────────────────────────────────────────────────────────
8177
8186
  profile = {