@connectedxm/admin 2.3.2 → 2.3.4

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
@@ -4049,11 +4049,18 @@ var useGetAccountTiers = (accountId = "", type, params = {}, options = {}) => {
4049
4049
  };
4050
4050
 
4051
4051
  // src/queries/activities/useGetActivities.ts
4052
- var ACTIVITIES_QUERY_KEY = () => ["ACTIVITIES"];
4052
+ var ACTIVITIES_QUERY_KEY = (moderation) => {
4053
+ const key = ["ACTIVITIES"];
4054
+ if (moderation) {
4055
+ key.push(moderation);
4056
+ }
4057
+ return key;
4058
+ };
4053
4059
  var SET_ACTIVITIES_QUERY_DATA = (client, keyParams, response) => {
4054
4060
  client.setQueryData(ACTIVITIES_QUERY_KEY(...keyParams), response);
4055
4061
  };
4056
4062
  var GetActivities = async ({
4063
+ moderation,
4057
4064
  pageParam,
4058
4065
  pageSize,
4059
4066
  orderBy,
@@ -4066,15 +4073,16 @@ var GetActivities = async ({
4066
4073
  page: pageParam || void 0,
4067
4074
  pageSize: pageSize || void 0,
4068
4075
  orderBy: orderBy || void 0,
4069
- search: search || void 0
4076
+ search: search || void 0,
4077
+ moderation: moderation || void 0
4070
4078
  }
4071
4079
  });
4072
4080
  return data;
4073
4081
  };
4074
- var useGetActivities = (params = {}, options = {}) => {
4082
+ var useGetActivities = (moderation, params = {}, options = {}) => {
4075
4083
  return useConnectedInfiniteQuery(
4076
- ACTIVITIES_QUERY_KEY(),
4077
- (params2) => GetActivities({ ...params2 }),
4084
+ ACTIVITIES_QUERY_KEY(moderation),
4085
+ (params2) => GetActivities({ ...params2, moderation }),
4078
4086
  params,
4079
4087
  options,
4080
4088
  "activities"
package/dist/index.d.cts CHANGED
@@ -372,6 +372,7 @@ interface BaseActivity {
372
372
  image: BaseImage | null;
373
373
  account: BaseAccount;
374
374
  entities: BaseActivityEntity[];
375
+ moderation: keyof typeof ModerationStatus | null;
375
376
  eventId: string | null;
376
377
  groupId: string | null;
377
378
  contentId: string | null;
@@ -1383,7 +1384,6 @@ interface Organization extends BaseOrganization {
1383
1384
  maxImageCount: number | null;
1384
1385
  maxVideoMins: number | null;
1385
1386
  locales: string[];
1386
- googleServices: string | null;
1387
1387
  inviteOnly: boolean;
1388
1388
  }
1389
1389
  interface OrganizationTrigger {
@@ -3440,7 +3440,7 @@ interface ActivityCreateInputs {
3440
3440
  interface ActivityUpdateInputs {
3441
3441
  message?: string | null;
3442
3442
  entities?: ActivityEntityInputs[] | null;
3443
- status?: keyof typeof ModerationStatus | null;
3443
+ moderation?: keyof typeof ModerationStatus | null;
3444
3444
  imageId?: string | null;
3445
3445
  videoId?: string | null;
3446
3446
  createdAt?: string | null;
@@ -4390,7 +4390,6 @@ interface OrganizationUpdateInputs {
4390
4390
  appSplashScreenId?: string | null;
4391
4391
  locale?: string | null;
4392
4392
  locales?: string[] | null;
4393
- googleServices?: string | null;
4394
4393
  inviteOnly?: boolean;
4395
4394
  }
4396
4395
  interface PaymentIntentPurchaseMetadataInputs {
@@ -5992,24 +5991,25 @@ declare const useGetAccounts: (accountType?: "account" | "team", params?: Omit<I
5992
5991
  * @category Keys
5993
5992
  * @group Activities
5994
5993
  */
5995
- declare const ACTIVITIES_QUERY_KEY: () => string[];
5994
+ declare const ACTIVITIES_QUERY_KEY: (moderation?: keyof typeof ModerationStatus) => string[];
5996
5995
  /**
5997
5996
  * @category Setters
5998
5997
  * @group Activities
5999
5998
  */
6000
5999
  declare const SET_ACTIVITIES_QUERY_DATA: (client: QueryClient, keyParams: Parameters<typeof ACTIVITIES_QUERY_KEY>, response: Awaited<ReturnType<typeof GetActivities>>) => void;
6001
6000
  interface GetActivitiesProps extends InfiniteQueryParams {
6001
+ moderation?: keyof typeof ModerationStatus;
6002
6002
  }
6003
6003
  /**
6004
6004
  * @category Queries
6005
6005
  * @group Activities
6006
6006
  */
6007
- declare const GetActivities: ({ pageParam, pageSize, orderBy, search, adminApiParams, }: GetActivitiesProps) => Promise<ConnectedXMResponse<Activity[]>>;
6007
+ declare const GetActivities: ({ moderation, pageParam, pageSize, orderBy, search, adminApiParams, }: GetActivitiesProps) => Promise<ConnectedXMResponse<Activity[]>>;
6008
6008
  /**
6009
6009
  * @category Hooks
6010
6010
  * @group Activities
6011
6011
  */
6012
- declare const useGetActivities: (params?: Omit<InfiniteQueryParams, "pageParam" | "queryClient" | "adminApiParams">, options?: InfiniteQueryOptions<Awaited<ReturnType<typeof GetActivities>>>) => _tanstack_react_query.UseInfiniteQueryResult<_tanstack_react_query.InfiniteData<ConnectedXMResponse<Activity[]>, number>, axios.AxiosError<ConnectedXMResponse<null>, any>>;
6012
+ declare const useGetActivities: (moderation?: keyof typeof ModerationStatus, params?: Omit<InfiniteQueryParams, "pageParam" | "queryClient" | "adminApiParams">, options?: InfiniteQueryOptions<Awaited<ReturnType<typeof GetActivities>>>) => _tanstack_react_query.UseInfiniteQueryResult<_tanstack_react_query.InfiniteData<ConnectedXMResponse<Activity[]>, number>, axios.AxiosError<ConnectedXMResponse<null>, any>>;
6013
6013
 
6014
6014
  /**
6015
6015
  * @category Keys
package/dist/index.d.ts CHANGED
@@ -372,6 +372,7 @@ interface BaseActivity {
372
372
  image: BaseImage | null;
373
373
  account: BaseAccount;
374
374
  entities: BaseActivityEntity[];
375
+ moderation: keyof typeof ModerationStatus | null;
375
376
  eventId: string | null;
376
377
  groupId: string | null;
377
378
  contentId: string | null;
@@ -1383,7 +1384,6 @@ interface Organization extends BaseOrganization {
1383
1384
  maxImageCount: number | null;
1384
1385
  maxVideoMins: number | null;
1385
1386
  locales: string[];
1386
- googleServices: string | null;
1387
1387
  inviteOnly: boolean;
1388
1388
  }
1389
1389
  interface OrganizationTrigger {
@@ -3440,7 +3440,7 @@ interface ActivityCreateInputs {
3440
3440
  interface ActivityUpdateInputs {
3441
3441
  message?: string | null;
3442
3442
  entities?: ActivityEntityInputs[] | null;
3443
- status?: keyof typeof ModerationStatus | null;
3443
+ moderation?: keyof typeof ModerationStatus | null;
3444
3444
  imageId?: string | null;
3445
3445
  videoId?: string | null;
3446
3446
  createdAt?: string | null;
@@ -4390,7 +4390,6 @@ interface OrganizationUpdateInputs {
4390
4390
  appSplashScreenId?: string | null;
4391
4391
  locale?: string | null;
4392
4392
  locales?: string[] | null;
4393
- googleServices?: string | null;
4394
4393
  inviteOnly?: boolean;
4395
4394
  }
4396
4395
  interface PaymentIntentPurchaseMetadataInputs {
@@ -5992,24 +5991,25 @@ declare const useGetAccounts: (accountType?: "account" | "team", params?: Omit<I
5992
5991
  * @category Keys
5993
5992
  * @group Activities
5994
5993
  */
5995
- declare const ACTIVITIES_QUERY_KEY: () => string[];
5994
+ declare const ACTIVITIES_QUERY_KEY: (moderation?: keyof typeof ModerationStatus) => string[];
5996
5995
  /**
5997
5996
  * @category Setters
5998
5997
  * @group Activities
5999
5998
  */
6000
5999
  declare const SET_ACTIVITIES_QUERY_DATA: (client: QueryClient, keyParams: Parameters<typeof ACTIVITIES_QUERY_KEY>, response: Awaited<ReturnType<typeof GetActivities>>) => void;
6001
6000
  interface GetActivitiesProps extends InfiniteQueryParams {
6001
+ moderation?: keyof typeof ModerationStatus;
6002
6002
  }
6003
6003
  /**
6004
6004
  * @category Queries
6005
6005
  * @group Activities
6006
6006
  */
6007
- declare const GetActivities: ({ pageParam, pageSize, orderBy, search, adminApiParams, }: GetActivitiesProps) => Promise<ConnectedXMResponse<Activity[]>>;
6007
+ declare const GetActivities: ({ moderation, pageParam, pageSize, orderBy, search, adminApiParams, }: GetActivitiesProps) => Promise<ConnectedXMResponse<Activity[]>>;
6008
6008
  /**
6009
6009
  * @category Hooks
6010
6010
  * @group Activities
6011
6011
  */
6012
- declare const useGetActivities: (params?: Omit<InfiniteQueryParams, "pageParam" | "queryClient" | "adminApiParams">, options?: InfiniteQueryOptions<Awaited<ReturnType<typeof GetActivities>>>) => _tanstack_react_query.UseInfiniteQueryResult<_tanstack_react_query.InfiniteData<ConnectedXMResponse<Activity[]>, number>, axios.AxiosError<ConnectedXMResponse<null>, any>>;
6012
+ declare const useGetActivities: (moderation?: keyof typeof ModerationStatus, params?: Omit<InfiniteQueryParams, "pageParam" | "queryClient" | "adminApiParams">, options?: InfiniteQueryOptions<Awaited<ReturnType<typeof GetActivities>>>) => _tanstack_react_query.UseInfiniteQueryResult<_tanstack_react_query.InfiniteData<ConnectedXMResponse<Activity[]>, number>, axios.AxiosError<ConnectedXMResponse<null>, any>>;
6013
6013
 
6014
6014
  /**
6015
6015
  * @category Keys
package/dist/index.js CHANGED
@@ -1237,11 +1237,18 @@ var useGetAccountTiers = (accountId = "", type, params = {}, options = {}) => {
1237
1237
  };
1238
1238
 
1239
1239
  // src/queries/activities/useGetActivities.ts
1240
- var ACTIVITIES_QUERY_KEY = () => ["ACTIVITIES"];
1240
+ var ACTIVITIES_QUERY_KEY = (moderation) => {
1241
+ const key = ["ACTIVITIES"];
1242
+ if (moderation) {
1243
+ key.push(moderation);
1244
+ }
1245
+ return key;
1246
+ };
1241
1247
  var SET_ACTIVITIES_QUERY_DATA = (client, keyParams, response) => {
1242
1248
  client.setQueryData(ACTIVITIES_QUERY_KEY(...keyParams), response);
1243
1249
  };
1244
1250
  var GetActivities = async ({
1251
+ moderation,
1245
1252
  pageParam,
1246
1253
  pageSize,
1247
1254
  orderBy,
@@ -1254,15 +1261,16 @@ var GetActivities = async ({
1254
1261
  page: pageParam || void 0,
1255
1262
  pageSize: pageSize || void 0,
1256
1263
  orderBy: orderBy || void 0,
1257
- search: search || void 0
1264
+ search: search || void 0,
1265
+ moderation: moderation || void 0
1258
1266
  }
1259
1267
  });
1260
1268
  return data;
1261
1269
  };
1262
- var useGetActivities = (params = {}, options = {}) => {
1270
+ var useGetActivities = (moderation, params = {}, options = {}) => {
1263
1271
  return useConnectedInfiniteQuery(
1264
- ACTIVITIES_QUERY_KEY(),
1265
- (params2) => GetActivities({ ...params2 }),
1272
+ ACTIVITIES_QUERY_KEY(moderation),
1273
+ (params2) => GetActivities({ ...params2, moderation }),
1266
1274
  params,
1267
1275
  options,
1268
1276
  "activities"
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@connectedxm/admin",
3
- "version": "2.3.2",
3
+ "version": "2.3.4",
4
4
  "description": "Admin API javascript SDK",
5
5
  "author": "ConnectedXM Inc.",
6
6
  "type": "module",
@@ -21,7 +21,7 @@
21
21
  "upgrade": "ncu -i --format group"
22
22
  },
23
23
  "dependencies": {
24
- "axios": "^1.8.4",
24
+ "axios": "^1.9.0",
25
25
  "immer": "^10.1.1"
26
26
  },
27
27
  "peerDependencies": {
@@ -29,24 +29,24 @@
29
29
  "react": "^18 || ^19"
30
30
  },
31
31
  "devDependencies": {
32
- "@babel/parser": "^7.27.0",
33
- "@swc/core": "^1.11.20",
34
- "@tanstack/react-query": "^5.72.2",
32
+ "@babel/parser": "^7.27.1",
33
+ "@swc/core": "^1.11.24",
34
+ "@tanstack/react-query": "^5.75.1",
35
35
  "@types/glob": "^8.1.0",
36
- "@types/node": "^22.14.1",
37
- "@types/react": "^19.1.1",
38
- "@typescript-eslint/eslint-plugin": "^8.29.1",
39
- "@typescript-eslint/parser": "^8.29.1",
40
- "eslint": "^9.24.0",
36
+ "@types/node": "^22.15.3",
37
+ "@types/react": "^19.1.2",
38
+ "@typescript-eslint/eslint-plugin": "^8.31.1",
39
+ "@typescript-eslint/parser": "^8.31.1",
40
+ "eslint": "^9.26.0",
41
41
  "eslint-plugin-react": "^7.37.5",
42
42
  "eslint-plugin-react-hooks": "^5.2.0",
43
- "glob": "^11.0.1",
43
+ "glob": "^11.0.2",
44
44
  "recast": "^0.23.11",
45
45
  "tsup": "^8.4.0",
46
46
  "typescript": "^5.8.3",
47
- "vitest": "^3.1.1"
47
+ "vitest": "^3.1.2"
48
48
  },
49
49
  "optionalDependencies": {
50
- "@rollup/rollup-linux-x64-gnu": "4.39.0"
50
+ "@rollup/rollup-linux-x64-gnu": "4.40.1"
51
51
  }
52
52
  }