@aptly-as/types 1.8.0 → 1.9.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.
Files changed (91) hide show
  1. package/core/api.js +1 -2
  2. package/core/app.d.ts +2 -2
  3. package/core/app.js +2 -5
  4. package/core/cloudinary.d.ts +1 -1
  5. package/core/cloudinary.js +1 -2
  6. package/core/error.d.ts +1 -1
  7. package/core/error.js +1 -2
  8. package/core/fields.d.ts +1 -1
  9. package/core/fields.js +1 -2
  10. package/core/index.d.ts +10 -10
  11. package/core/index.js +9 -21
  12. package/core/permission.d.ts +8 -22
  13. package/core/permission.js +9 -11
  14. package/core/scope.d.ts +3 -3
  15. package/core/scope.js +2 -5
  16. package/core/signage.d.ts +3 -3
  17. package/core/signage.js +1 -2
  18. package/core/webhook-event-data.d.ts +1 -1
  19. package/core/webhook-event-data.js +1 -2
  20. package/enums/document.js +4 -7
  21. package/enums/fields.js +2 -5
  22. package/enums/index.d.ts +4 -4
  23. package/enums/index.js +36 -49
  24. package/enums/unit-template.js +4 -7
  25. package/enums/webhook.js +6 -9
  26. package/index.d.ts +3 -3
  27. package/index.js +3 -15
  28. package/models/algorithm.d.ts +2 -2
  29. package/models/algorithm.js +4 -7
  30. package/models/app.d.ts +8 -8
  31. package/models/app.js +6 -9
  32. package/models/availability.js +1 -2
  33. package/models/booking.d.ts +7 -6
  34. package/models/booking.js +1 -2
  35. package/models/client.d.ts +3 -6
  36. package/models/client.js +1 -2
  37. package/models/department.d.ts +11 -11
  38. package/models/department.js +1 -2
  39. package/models/document.d.ts +4 -10
  40. package/models/document.js +1 -2
  41. package/models/extends.d.ts +4 -10
  42. package/models/extends.js +1 -2
  43. package/models/index.d.ts +30 -29
  44. package/models/index.js +30 -41
  45. package/models/inquiry.d.ts +9 -12
  46. package/models/inquiry.js +1 -2
  47. package/models/media.d.ts +5 -14
  48. package/models/media.js +1 -2
  49. package/models/note.d.ts +18 -0
  50. package/models/note.js +1 -0
  51. package/models/notification-trigger.d.ts +1 -1
  52. package/models/notification-trigger.js +1 -2
  53. package/models/option-label.d.ts +2 -5
  54. package/models/option-label.js +1 -2
  55. package/models/order.d.ts +8 -11
  56. package/models/order.js +1 -2
  57. package/models/organization.d.ts +13 -16
  58. package/models/organization.js +1 -2
  59. package/models/page.d.ts +4 -13
  60. package/models/page.js +1 -2
  61. package/models/producer.d.ts +3 -9
  62. package/models/producer.js +1 -2
  63. package/models/product-stats.d.ts +2 -2
  64. package/models/product-stats.js +1 -2
  65. package/models/product.d.ts +7 -13
  66. package/models/product.js +1 -2
  67. package/models/project.d.ts +14 -31
  68. package/models/project.js +1 -2
  69. package/models/queue-download.d.ts +5 -5
  70. package/models/queue-download.js +1 -2
  71. package/models/recommendation.d.ts +3 -3
  72. package/models/recommendation.js +1 -2
  73. package/models/supplier.d.ts +3 -6
  74. package/models/supplier.js +1 -2
  75. package/models/tag.d.ts +2 -5
  76. package/models/tag.js +1 -2
  77. package/models/unit-email.d.ts +7 -10
  78. package/models/unit-email.js +2 -5
  79. package/models/unit-template.d.ts +17 -26
  80. package/models/unit-template.js +1 -2
  81. package/models/unit.d.ts +20 -34
  82. package/models/unit.js +1 -2
  83. package/models/upsell-template.d.ts +2 -8
  84. package/models/upsell-template.js +1 -2
  85. package/models/user.d.ts +2 -5
  86. package/models/user.js +1 -2
  87. package/models/webhook-event.d.ts +5 -8
  88. package/models/webhook-event.js +1 -2
  89. package/models/webhook.d.ts +3 -6
  90. package/models/webhook.js +1 -2
  91. package/package.json +7 -8
@@ -1,16 +1,13 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.AptlyAlgorithmPipelineApplyTo = exports.AptlyAlgorithmPipelineOperation = void 0;
4
- var AptlyAlgorithmPipelineOperation;
1
+ export var AptlyAlgorithmPipelineOperation;
5
2
  (function (AptlyAlgorithmPipelineOperation) {
6
3
  AptlyAlgorithmPipelineOperation["Base"] = "base";
7
4
  AptlyAlgorithmPipelineOperation["Add"] = "add";
8
5
  AptlyAlgorithmPipelineOperation["Subtract"] = "subtract";
9
6
  AptlyAlgorithmPipelineOperation["Multiply"] = "multiply";
10
- })(AptlyAlgorithmPipelineOperation = exports.AptlyAlgorithmPipelineOperation || (exports.AptlyAlgorithmPipelineOperation = {}));
11
- var AptlyAlgorithmPipelineApplyTo;
7
+ })(AptlyAlgorithmPipelineOperation || (AptlyAlgorithmPipelineOperation = {}));
8
+ export var AptlyAlgorithmPipelineApplyTo;
12
9
  (function (AptlyAlgorithmPipelineApplyTo) {
13
10
  AptlyAlgorithmPipelineApplyTo["Base"] = "base";
14
11
  AptlyAlgorithmPipelineApplyTo["Root"] = "root";
15
12
  AptlyAlgorithmPipelineApplyTo["PreviousStep"] = "previousStep";
16
- })(AptlyAlgorithmPipelineApplyTo = exports.AptlyAlgorithmPipelineApplyTo || (exports.AptlyAlgorithmPipelineApplyTo = {}));
13
+ })(AptlyAlgorithmPipelineApplyTo || (AptlyAlgorithmPipelineApplyTo = {}));
package/models/app.d.ts CHANGED
@@ -1,8 +1,8 @@
1
- import { AptlyBaseSchema } from './extends';
2
- import { AptlyWebhookType } from '../enums';
3
- import { AptlyAppSandbox, AptlyField, AptlyPermissionModel } from '../core';
4
- import { AptlyMediaSrcSchema } from './media';
5
- export declare type AptlyApp = AptlyAppSchema<string, string>;
1
+ import { AptlyBaseSchema } from './extends.js';
2
+ import { AptlyWebhookType } from '../enums/index.js';
3
+ import { AptlyAppSandbox, AptlyField, AptlyPermissionModel } from '../core/index.js';
4
+ import { AptlyMediaSrcSchema } from './media.js';
5
+ export type AptlyApp = AptlyAppSchema<string, string>;
6
6
  export interface AptlyAppSchema<ID, DATE> extends Omit<AptlyBaseSchema<ID, DATE>, 'archived'> {
7
7
  slug: string;
8
8
  description: string;
@@ -16,7 +16,7 @@ export interface AptlyAppSchema<ID, DATE> extends Omit<AptlyBaseSchema<ID, DATE>
16
16
  proxies: AptlyAppProxySchema<ID>[];
17
17
  menus: AptlyAppMenuSchema<ID, DATE>[];
18
18
  }
19
- export declare type AptlyAppSetting = AptlyAppSettingSchema<string>;
19
+ export type AptlyAppSetting = AptlyAppSettingSchema<string>;
20
20
  export interface AptlyAppSettingSchema<ID> extends AptlyField {
21
21
  _id: ID;
22
22
  key: string;
@@ -44,11 +44,11 @@ export declare enum AptlyProjectInjection {
44
44
  Support = "support",
45
45
  Admin = "admin"
46
46
  }
47
- export declare type AptlyAppInjectionMenu = `organization-${AptlyOrganizationInjection}` | `project-${AptlyProjectInjection}`;
47
+ export type AptlyAppInjectionMenu = `organization-${AptlyOrganizationInjection}` | `project-${AptlyProjectInjection}`;
48
48
  export declare enum AptlyAppInjectionType {
49
49
  Iframe = "iframe"
50
50
  }
51
- export declare type AptlyAppMenu = AptlyAppMenuSchema<string, string>;
51
+ export type AptlyAppMenu = AptlyAppMenuSchema<string, string>;
52
52
  export interface AptlyAppMenuSchema<ID, DATE> {
53
53
  _id: ID;
54
54
  type: AptlyAppInjectionType;
package/models/app.js CHANGED
@@ -1,7 +1,4 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.AptlyAppInjectionType = exports.AptlyProjectInjection = exports.AptlyOrganizationInjection = void 0;
4
- var AptlyOrganizationInjection;
1
+ export var AptlyOrganizationInjection;
5
2
  (function (AptlyOrganizationInjection) {
6
3
  AptlyOrganizationInjection["Base"] = "";
7
4
  AptlyOrganizationInjection["Project"] = "project";
@@ -9,8 +6,8 @@ var AptlyOrganizationInjection;
9
6
  AptlyOrganizationInjection["Products"] = "products";
10
7
  AptlyOrganizationInjection["Content"] = "content";
11
8
  AptlyOrganizationInjection["Admin"] = "admin";
12
- })(AptlyOrganizationInjection = exports.AptlyOrganizationInjection || (exports.AptlyOrganizationInjection = {}));
13
- var AptlyProjectInjection;
9
+ })(AptlyOrganizationInjection || (AptlyOrganizationInjection = {}));
10
+ export var AptlyProjectInjection;
14
11
  (function (AptlyProjectInjection) {
15
12
  AptlyProjectInjection["Base"] = "";
16
13
  AptlyProjectInjection["Options"] = "options";
@@ -19,8 +16,8 @@ var AptlyProjectInjection;
19
16
  AptlyProjectInjection["Project"] = "project";
20
17
  AptlyProjectInjection["Support"] = "support";
21
18
  AptlyProjectInjection["Admin"] = "admin";
22
- })(AptlyProjectInjection = exports.AptlyProjectInjection || (exports.AptlyProjectInjection = {}));
23
- var AptlyAppInjectionType;
19
+ })(AptlyProjectInjection || (AptlyProjectInjection = {}));
20
+ export var AptlyAppInjectionType;
24
21
  (function (AptlyAppInjectionType) {
25
22
  AptlyAppInjectionType["Iframe"] = "iframe";
26
- })(AptlyAppInjectionType = exports.AptlyAppInjectionType || (exports.AptlyAppInjectionType = {}));
23
+ })(AptlyAppInjectionType || (AptlyAppInjectionType = {}));
@@ -1,2 +1 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
1
+ export {};
@@ -1,19 +1,20 @@
1
1
  import { AptlyOrganizationSchema } from './organization.js';
2
2
  import { AptlyProjectSchema } from './project.js';
3
3
  import { AptlyUnitSchema } from './unit.js';
4
- export declare type AptlyBooking = AptlyBookingSchema<string, string>;
4
+ export type AptlyBooking = AptlyBookingSchema<string, string>;
5
5
  export interface AptlyBookingSchema<ID, DATE> {
6
6
  _id: ID;
7
+ organization: ID | AptlyOrganizationSchema<ID, DATE>;
7
8
  project: ID | AptlyProjectSchema<ID, DATE>;
8
9
  unit: ID | AptlyUnitSchema<ID, DATE>;
9
10
  user: ID;
10
- availability: ID;
11
- calendar: ID;
11
+ availability: ID | AptlyAvailabilitySchema<ID, DATE>;
12
+ calendar: ID | AptlyAvailabilityCalendarSchema<ID, DATE>;
12
13
  availableTime: ID;
13
14
  from: DATE;
14
15
  to: DATE;
15
16
  }
16
- export declare type AptlyAvailability = AptlyAvailabilitySchema<string, string>;
17
+ export type AptlyAvailability = AptlyAvailabilitySchema<string, string>;
17
18
  export interface AptlyAvailabilitySchema<ID, DATE> {
18
19
  _id: ID;
19
20
  organization?: ID | AptlyOrganizationSchema<ID, DATE>;
@@ -21,7 +22,7 @@ export interface AptlyAvailabilitySchema<ID, DATE> {
21
22
  archived?: boolean;
22
23
  calendars: AptlyAvailabilityCalendarSchema<ID, DATE>[];
23
24
  }
24
- export declare type AptlyAvailabilityCalendar = AptlyAvailabilityCalendarSchema<string, string>;
25
+ export type AptlyAvailabilityCalendar = AptlyAvailabilityCalendarSchema<string, string>;
25
26
  export interface AptlyAvailabilityCalendarSchema<ID, DATE> {
26
27
  _id: ID;
27
28
  name: string;
@@ -42,7 +43,7 @@ export interface AptlyAvailabilityCalendarSchema<ID, DATE> {
42
43
  endAvailabilityAt?: DATE;
43
44
  userAvailability?: ID[];
44
45
  }
45
- export declare type AptlyAvailabilityCalendarAvailableTimes = AptlyAvailabilityCalendarAvailableTimesSchema<string, string>;
46
+ export type AptlyAvailabilityCalendarAvailableTimes = AptlyAvailabilityCalendarAvailableTimesSchema<string, string>;
46
47
  export interface AptlyAvailabilityCalendarAvailableTimesSchema<ID, DATE> {
47
48
  _id: ID;
48
49
  from: DATE;
package/models/booking.js CHANGED
@@ -1,2 +1 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
1
+ export {};
@@ -1,14 +1,11 @@
1
- import { AptlyBaseSchema } from './extends';
2
- import { AptlyPermissionSchema } from '../core';
1
+ import { AptlyBaseSchema } from './extends.js';
2
+ import { AptlyPermissionSchema } from '../core/index.js';
3
3
  export interface AptlyUserClientSchema<ID, DATE> extends Omit<AptlyBaseSchema<ID, DATE>, 'archived'> {
4
4
  user: ID;
5
5
  subject: string;
6
6
  clientId: string;
7
7
  clientSecret?: string;
8
8
  permissions: AptlyPermissionSchema;
9
- /**
10
- * @deprecated use createdAt
11
- */
12
9
  created: DATE;
13
10
  }
14
- export declare type AptlyUserClient = AptlyUserClientSchema<string, string>;
11
+ export type AptlyUserClient = AptlyUserClientSchema<string, string>;
package/models/client.js CHANGED
@@ -1,2 +1 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
1
+ export {};
@@ -1,27 +1,27 @@
1
- import { AptlyPermissionOrganizationModels } from '../core';
2
- import { AptlyOrganizationSchema } from './organization';
3
- import { AptlyProjectSchema } from './project';
4
- import { AptlyUserSchema } from './user';
5
- import { AptlyBaseSchema } from './extends';
6
- import { AptlyUnitSchema } from './unit';
7
- export declare type AptlyDepartment = AptlyDepartmentGeneric<string, string>;
1
+ import { AptlyPermissionOrganizationModels } from '../core/index.js';
2
+ import { AptlyOrganizationSchema } from './organization.js';
3
+ import { AptlyProjectSchema } from './project.js';
4
+ import { AptlyUserSchema } from './user.js';
5
+ import { AptlyBaseSchema } from './extends.js';
6
+ import { AptlyUnitSchema } from './unit.js';
7
+ export type AptlyDepartment = AptlyDepartmentGeneric<string, string>;
8
8
  export interface AptlyDepartmentGeneric<ID, DATE> extends Omit<AptlyBaseSchema<ID, DATE>, 'archived'> {
9
9
  organization: ID | AptlyOrganizationSchema<ID, DATE>;
10
10
  projects: AptlyDepartmentProjectGeneric<ID, DATE>[];
11
11
  users: AptlyDepartmentUserGeneric<ID, DATE>[];
12
12
  }
13
- export declare type AptlyDepartmentProject = AptlyDepartmentProjectGeneric<string, string>;
13
+ export type AptlyDepartmentProject = AptlyDepartmentProjectGeneric<string, string>;
14
14
  export interface AptlyDepartmentProjectGeneric<ID, DATE> {
15
15
  _id: ID;
16
- project: (ID | AptlyProjectSchema<ID, DATE>);
16
+ project: ID | AptlyProjectSchema<ID, DATE>;
17
17
  units: (ID | AptlyUnitSchema<ID, DATE>)[] | null;
18
18
  createdAt: DATE;
19
19
  updatedAt: DATE;
20
20
  }
21
- export declare type AptlyDepartmentUser = AptlyDepartmentUserGeneric<string, string>;
21
+ export type AptlyDepartmentUser = AptlyDepartmentUserGeneric<string, string>;
22
22
  export interface AptlyDepartmentUserGeneric<ID, DATE> {
23
23
  _id: ID;
24
- user: (ID | AptlyUserSchema<ID, DATE>);
24
+ user: ID | AptlyUserSchema<ID, DATE>;
25
25
  permissions: AptlyPermissionOrganizationModels[];
26
26
  createdAt: DATE;
27
27
  updatedAt: DATE;
@@ -1,2 +1 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
1
+ export {};
@@ -1,6 +1,6 @@
1
- import { AptlyDocumentType } from '../enums';
2
- import { AptlyBaseSchema } from './extends';
3
- export declare type AptlyDocument = AptlyDocumentSchema<string, string>;
1
+ import { AptlyDocumentType } from '../enums/index.js';
2
+ import { AptlyBaseSchema } from './extends.js';
3
+ export type AptlyDocument = AptlyDocumentSchema<string, string>;
4
4
  export interface AptlyDocumentSchema<ID, DATE> extends Omit<AptlyBaseSchema<ID, DATE>, 'archived'> {
5
5
  mime: string;
6
6
  _type: AptlyDocumentType;
@@ -18,16 +18,10 @@ export interface AptlyDocumentSchema<ID, DATE> extends Omit<AptlyBaseSchema<ID,
18
18
  boligmappaStatus?: AptlyDocumentSchemaBoligmappaStatusSchema<ID>[];
19
19
  chunks?: (AptlyDocumentSchema<ID, DATE> | ID)[];
20
20
  isPasswordProtected?: boolean;
21
- /**
22
- * Used in frontend.
23
- */
24
21
  downloadToken?: string;
25
- /**
26
- * @deprecated use createdAt
27
- */
28
22
  created: DATE;
29
23
  }
30
- export declare type AptlyDocumentSchemaBoligmappaStatus = AptlyDocumentSchemaBoligmappaStatusSchema<string>;
24
+ export type AptlyDocumentSchemaBoligmappaStatus = AptlyDocumentSchemaBoligmappaStatusSchema<string>;
31
25
  export interface AptlyDocumentSchemaBoligmappaStatusSchema<ID> {
32
26
  _id: ID;
33
27
  unit: ID;
@@ -1,2 +1 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
1
+ export {};
@@ -1,5 +1,5 @@
1
- import { AptlyUserSchema } from './user';
2
- import { AptlyHistoryType } from '../enums';
1
+ import { AptlyUserSchema } from './user.js';
2
+ import { AptlyHistoryType } from '../enums/index.js';
3
3
  export interface AptlyBaseSchema<ID, DATE> {
4
4
  _id: ID;
5
5
  name: string;
@@ -7,19 +7,13 @@ export interface AptlyBaseSchema<ID, DATE> {
7
7
  createdAt: DATE;
8
8
  updatedAt: DATE;
9
9
  }
10
- export declare type AptlyHistory = AptlyHistorySchema<string, string>;
10
+ export type AptlyHistory = AptlyHistorySchema<string, string>;
11
11
  export interface AptlyHistorySchema<ID, DATE> {
12
- /**
13
- * @deprecated not used in v2
14
- */
15
12
  locked: boolean;
16
- /**
17
- * @deprecated use updatedAt
18
- */
19
13
  lastChange: DATE;
20
14
  history: AptlyHistoryHistorySchema<ID, DATE>[];
21
15
  }
22
- export declare type AptlyHistoryHistory = AptlyHistoryHistorySchema<string, string>;
16
+ export type AptlyHistoryHistory = AptlyHistoryHistorySchema<string, string>;
23
17
  export interface AptlyHistoryHistorySchema<ID, DATE> {
24
18
  _id: ID;
25
19
  type: AptlyHistoryType;
package/models/extends.js CHANGED
@@ -1,2 +1 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
1
+ export {};
package/models/index.d.ts CHANGED
@@ -1,29 +1,30 @@
1
- export * from './algorithm';
2
- export * from './app';
3
- export * from './booking';
4
- export * from './client';
5
- export * from './department';
6
- export * from './document';
7
- export * from './extends';
8
- export * from './inquiry';
9
- export * from './media';
10
- export * from './notification-trigger';
11
- export * from './option-label';
12
- export * from './order';
13
- export * from './organization';
14
- export * from './page';
15
- export * from './producer';
16
- export * from './product';
17
- export * from './product-stats';
18
- export * from './project';
19
- export * from './queue-download';
20
- export * from './recommendation';
21
- export * from './supplier';
22
- export * from './tag';
23
- export * from './unit';
24
- export * from './unit-template';
25
- export * from './unit-email';
26
- export * from './upsell-template';
27
- export * from './user';
28
- export * from './webhook';
29
- export * from './webhook-event';
1
+ export * from './algorithm.js';
2
+ export * from './app.js';
3
+ export * from './booking.js';
4
+ export * from './client.js';
5
+ export * from './department.js';
6
+ export * from './document.js';
7
+ export * from './extends.js';
8
+ export * from './inquiry.js';
9
+ export * from './media.js';
10
+ export * from './note.js';
11
+ export * from './notification-trigger.js';
12
+ export * from './option-label.js';
13
+ export * from './order.js';
14
+ export * from './organization.js';
15
+ export * from './page.js';
16
+ export * from './producer.js';
17
+ export * from './product.js';
18
+ export * from './product-stats.js';
19
+ export * from './project.js';
20
+ export * from './queue-download.js';
21
+ export * from './recommendation.js';
22
+ export * from './supplier.js';
23
+ export * from './tag.js';
24
+ export * from './unit.js';
25
+ export * from './unit-template.js';
26
+ export * from './unit-email.js';
27
+ export * from './upsell-template.js';
28
+ export * from './user.js';
29
+ export * from './webhook.js';
30
+ export * from './webhook-event.js';
package/models/index.js CHANGED
@@ -1,41 +1,30 @@
1
- "use strict";
2
- var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
- if (k2 === undefined) k2 = k;
4
- Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
5
- }) : (function(o, m, k, k2) {
6
- if (k2 === undefined) k2 = k;
7
- o[k2] = m[k];
8
- }));
9
- var __exportStar = (this && this.__exportStar) || function(m, exports) {
10
- for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
11
- };
12
- Object.defineProperty(exports, "__esModule", { value: true });
13
- __exportStar(require("./algorithm"), exports);
14
- __exportStar(require("./app"), exports);
15
- __exportStar(require("./booking"), exports);
16
- __exportStar(require("./client"), exports);
17
- __exportStar(require("./department"), exports);
18
- __exportStar(require("./document"), exports);
19
- __exportStar(require("./extends"), exports);
20
- __exportStar(require("./inquiry"), exports);
21
- __exportStar(require("./media"), exports);
22
- __exportStar(require("./notification-trigger"), exports);
23
- __exportStar(require("./option-label"), exports);
24
- __exportStar(require("./order"), exports);
25
- __exportStar(require("./organization"), exports);
26
- __exportStar(require("./page"), exports);
27
- __exportStar(require("./producer"), exports);
28
- __exportStar(require("./product"), exports);
29
- __exportStar(require("./product-stats"), exports);
30
- __exportStar(require("./project"), exports);
31
- __exportStar(require("./queue-download"), exports);
32
- __exportStar(require("./recommendation"), exports);
33
- __exportStar(require("./supplier"), exports);
34
- __exportStar(require("./tag"), exports);
35
- __exportStar(require("./unit"), exports);
36
- __exportStar(require("./unit-template"), exports);
37
- __exportStar(require("./unit-email"), exports);
38
- __exportStar(require("./upsell-template"), exports);
39
- __exportStar(require("./user"), exports);
40
- __exportStar(require("./webhook"), exports);
41
- __exportStar(require("./webhook-event"), exports);
1
+ export * from './algorithm.js';
2
+ export * from './app.js';
3
+ export * from './booking.js';
4
+ export * from './client.js';
5
+ export * from './department.js';
6
+ export * from './document.js';
7
+ export * from './extends.js';
8
+ export * from './inquiry.js';
9
+ export * from './media.js';
10
+ export * from './note.js';
11
+ export * from './notification-trigger.js';
12
+ export * from './option-label.js';
13
+ export * from './order.js';
14
+ export * from './organization.js';
15
+ export * from './page.js';
16
+ export * from './producer.js';
17
+ export * from './product.js';
18
+ export * from './product-stats.js';
19
+ export * from './project.js';
20
+ export * from './queue-download.js';
21
+ export * from './recommendation.js';
22
+ export * from './supplier.js';
23
+ export * from './tag.js';
24
+ export * from './unit.js';
25
+ export * from './unit-template.js';
26
+ export * from './unit-email.js';
27
+ export * from './upsell-template.js';
28
+ export * from './user.js';
29
+ export * from './webhook.js';
30
+ export * from './webhook-event.js';
@@ -1,10 +1,10 @@
1
- import { AptlyInquiryParticipantRole, AptlyInquiryStatus, AptlyInquiryType } from '../enums';
2
- import { AptlySchemaFile } from '../core';
3
- import { AptlyUnitSchema } from './unit';
4
- import { AptlyOrganizationSchema } from './organization';
5
- import { AptlyProjectSchema } from './project';
6
- import { AptlyUserSchema } from './user';
7
- export declare type AptlyInquiry = AptlyInquirySchema<string, string>;
1
+ import { AptlyInquiryParticipantRole, AptlyInquiryStatus, AptlyInquiryType } from '../enums/index.js';
2
+ import { AptlySchemaFile } from '../core/index.js';
3
+ import { AptlyUnitSchema } from './unit.js';
4
+ import { AptlyOrganizationSchema } from './organization.js';
5
+ import { AptlyProjectSchema } from './project.js';
6
+ import { AptlyUserSchema } from './user.js';
7
+ export type AptlyInquiry = AptlyInquirySchema<string, string>;
8
8
  export interface AptlyInquirySchema<ID, DATE> {
9
9
  _id: ID;
10
10
  _type: AptlyInquiryType;
@@ -26,7 +26,7 @@ export interface AptlyInquirySchema<ID, DATE> {
26
26
  messages: AptlyInquiryMessageSchema<ID, DATE>[];
27
27
  references?: string;
28
28
  }
29
- export declare type AptlyInquiryParticipant = AptlyInquiryParticipantSchema<string, string>;
29
+ export type AptlyInquiryParticipant = AptlyInquiryParticipantSchema<string, string>;
30
30
  export interface AptlyInquiryParticipantSchema<ID, DATE> {
31
31
  _id: ID;
32
32
  user?: ID | AptlyUserSchema<ID, DATE>;
@@ -34,13 +34,10 @@ export interface AptlyInquiryParticipantSchema<ID, DATE> {
34
34
  role: AptlyInquiryParticipantRole;
35
35
  readAll: boolean;
36
36
  }
37
- export declare type AptlyInquiryMessage = AptlyInquiryMessageSchema<string, string>;
37
+ export type AptlyInquiryMessage = AptlyInquiryMessageSchema<string, string>;
38
38
  export interface AptlyInquiryMessageSchema<ID, DATE> {
39
39
  _id: ID;
40
40
  message: string;
41
- /**
42
- * @deprecated Use files instead
43
- */
44
41
  images?: string[];
45
42
  files: AptlySchemaFile[];
46
43
  author?: ID;
package/models/inquiry.js CHANGED
@@ -1,2 +1 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
1
+ export {};
package/models/media.d.ts CHANGED
@@ -1,5 +1,5 @@
1
- import { AptlyOrganizationSchema } from './organization';
2
- import { AptlyBaseSchema } from './extends';
1
+ import { AptlyOrganizationSchema } from './organization.js';
2
+ import { AptlyBaseSchema } from './extends.js';
3
3
  export interface AptlyMediaSchema<ID, DATE> extends AptlyBaseSchema<ID, DATE> {
4
4
  organization: ID | AptlyOrganizationSchema<ID, DATE>;
5
5
  src: string;
@@ -25,13 +25,7 @@ export interface AptlyMediaSchema<ID, DATE> extends AptlyBaseSchema<ID, DATE> {
25
25
  placeholder: boolean;
26
26
  url: string;
27
27
  original_filename: string;
28
- /**
29
- * @deprecated use createdAt
30
- */
31
28
  created: DATE;
32
- /**
33
- * @deprecated use updatedAt
34
- */
35
29
  updated: DATE;
36
30
  srcUrl?: string;
37
31
  uploadSignature?: string;
@@ -49,11 +43,8 @@ export interface AptlyMediaSrcLocation {
49
43
  export interface AptlyMediaSrcSchema<ID, DATE> extends Pick<AptlyMediaSchema<ID, DATE>, AptlyMediaSrcKeys> {
50
44
  area?: AptlyMediaSrcArea;
51
45
  location?: AptlyMediaSrcLocation;
52
- /**
53
- * @deprecated used my product images. Is slowly replaced with src/url
54
- */
55
46
  image?: string;
56
47
  }
57
- export declare type AptlyMediaSrcKeys = '_id' | 'name' | 'src' | 'url' | 'alt' | 'title' | 'caption' | 'mime' | 'width' | 'height';
58
- export declare type AptlyMediaSrc = AptlyMediaSrcSchema<string, string>;
59
- export declare type AptlyMedia = AptlyMediaSchema<string, string>;
48
+ export type AptlyMediaSrcKeys = '_id' | 'name' | 'src' | 'url' | 'alt' | 'title' | 'caption' | 'mime' | 'width' | 'height';
49
+ export type AptlyMediaSrc = AptlyMediaSrcSchema<string, string>;
50
+ export type AptlyMedia = AptlyMediaSchema<string, string>;
package/models/media.js CHANGED
@@ -1,2 +1 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
1
+ export {};
@@ -0,0 +1,18 @@
1
+ import { AptlyBaseSchema } from './extends.js';
2
+ import { AptlyOrganizationSchema } from './organization.js';
3
+ import { AptlyProjectSchema } from './project.js';
4
+ import { AptlyUnitSchema } from './unit.js';
5
+ import { AptlyUserSchema } from './user.js';
6
+ export type AptlyNote = AptlyNoteSchema<string, string>;
7
+ export interface AptlyNoteSchema<ID, DATE> extends AptlyBaseSchema<ID, DATE> {
8
+ content: string;
9
+ organization: ID | AptlyOrganizationSchema<ID, DATE>;
10
+ project: ID | AptlyProjectSchema<ID, DATE>;
11
+ unit: ID | AptlyUnitSchema<ID, DATE>;
12
+ users: (ID | AptlyUserSchema<ID, DATE>)[];
13
+ addToReceipt: boolean;
14
+ unitTemplateCategory: ID | null;
15
+ unitTemplateProduct?: ID | null;
16
+ deadlineAt?: DATE | null;
17
+ hasDeadline?: boolean;
18
+ }
package/models/note.js ADDED
@@ -0,0 +1 @@
1
+ export {};
@@ -1,4 +1,4 @@
1
- export declare type AptlyNotificationTrigger = AptlyNotificationTriggerSchema<string, string>;
1
+ export type AptlyNotificationTrigger = AptlyNotificationTriggerSchema<string, string>;
2
2
  export interface AptlyNotificationTriggerSchema<ID, DATE> {
3
3
  _id: ID;
4
4
  _type: string;
@@ -1,2 +1 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
1
+ export {};
@@ -1,10 +1,7 @@
1
- import { AptlyBaseSchema } from './extends';
2
- export declare type AptlyOptionLabel = AptlyOptionLabelSchema<string, string>;
1
+ import { AptlyBaseSchema } from './extends.js';
2
+ export type AptlyOptionLabel = AptlyOptionLabelSchema<string, string>;
3
3
  export interface AptlyOptionLabelSchema<ID, DATE> extends AptlyBaseSchema<ID, DATE> {
4
4
  organization?: ID;
5
5
  project?: ID;
6
- /**
7
- * @deprecated use createdAt
8
- */
9
6
  created: DATE;
10
7
  }
@@ -1,2 +1 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
1
+ export {};
package/models/order.d.ts CHANGED
@@ -1,10 +1,10 @@
1
- import { AptlyOrderStatus } from '../enums';
1
+ import { AptlyOrderStatus } from '../enums/index.js';
2
2
  import { AptlyOrganizationSchema } from './organization.js';
3
3
  import { AptlyProjectPeriodSchema, AptlyProjectSchema } from './project.js';
4
- import { AptlyUnitItemParamSchema, AptlyUnitSchema } from './unit';
5
- import { AptlyBaseSchema } from './extends';
4
+ import { AptlyUnitItemParamSchema, AptlyUnitSchema } from './unit.js';
5
+ import { AptlyBaseSchema } from './extends.js';
6
6
  import { AptlyUserSchema } from './user.js';
7
- export declare type AptlyOrder = AptlyOrderSchema<string, string>;
7
+ export type AptlyOrder = AptlyOrderSchema<string, string>;
8
8
  export interface AptlyOrderSchema<ID, DATE> extends Omit<AptlyBaseSchema<ID, DATE>, 'name' | 'archived'> {
9
9
  orderNumber: string;
10
10
  organization: ID | AptlyOrganizationSchema<ID, DATE>;
@@ -19,18 +19,15 @@ export interface AptlyOrderSchema<ID, DATE> extends Omit<AptlyBaseSchema<ID, DAT
19
19
  items: AptlyOrderItemSchema<ID, DATE>[];
20
20
  totalCost: number;
21
21
  pricePipeline: AptlyOrderPricePipelineItemSchema<ID>[];
22
- /**
23
- * @deprecated use createdAt
24
- */
25
22
  created: DATE;
26
23
  }
27
- export declare type AptlyOrderPricePipelineItem = AptlyOrderPricePipelineItemSchema<string>;
24
+ export type AptlyOrderPricePipelineItem = AptlyOrderPricePipelineItemSchema<string>;
28
25
  export interface AptlyOrderPricePipelineItemSchema<ID> {
29
26
  _id: ID;
30
27
  label: string;
31
28
  value: number;
32
29
  }
33
- export declare type AptlyOrderSignage = AptlyOrderSignageSchema<string, string>;
30
+ export type AptlyOrderSignage = AptlyOrderSignageSchema<string, string>;
34
31
  export interface AptlyOrderSignageSchema<ID, DATE> {
35
32
  hasReceivedFile: boolean;
36
33
  signed: boolean;
@@ -43,7 +40,7 @@ export interface AptlyOrderSignageSchema<ID, DATE> {
43
40
  organizationSignedAt?: DATE;
44
41
  customerSignedAt?: DATE;
45
42
  }
46
- export declare type AptlyOrderItem = AptlyOrderItemSchema<string, string>;
43
+ export type AptlyOrderItem = AptlyOrderItemSchema<string, string>;
47
44
  export interface AptlyOrderItemSchema<ID, DATE> {
48
45
  _id: ID;
49
46
  text?: string;
@@ -55,7 +52,7 @@ export interface AptlyOrderItemSchema<ID, DATE> {
55
52
  unitCost: number;
56
53
  pricePipeline: AptlyOrderItemPricePipelineSchema<ID>[];
57
54
  }
58
- export declare type AptlyOrderItemPricePipeline = AptlyOrderItemPricePipelineSchema<string>;
55
+ export type AptlyOrderItemPricePipeline = AptlyOrderItemPricePipelineSchema<string>;
59
56
  export interface AptlyOrderItemPricePipelineSchema<ID> {
60
57
  _id: ID;
61
58
  label: string;
package/models/order.js CHANGED
@@ -1,2 +1 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
1
+ export {};