@joai/sdk 3.0.0 → 4.1.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.mts +27 -4
- package/dist/index.mjs +21 -2
- package/package.json +1 -1
package/dist/index.d.mts
CHANGED
|
@@ -245,6 +245,25 @@ type AffiliateTier = {
|
|
|
245
245
|
type AffiliateStatus = 'pending' | 'approved' | 'rejected' | 'suspended' | 'demoted'; //#endregion
|
|
246
246
|
//#region src/team/constants.d.ts
|
|
247
247
|
declare const teamCategories: readonly ["general", "food-drink", "retail", "beauty-wellness", "health", "sports-fitness", "trades-services", "professional-services", "education-culture", "clubs-organizations", "leisure-tourism"]; //#endregion
|
|
248
|
+
//#region src/team/apps.d.ts
|
|
249
|
+
declare const NativeApps: {
|
|
250
|
+
readonly Board: "board";
|
|
251
|
+
readonly Shop: "shop";
|
|
252
|
+
readonly SmartLinks: "smart-links";
|
|
253
|
+
readonly Contacts: "contacts";
|
|
254
|
+
readonly Appointments: "appointments";
|
|
255
|
+
readonly Workspace: "workspace";
|
|
256
|
+
readonly Meeting: "meeting";
|
|
257
|
+
readonly VoiceDictation: "voice-dictation";
|
|
258
|
+
readonly Heartbeats: "heartbeats";
|
|
259
|
+
readonly Wallets: "wallets";
|
|
260
|
+
readonly Campaigns: "campaigns";
|
|
261
|
+
readonly News: "news";
|
|
262
|
+
readonly Sites: "sites";
|
|
263
|
+
readonly Contracts: "contracts";
|
|
264
|
+
};
|
|
265
|
+
type NativeApp = (typeof NativeApps)[keyof typeof NativeApps];
|
|
266
|
+
//#endregion
|
|
248
267
|
//#region src/team/types.d.ts
|
|
249
268
|
type TeamCategory = (typeof teamCategories)[number];
|
|
250
269
|
type TeamFeature = 'shop' | 'appointments';
|
|
@@ -270,7 +289,9 @@ type TeamMeta = {
|
|
|
270
289
|
'stock.enabled'?: boolean;
|
|
271
290
|
contactPropertyMaskWarp?: string;
|
|
272
291
|
branding?: TeamBrand | null;
|
|
273
|
-
settings: Record<string, unknown
|
|
292
|
+
settings: Record<string, unknown> & {
|
|
293
|
+
apps?: NativeApp[];
|
|
294
|
+
};
|
|
274
295
|
};
|
|
275
296
|
type TeamPlace = {
|
|
276
297
|
provider: 'google';
|
|
@@ -1801,7 +1822,6 @@ type KvField = {
|
|
|
1801
1822
|
};
|
|
1802
1823
|
type KvFieldWithEntries = Pick<KvField, 'name' | 'description' | 'unit'> & {
|
|
1803
1824
|
entries: KvEntry[];
|
|
1804
|
-
nextCursor: string | null;
|
|
1805
1825
|
};
|
|
1806
1826
|
type CreateKvFieldPayload = {
|
|
1807
1827
|
name: string;
|
|
@@ -3735,6 +3755,9 @@ declare class NotificationsResource {
|
|
|
3735
3755
|
constructor(http: IHttpService);
|
|
3736
3756
|
list(page?: number): Promise<IAppResponse<Notification[]>>;
|
|
3737
3757
|
getUnread(): Promise<IAppResponse<Notification[]>>;
|
|
3758
|
+
getDismissedPushKeys(): Promise<IAppResponse<{
|
|
3759
|
+
notificationKeys: string[];
|
|
3760
|
+
}>>;
|
|
3738
3761
|
getSettings(): Promise<IAppResponse<NotificationSetting[]>>;
|
|
3739
3762
|
updateSettings(notificationType: string, channel: NotificationChannel): Promise<IAppResponse<NotificationSetting[]>>;
|
|
3740
3763
|
getAgentSettings(): Promise<IAppResponse<{
|
|
@@ -4049,8 +4072,8 @@ declare class KvResource {
|
|
|
4049
4072
|
field?: string;
|
|
4050
4073
|
since?: string;
|
|
4051
4074
|
until?: string;
|
|
4052
|
-
|
|
4053
|
-
|
|
4075
|
+
page?: number;
|
|
4076
|
+
perPage?: number;
|
|
4054
4077
|
}): Promise<IAppResponse<KvFieldWithEntries>>;
|
|
4055
4078
|
setEntry(payload: KvEntryPayload): Promise<IAppResponse<SetKvEntryResult>>;
|
|
4056
4079
|
appendEntry(payload: KvEntryPayload): Promise<IAppResponse<AppendKvEntryResult>>;
|
package/dist/index.mjs
CHANGED
|
@@ -110,6 +110,22 @@ var HttpService = class {
|
|
|
110
110
|
};
|
|
111
111
|
}
|
|
112
112
|
};
|
|
113
|
+
Object.values({
|
|
114
|
+
Board: "board",
|
|
115
|
+
Shop: "shop",
|
|
116
|
+
SmartLinks: "smart-links",
|
|
117
|
+
Contacts: "contacts",
|
|
118
|
+
Appointments: "appointments",
|
|
119
|
+
Workspace: "workspace",
|
|
120
|
+
Meeting: "meeting",
|
|
121
|
+
VoiceDictation: "voice-dictation",
|
|
122
|
+
Heartbeats: "heartbeats",
|
|
123
|
+
Wallets: "wallets",
|
|
124
|
+
Campaigns: "campaigns",
|
|
125
|
+
News: "news",
|
|
126
|
+
Sites: "sites",
|
|
127
|
+
Contracts: "contracts"
|
|
128
|
+
});
|
|
113
129
|
//#endregion
|
|
114
130
|
//#region src/resources/agents.ts
|
|
115
131
|
var AgentsResource = class {
|
|
@@ -1512,6 +1528,9 @@ var NotificationsResource = class {
|
|
|
1512
1528
|
getUnread() {
|
|
1513
1529
|
return this.http.get("notifications?unread");
|
|
1514
1530
|
}
|
|
1531
|
+
getDismissedPushKeys() {
|
|
1532
|
+
return this.http.get("notifications/dismissed-push-keys");
|
|
1533
|
+
}
|
|
1515
1534
|
getSettings() {
|
|
1516
1535
|
return this.http.get("notifications/settings");
|
|
1517
1536
|
}
|
|
@@ -1877,8 +1896,8 @@ var KvResource = class {
|
|
|
1877
1896
|
if (params?.field) query.set("field", params.field);
|
|
1878
1897
|
if (params?.since) query.set("since", params.since);
|
|
1879
1898
|
if (params?.until) query.set("until", params.until);
|
|
1880
|
-
if (params?.
|
|
1881
|
-
if (params?.
|
|
1899
|
+
if (params?.page != null) query.set("page", String(params.page));
|
|
1900
|
+
if (params?.perPage != null) query.set("perPage", String(params.perPage));
|
|
1882
1901
|
const qs = query.toString();
|
|
1883
1902
|
return this.http.get(`kv/entries${qs ? "?" + qs : ""}`);
|
|
1884
1903
|
}
|