@dev-crew-berlin/enter-js-utils 0.49.0 → 0.50.2

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.
@@ -21,6 +21,12 @@ export default class API extends APIBase {
21
21
  getCheckinCounts(args: {
22
22
  instanceName: string;
23
23
  }): Promise<APIResult<CheckinCounts>>;
24
+ calculateCustomCounts(args: {
25
+ instanceName: string;
26
+ counter: components['schemas']['CustomCounter'][];
27
+ }): Promise<APIResult<{
28
+ [key: string]: number;
29
+ }>>;
24
30
  getAttendeeList(args: {
25
31
  instanceName: string;
26
32
  includeDeleted?: boolean;
@@ -25,6 +25,12 @@ export default class API extends APIBase {
25
25
  const instanceName = args.instanceName;
26
26
  return this.get(`/instances/${instanceName}/checkin_counts`);
27
27
  }
28
+ async calculateCustomCounts(args) {
29
+ const instanceName = args.instanceName;
30
+ return this.post(`/instances/${instanceName}/custom_counts`, {
31
+ counters: args.counter
32
+ });
33
+ }
28
34
  async getAttendeeList(args) {
29
35
  const query = new URLSearchParams();
30
36
  if (args.includeDeleted) {
@@ -10,6 +10,9 @@ export declare type paths = {
10
10
  "/instances/{instance_name}/checkin_counts": {
11
11
  get: operations["checkin_counts_instances__instance_name__checkin_counts_get"];
12
12
  };
13
+ "/instances/{instance_name}/custom_counts": {
14
+ post: operations["calcualte_custom_counts_instances__instance_name__custom_counts_post"];
15
+ };
13
16
  "/events": {
14
17
  /** Send a list of events to be applied to the current state. Events are executed in order. */
15
18
  post: operations["create_events_events_post"];
@@ -218,29 +221,6 @@ export declare type components = {
218
221
  /** Authcode */
219
222
  authCode: string;
220
223
  };
221
- /** AuthCodeGenerator */
222
- AuthCodeGenerator: {
223
- /**
224
- * Chars
225
- * @default abcdefghijklmnopqrstuvwxyz1234567890
226
- */
227
- chars: string;
228
- /**
229
- * Length
230
- * @default 8
231
- */
232
- length: number;
233
- /**
234
- * Prefix
235
- * @default
236
- */
237
- prefix: string;
238
- /**
239
- * Suffix
240
- * @default
241
- */
242
- suffix: string;
243
- };
244
224
  /** CheckboxField */
245
225
  CheckboxField: {
246
226
  /**
@@ -516,6 +496,18 @@ export declare type components = {
516
496
  /** Mainguestid */
517
497
  mainGuestId: string;
518
498
  };
499
+ /** CustomCountQuery */
500
+ CustomCountQuery: {
501
+ /** Counters */
502
+ counters: components["schemas"]["CustomCounter"][];
503
+ };
504
+ /** CustomCounter */
505
+ CustomCounter: {
506
+ /** Name */
507
+ name: string;
508
+ /** Filter */
509
+ filter: string;
510
+ };
519
511
  /** DateField */
520
512
  DateField: {
521
513
  /**
@@ -1116,7 +1108,7 @@ export declare type components = {
1116
1108
  /** Thumbnail */
1117
1109
  thumbnail: boolean;
1118
1110
  frontend: components["schemas"]["FrontendConfigJSON"];
1119
- registration: components["schemas"]["RegistrationInfo"];
1111
+ registration: components["schemas"]["PublicRegistrationInfo"];
1120
1112
  /** Guestnamefields */
1121
1113
  guestNameFields: string[];
1122
1114
  /** Tagcolors */
@@ -1124,6 +1116,39 @@ export declare type components = {
1124
1116
  [key: string]: string;
1125
1117
  };
1126
1118
  };
1119
+ /** PublicRegistrationInfo */
1120
+ PublicRegistrationInfo: {
1121
+ /**
1122
+ * Closed
1123
+ * @default false
1124
+ */
1125
+ closed: boolean;
1126
+ /**
1127
+ * Start
1128
+ * Format: date-time
1129
+ */
1130
+ start?: string;
1131
+ /**
1132
+ * End
1133
+ * Format: date-time
1134
+ */
1135
+ end?: string;
1136
+ /**
1137
+ * Canedit
1138
+ * @default false
1139
+ */
1140
+ canEdit: boolean;
1141
+ /**
1142
+ * Editend
1143
+ * Format: date-time
1144
+ */
1145
+ editEnd?: string;
1146
+ /**
1147
+ * Allowregistrationwithauthcode
1148
+ * @default false
1149
+ */
1150
+ allowRegistrationWithAuthCode: boolean;
1151
+ };
1127
1152
  /**
1128
1153
  * PublicUser
1129
1154
  * @description User that is retunred from the api
@@ -1210,40 +1235,6 @@ export declare type components = {
1210
1235
  */
1211
1236
  items: components["schemas"]["ItemOption"][];
1212
1237
  };
1213
- /** RegistrationInfo */
1214
- RegistrationInfo: {
1215
- /**
1216
- * Closed
1217
- * @default false
1218
- */
1219
- closed: boolean;
1220
- /**
1221
- * Start
1222
- * Format: date-time
1223
- */
1224
- start?: string;
1225
- /**
1226
- * End
1227
- * Format: date-time
1228
- */
1229
- end?: string;
1230
- /**
1231
- * Canedit
1232
- * @default false
1233
- */
1234
- canEdit: boolean;
1235
- /**
1236
- * Editend
1237
- * Format: date-time
1238
- */
1239
- editEnd?: string;
1240
- /**
1241
- * Allowregistrationwithauthcode
1242
- * @default false
1243
- */
1244
- allowRegistrationWithAuthCode: boolean;
1245
- auth_code_generator?: components["schemas"]["AuthCodeGenerator"];
1246
- };
1247
1238
  /** SecurityQuestion */
1248
1239
  SecurityQuestion: {
1249
1240
  security_question: components["schemas"]["QuestionFields"];
@@ -1454,6 +1445,37 @@ export declare type operations = {
1454
1445
  };
1455
1446
  };
1456
1447
  };
1448
+ calcualte_custom_counts_instances__instance_name__custom_counts_post: {
1449
+ parameters: {
1450
+ path: {
1451
+ instance_name: string;
1452
+ };
1453
+ query: {
1454
+ include_deleted?: boolean;
1455
+ };
1456
+ };
1457
+ responses: {
1458
+ /** Successful Response */
1459
+ 200: {
1460
+ content: {
1461
+ "application/json": {
1462
+ [key: string]: number;
1463
+ };
1464
+ };
1465
+ };
1466
+ /** Validation Error */
1467
+ 422: {
1468
+ content: {
1469
+ "application/json": components["schemas"]["HTTPValidationError"];
1470
+ };
1471
+ };
1472
+ };
1473
+ requestBody: {
1474
+ content: {
1475
+ "application/json": components["schemas"]["CustomCountQuery"];
1476
+ };
1477
+ };
1478
+ };
1457
1479
  /** Send a list of events to be applied to the current state. Events are executed in order. */
1458
1480
  create_events_events_post: {
1459
1481
  responses: {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@dev-crew-berlin/enter-js-utils",
3
- "version": "0.49.0",
3
+ "version": "0.50.2",
4
4
  "description": "utils such as vaildation and other helpers to work with data from the enter app",
5
5
  "files": [
6
6
  "dist",