@extrahorizon/javascript-sdk 8.9.0-dev-138-3022f93 → 8.9.0-dev-140-d9dfc1d

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.
@@ -5610,7 +5610,7 @@ const templatesV2Service = (httpWithAuth) => {
5610
5610
  };
5611
5611
  };
5612
5612
 
5613
- const version = '8.9.0-dev-138-3022f93';
5613
+ const version = '8.9.0-dev-140-d9dfc1d';
5614
5614
 
5615
5615
  /**
5616
5616
  * Create ExtraHorizon client.
package/build/index.mjs CHANGED
@@ -5580,7 +5580,7 @@ const templatesV2Service = (httpWithAuth) => {
5580
5580
  };
5581
5581
  };
5582
5582
 
5583
- const version = '8.9.0-dev-138-3022f93';
5583
+ const version = '8.9.0-dev-140-d9dfc1d';
5584
5584
 
5585
5585
  /**
5586
5586
  * Create ExtraHorizon client.
@@ -1,7 +1,9 @@
1
1
  /// <reference types="node" />
2
2
  import { FindAllIterator } from '../../services/helpers';
3
3
  import { ObjectId, LanguageCode, TimeZone, PagedResult, AffectedRecords, OptionsWithRql, OptionsBase } from '../types';
4
- export interface TemplateOut {
4
+ export declare type TemplateOut = Template;
5
+ export declare type TemplateIn = TemplateCreation;
6
+ export interface Template {
5
7
  id: ObjectId;
6
8
  name: string;
7
9
  description: string;
@@ -10,7 +12,7 @@ export interface TemplateOut {
10
12
  creationTimestamp: Date;
11
13
  updateTimestamp: Date;
12
14
  }
13
- export interface TemplateIn {
15
+ export interface TemplateCreation {
14
16
  name: string;
15
17
  description: string;
16
18
  schema: TemplateObjectConfiguration;
@@ -24,6 +26,7 @@ export interface TemplateObjectConfiguration {
24
26
  }
25
27
  export interface TemplateArrayConfiguration {
26
28
  type: 'array';
29
+ type_configuration: TemplateTypeConfiguration;
27
30
  options?: TemplateArrayOption[];
28
31
  }
29
32
  export interface TemplateStringConfiguration {
@@ -97,7 +100,7 @@ export interface TemplatesService {
97
100
  * @param rql Add filters to the requested list.
98
101
  * @returns PagedResult<TemplateOut>
99
102
  */
100
- find(options?: OptionsWithRql): Promise<PagedResult<TemplateOut>>;
103
+ find(options?: OptionsWithRql): Promise<PagedResult<Template>>;
101
104
  /**
102
105
  * Request a list of all templates
103
106
  *
@@ -109,7 +112,7 @@ export interface TemplatesService {
109
112
  * @param rql Add filters to the requested list.
110
113
  * @returns TemplateOut[]
111
114
  */
112
- findAll(options?: OptionsWithRql): Promise<TemplateOut[]>;
115
+ findAll(options?: OptionsWithRql): Promise<Template[]>;
113
116
  /**
114
117
  * Request a list of all templates
115
118
  *
@@ -119,24 +122,24 @@ export interface TemplatesService {
119
122
  * @param rql Add filters to the requested list.
120
123
  * @returns TemplateOut[]
121
124
  */
122
- findAllIterator(options?: OptionsWithRql): FindAllIterator<TemplateOut>;
125
+ findAllIterator(options?: OptionsWithRql): FindAllIterator<Template>;
123
126
  /**
124
127
  * Find By Id
125
128
  * @param id the Id to search for
126
129
  * @returns the first element found
127
130
  */
128
- findById(id: ObjectId, options?: OptionsWithRql): Promise<TemplateOut | undefined>;
131
+ findById(id: ObjectId, options?: OptionsWithRql): Promise<Template | undefined>;
129
132
  /**
130
133
  * Find By Name
131
134
  * @param name the name to search for
132
135
  * @returns the first element found
133
136
  */
134
- findByName(name: string, options?: OptionsWithRql): Promise<TemplateOut | undefined>;
137
+ findByName(name: string, options?: OptionsWithRql): Promise<Template | undefined>;
135
138
  /**
136
139
  * Find First
137
140
  * @returns the first element found
138
141
  */
139
- findFirst(options?: OptionsWithRql): Promise<TemplateOut | undefined>;
142
+ findFirst(options?: OptionsWithRql): Promise<Template | undefined>;
140
143
  /**
141
144
  * Create a new template
142
145
  *
@@ -146,7 +149,7 @@ export interface TemplatesService {
146
149
  * @param requestBody TemplateIn
147
150
  * @returns TemplateOut
148
151
  */
149
- create(requestBody: TemplateIn, options?: OptionsBase): Promise<TemplateOut>;
152
+ create(requestBody: TemplateCreation, options?: OptionsBase): Promise<Template>;
150
153
  /**
151
154
  * Update an existing template
152
155
  *
@@ -158,7 +161,7 @@ export interface TemplatesService {
158
161
  * @returns TemplateOut
159
162
  * @throws {ResourceUnknownError}
160
163
  */
161
- update(templateId: string, requestBody: TemplateIn, options?: OptionsBase): Promise<TemplateOut>;
164
+ update(templateId: string, requestBody: TemplateCreation, options?: OptionsBase): Promise<Template>;
162
165
  /**
163
166
  * Delete a template
164
167
  *
@@ -9,6 +9,7 @@ export * from './services/tasks/types';
9
9
  export * from './services/users/types';
10
10
  export * from './services/mails/types';
11
11
  export * from './services/templates/types';
12
+ export * from './services/templatesV2/types';
12
13
  export * from './services/configurations/types';
13
14
  export * from './services/dispatchers/types';
14
15
  export * from './services/payments/types';
@@ -1 +1 @@
1
- export declare const version = "8.9.0-dev-138-3022f93";
1
+ export declare const version = "8.9.0-dev-140-d9dfc1d";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@extrahorizon/javascript-sdk",
3
- "version": "8.9.0-dev-138-3022f93",
3
+ "version": "8.9.0-dev-140-d9dfc1d",
4
4
  "description": "This package serves as a JavaScript wrapper around all Extra Horizon cloud services.",
5
5
  "main": "build/index.cjs.js",
6
6
  "types": "build/types/index.d.ts",