Skip to content

Commit 8660028

Browse files
Merge pull request #644 from HubSpot/feature/13.0.0
Feature/13.0.0
2 parents 479d9e9 + 125d942 commit 8660028

File tree

2,409 files changed

+96961
-25429
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

2,409 files changed

+96961
-25429
lines changed

.eslintrc.js

Lines changed: 0 additions & 21 deletions
This file was deleted.

.github/workflows/lint.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,6 @@ jobs:
88
- uses: actions/checkout@v1
99
- uses: actions/setup-node@v1
1010
with:
11-
node-version: '14.x'
11+
node-version: '18.x'
1212
- run: npm install
1313
- run: npm run lint

.github/workflows/test.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,6 @@ jobs:
88
- uses: actions/checkout@v1
99
- uses: actions/setup-node@v1
1010
with:
11-
node-version: '14.x'
11+
node-version: '18.x'
1212
- run: npm install
1313
- run: npm run test

CHANGELOG.md

Lines changed: 150 additions & 2 deletions
Large diffs are not rendered by default.

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -427,8 +427,8 @@ console.log(response);
427427

428428
## Reserved words
429429

430-
The SDK has reserved words(e.g. `from`, `in`). [Full list of reserved words.](https://openapi-generator.tech/docs/generators/typescript#reserved-words)
431-
When you face with a reserved word you have to add `_` before the word(e.g. `_from`, `_in`).
430+
The SDK has reserved words(e.g. `from`, `in`, `delete`). [Full list of reserved words.](https://openapi-generator.tech/docs/generators/typescript#reserved-words)
431+
When you face with a reserved word you have to add `_` before the word(e.g. `_from`, `_in`, `_delete`).
432432

433433
```javascript
434434
const BatchInputPublicAssociation = {

codegen/automation/actions/apis/CallbacksApi.ts

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,9 @@ import { CallbackCompletionRequest } from '../models/CallbackCompletionRequest';
1717
export class CallbacksApiRequestFactory extends BaseAPIRequestFactory {
1818

1919
/**
20-
* Completes a single callback
21-
* @param callbackId
20+
* Complete a specific blocked action execution by ID.
21+
* Completes a callback
22+
* @param callbackId The ID of the action execution.
2223
* @param callbackCompletionRequest
2324
*/
2425
public async complete(callbackId: string, callbackCompletionRequest: CallbackCompletionRequest, _options?: Configuration): Promise<RequestContext> {
@@ -63,7 +64,7 @@ export class CallbacksApiRequestFactory extends BaseAPIRequestFactory {
6364
await authMethod?.applySecurityAuthentication(requestContext);
6465
}
6566

66-
const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default
67+
const defaultAuth: SecurityAuthentication | undefined = _config?.authMethods?.default
6768
if (defaultAuth?.applySecurityAuthentication) {
6869
await defaultAuth?.applySecurityAuthentication(requestContext);
6970
}
@@ -72,7 +73,8 @@ export class CallbacksApiRequestFactory extends BaseAPIRequestFactory {
7273
}
7374

7475
/**
75-
* Completes a batch of callbacks
76+
* Complete a batch of blocked action executions.
77+
* Complete a batch of callbacks
7678
* @param batchInputCallbackCompletionBatchRequest
7779
*/
7880
public async completeBatch(batchInputCallbackCompletionBatchRequest: BatchInputCallbackCompletionBatchRequest, _options?: Configuration): Promise<RequestContext> {
@@ -110,7 +112,7 @@ export class CallbacksApiRequestFactory extends BaseAPIRequestFactory {
110112
await authMethod?.applySecurityAuthentication(requestContext);
111113
}
112114

113-
const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default
115+
const defaultAuth: SecurityAuthentication | undefined = _config?.authMethods?.default
114116
if (defaultAuth?.applySecurityAuthentication) {
115117
await defaultAuth?.applySecurityAuthentication(requestContext);
116118
}

codegen/automation/actions/apis/DefinitionsApi.ts

Lines changed: 23 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -19,9 +19,10 @@ import { PublicActionDefinitionPatch } from '../models/PublicActionDefinitionPat
1919
export class DefinitionsApiRequestFactory extends BaseAPIRequestFactory {
2020

2121
/**
22-
* Archive an extension definition
23-
* @param definitionId
24-
* @param appId
22+
* Delete an action definition by ID.
23+
* Delete an action definition
24+
* @param definitionId The ID of the custom action definition.
25+
* @param appId The ID of the app.
2526
*/
2627
public async archive(definitionId: string, appId: number, _options?: Configuration): Promise<RequestContext> {
2728
let _config = _options || this.configuration;
@@ -55,7 +56,7 @@ export class DefinitionsApiRequestFactory extends BaseAPIRequestFactory {
5556
await authMethod?.applySecurityAuthentication(requestContext);
5657
}
5758

58-
const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default
59+
const defaultAuth: SecurityAuthentication | undefined = _config?.authMethods?.default
5960
if (defaultAuth?.applySecurityAuthentication) {
6061
await defaultAuth?.applySecurityAuthentication(requestContext);
6162
}
@@ -64,8 +65,9 @@ export class DefinitionsApiRequestFactory extends BaseAPIRequestFactory {
6465
}
6566

6667
/**
67-
* Create a new extension definition
68-
* @param appId
68+
* Create a new custom workflow action.
69+
* Create a new custom action definition
70+
* @param appId The ID of the app.
6971
* @param publicActionDefinitionEgg
7072
*/
7173
public async create(appId: number, publicActionDefinitionEgg: PublicActionDefinitionEgg, _options?: Configuration): Promise<RequestContext> {
@@ -110,7 +112,7 @@ export class DefinitionsApiRequestFactory extends BaseAPIRequestFactory {
110112
await authMethod?.applySecurityAuthentication(requestContext);
111113
}
112114

113-
const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default
115+
const defaultAuth: SecurityAuthentication | undefined = _config?.authMethods?.default
114116
if (defaultAuth?.applySecurityAuthentication) {
115117
await defaultAuth?.applySecurityAuthentication(requestContext);
116118
}
@@ -119,9 +121,10 @@ export class DefinitionsApiRequestFactory extends BaseAPIRequestFactory {
119121
}
120122

121123
/**
122-
* Get extension definition by Id
123-
* @param definitionId
124-
* @param appId
124+
* Retrieve a custom workflow action definition by ID.
125+
* Retrieve a custom action definition
126+
* @param definitionId The ID of the custom action.
127+
* @param appId The ID of the app.
125128
* @param archived Whether to return only results that have been archived.
126129
*/
127130
public async getById(definitionId: string, appId: number, archived?: boolean, _options?: Configuration): Promise<RequestContext> {
@@ -162,7 +165,7 @@ export class DefinitionsApiRequestFactory extends BaseAPIRequestFactory {
162165
await authMethod?.applySecurityAuthentication(requestContext);
163166
}
164167

165-
const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default
168+
const defaultAuth: SecurityAuthentication | undefined = _config?.authMethods?.default
166169
if (defaultAuth?.applySecurityAuthentication) {
167170
await defaultAuth?.applySecurityAuthentication(requestContext);
168171
}
@@ -171,8 +174,9 @@ export class DefinitionsApiRequestFactory extends BaseAPIRequestFactory {
171174
}
172175

173176
/**
174-
* Get paged extension definitions
175-
* @param appId
177+
* Retrieve custom workflow action definitions by app ID.
178+
* Retrieve custom action definitions
179+
* @param appId The ID of the app.
176180
* @param limit The maximum number of results to display per page.
177181
* @param after The paging cursor token of the last successfully read resource will be returned as the &#x60;paging.next.after&#x60; JSON property of a paged response containing more results.
178182
* @param archived Whether to return only results that have been archived.
@@ -220,7 +224,7 @@ export class DefinitionsApiRequestFactory extends BaseAPIRequestFactory {
220224
await authMethod?.applySecurityAuthentication(requestContext);
221225
}
222226

223-
const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default
227+
const defaultAuth: SecurityAuthentication | undefined = _config?.authMethods?.default
224228
if (defaultAuth?.applySecurityAuthentication) {
225229
await defaultAuth?.applySecurityAuthentication(requestContext);
226230
}
@@ -229,9 +233,10 @@ export class DefinitionsApiRequestFactory extends BaseAPIRequestFactory {
229233
}
230234

231235
/**
232-
* Patch an existing extension definition
233-
* @param definitionId
234-
* @param appId
236+
* Update an existing action definition by ID.
237+
* Update an existing action definition
238+
* @param definitionId The ID of the custom action definition.
239+
* @param appId The ID of the app.
235240
* @param publicActionDefinitionPatch
236241
*/
237242
public async update(definitionId: string, appId: number, publicActionDefinitionPatch: PublicActionDefinitionPatch, _options?: Configuration): Promise<RequestContext> {
@@ -283,7 +288,7 @@ export class DefinitionsApiRequestFactory extends BaseAPIRequestFactory {
283288
await authMethod?.applySecurityAuthentication(requestContext);
284289
}
285290

286-
const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default
291+
const defaultAuth: SecurityAuthentication | undefined = _config?.authMethods?.default
287292
if (defaultAuth?.applySecurityAuthentication) {
288293
await defaultAuth?.applySecurityAuthentication(requestContext);
289294
}

codegen/automation/actions/apis/FunctionsApi.ts

Lines changed: 35 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ export class FunctionsApiRequestFactory extends BaseAPIRequestFactory {
7070
await authMethod?.applySecurityAuthentication(requestContext);
7171
}
7272

73-
const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default
73+
const defaultAuth: SecurityAuthentication | undefined = _config?.authMethods?.default
7474
if (defaultAuth?.applySecurityAuthentication) {
7575
await defaultAuth?.applySecurityAuthentication(requestContext);
7676
}
@@ -79,10 +79,11 @@ export class FunctionsApiRequestFactory extends BaseAPIRequestFactory {
7979
}
8080

8181
/**
82+
* Delete a function within a given definition.
8283
* Delete a function for a definition
83-
* @param definitionId
84-
* @param functionType
85-
* @param appId
84+
* @param definitionId The ID of the definition.
85+
* @param functionType The type of function. Can be &#x60;PRE_ACTION_EXECUTION&#x60;, &#x60;PRE_FETCH_OPTIONS&#x60;, &#x60;POST_FETCH_OPTIONS&#x60;, &#x60;POST_ACTION_EXECUTION&#x60;.
86+
* @param appId The ID of the app.
8687
*/
8788
public async archiveByFunctionType(definitionId: string, functionType: 'PRE_ACTION_EXECUTION' | 'PRE_FETCH_OPTIONS' | 'POST_FETCH_OPTIONS' | 'POST_ACTION_EXECUTION', appId: number, _options?: Configuration): Promise<RequestContext> {
8889
let _config = _options || this.configuration;
@@ -123,7 +124,7 @@ export class FunctionsApiRequestFactory extends BaseAPIRequestFactory {
123124
await authMethod?.applySecurityAuthentication(requestContext);
124125
}
125126

126-
const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default
127+
const defaultAuth: SecurityAuthentication | undefined = _config?.authMethods?.default
127128
if (defaultAuth?.applySecurityAuthentication) {
128129
await defaultAuth?.applySecurityAuthentication(requestContext);
129130
}
@@ -132,11 +133,12 @@ export class FunctionsApiRequestFactory extends BaseAPIRequestFactory {
132133
}
133134

134135
/**
135-
* Insert a function for a definition
136-
* @param definitionId
137-
* @param functionType
138-
* @param functionId
139-
* @param appId
136+
* Update a function for a given definition by ID.
137+
* Update a function for a definition
138+
* @param definitionId The ID of the definition.
139+
* @param functionType The type of function. Can be &#x60;PRE_ACTION_EXECUTION&#x60;, &#x60;PRE_FETCH_OPTIONS&#x60;, &#x60;POST_FETCH_OPTIONS&#x60;, &#x60;POST_ACTION_EXECUTION&#x60;.
140+
* @param functionId The ID of the function.
141+
* @param appId The ID of the app.
140142
* @param body
141143
*/
142144
public async createOrReplace(definitionId: string, functionType: 'PRE_ACTION_EXECUTION' | 'PRE_FETCH_OPTIONS' | 'POST_FETCH_OPTIONS' | 'POST_ACTION_EXECUTION', functionId: string, appId: number, body: string, _options?: Configuration): Promise<RequestContext> {
@@ -202,7 +204,7 @@ export class FunctionsApiRequestFactory extends BaseAPIRequestFactory {
202204
await authMethod?.applySecurityAuthentication(requestContext);
203205
}
204206

205-
const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default
207+
const defaultAuth: SecurityAuthentication | undefined = _config?.authMethods?.default
206208
if (defaultAuth?.applySecurityAuthentication) {
207209
await defaultAuth?.applySecurityAuthentication(requestContext);
208210
}
@@ -211,10 +213,11 @@ export class FunctionsApiRequestFactory extends BaseAPIRequestFactory {
211213
}
212214

213215
/**
216+
* Add a function for a given definition.
214217
* Insert a function for a definition
215-
* @param definitionId
216-
* @param functionType
217-
* @param appId
218+
* @param definitionId The ID of the definition.
219+
* @param functionType The type of function. Can be &#x60;PRE_ACTION_EXECUTION&#x60;, &#x60;PRE_FETCH_OPTIONS&#x60;, &#x60;POST_FETCH_OPTIONS&#x60;, &#x60;POST_ACTION_EXECUTION&#x60;.
220+
* @param appId The ID of the app.
218221
* @param body
219222
*/
220223
public async createOrReplaceByFunctionType(definitionId: string, functionType: 'PRE_ACTION_EXECUTION' | 'PRE_FETCH_OPTIONS' | 'POST_FETCH_OPTIONS' | 'POST_ACTION_EXECUTION', appId: number, body: string, _options?: Configuration): Promise<RequestContext> {
@@ -273,7 +276,7 @@ export class FunctionsApiRequestFactory extends BaseAPIRequestFactory {
273276
await authMethod?.applySecurityAuthentication(requestContext);
274277
}
275278

276-
const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default
279+
const defaultAuth: SecurityAuthentication | undefined = _config?.authMethods?.default
277280
if (defaultAuth?.applySecurityAuthentication) {
278281
await defaultAuth?.applySecurityAuthentication(requestContext);
279282
}
@@ -282,10 +285,10 @@ export class FunctionsApiRequestFactory extends BaseAPIRequestFactory {
282285
}
283286

284287
/**
285-
* Get all functions by a type for a given definition
286-
* @param definitionId
287-
* @param functionType
288-
* @param appId
288+
* Retrieve functions by a type for a given definition
289+
* @param definitionId The ID of the definition.
290+
* @param functionType The type of function. Can be &#x60;PRE_ACTION_EXECUTION&#x60;, &#x60;PRE_FETCH_OPTIONS&#x60;, &#x60;POST_FETCH_OPTIONS&#x60;, &#x60;POST_ACTION_EXECUTION&#x60;.
291+
* @param appId The ID of the app.
289292
*/
290293
public async getByFunctionType(definitionId: string, functionType: 'PRE_ACTION_EXECUTION' | 'PRE_FETCH_OPTIONS' | 'POST_FETCH_OPTIONS' | 'POST_ACTION_EXECUTION', appId: number, _options?: Configuration): Promise<RequestContext> {
291294
let _config = _options || this.configuration;
@@ -326,7 +329,7 @@ export class FunctionsApiRequestFactory extends BaseAPIRequestFactory {
326329
await authMethod?.applySecurityAuthentication(requestContext);
327330
}
328331

329-
const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default
332+
const defaultAuth: SecurityAuthentication | undefined = _config?.authMethods?.default
330333
if (defaultAuth?.applySecurityAuthentication) {
331334
await defaultAuth?.applySecurityAuthentication(requestContext);
332335
}
@@ -335,11 +338,12 @@ export class FunctionsApiRequestFactory extends BaseAPIRequestFactory {
335338
}
336339

337340
/**
338-
* Get a function for a given definition
339-
* @param definitionId
340-
* @param functionType
341-
* @param functionId
342-
* @param appId
341+
* Retrieve a specific function from a given definition.
342+
* Retrieve a function from a given definition
343+
* @param definitionId The ID of the definition.
344+
* @param functionType The type of function. Can be &#x60;PRE_ACTION_EXECUTION&#x60;, &#x60;PRE_FETCH_OPTIONS&#x60;, &#x60;POST_FETCH_OPTIONS&#x60;, &#x60;POST_ACTION_EXECUTION&#x60;.
345+
* @param functionId The ID of the function.
346+
* @param appId The ID of the app.
343347
*/
344348
public async getById(definitionId: string, functionType: 'PRE_ACTION_EXECUTION' | 'PRE_FETCH_OPTIONS' | 'POST_FETCH_OPTIONS' | 'POST_ACTION_EXECUTION', functionId: string, appId: number, _options?: Configuration): Promise<RequestContext> {
345349
let _config = _options || this.configuration;
@@ -387,7 +391,7 @@ export class FunctionsApiRequestFactory extends BaseAPIRequestFactory {
387391
await authMethod?.applySecurityAuthentication(requestContext);
388392
}
389393

390-
const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default
394+
const defaultAuth: SecurityAuthentication | undefined = _config?.authMethods?.default
391395
if (defaultAuth?.applySecurityAuthentication) {
392396
await defaultAuth?.applySecurityAuthentication(requestContext);
393397
}
@@ -396,9 +400,10 @@ export class FunctionsApiRequestFactory extends BaseAPIRequestFactory {
396400
}
397401

398402
/**
399-
* Get all functions for a given definition
400-
* @param definitionId
401-
* @param appId
403+
* Retrieve all functions included in a definition.
404+
* Retrieve functions for a given definition
405+
* @param definitionId The ID of the definition.
406+
* @param appId The ID of the app.
402407
*/
403408
public async getPage(definitionId: string, appId: number, _options?: Configuration): Promise<RequestContext> {
404409
let _config = _options || this.configuration;
@@ -432,7 +437,7 @@ export class FunctionsApiRequestFactory extends BaseAPIRequestFactory {
432437
await authMethod?.applySecurityAuthentication(requestContext);
433438
}
434439

435-
const defaultAuth: SecurityAuthentication | undefined = _options?.authMethods?.default || this.configuration?.authMethods?.default
440+
const defaultAuth: SecurityAuthentication | undefined = _config?.authMethods?.default
436441
if (defaultAuth?.applySecurityAuthentication) {
437442
await defaultAuth?.applySecurityAuthentication(requestContext);
438443
}

0 commit comments

Comments
 (0)