@stackone/connect-sdk 1.33.0 → 1.35.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.
- package/dist/index.d.mts +143 -0
- package/dist/index.d.ts +143 -0
- package/dist/index.js +4170 -1
- package/dist/index.mjs +4140 -0
- package/package.json +22 -5
- package/dist/index.es.mjs +0 -1
- package/dist/types/blocks/createBlock.d.ts +0 -12
- package/dist/types/blocks/createBlockContext.d.ts +0 -11
- package/dist/types/compositeIds/inputs.d.ts +0 -2
- package/dist/types/compositeIds/outputs.d.ts +0 -2
- package/dist/types/connectors/constants.d.ts +0 -1
- package/dist/types/connectors/operations.d.ts +0 -6
- package/dist/types/connectors/parsers.d.ts +0 -3
- package/dist/types/connectors/responses.d.ts +0 -3
- package/dist/types/connectors/schemas.d.ts +0 -1457
- package/dist/types/connectors/specs/examples/testConnector.d.ts +0 -2
- package/dist/types/connectors/specs/examples/testConnectorWithoutOperations.d.ts +0 -2
- package/dist/types/errors/connectSDKErrors.d.ts +0 -20
- package/dist/types/errors/types.d.ts +0 -1
- package/dist/types/index.d.ts +0 -8
- package/dist/types/pagination/utils.d.ts +0 -2
- package/dist/types/pagination/virtualPagination.d.ts +0 -7
- package/dist/types/runners/executeStepFunctions.d.ts +0 -7
- package/dist/types/runners/runConnectorOperation.d.ts +0 -25
- package/dist/types/runners/runStepOperation.d.ts +0 -11
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
import { BlockContext } from '@stackone/core';
|
|
2
|
-
import { ErrorType } from './types';
|
|
3
|
-
export declare class ConnectSDKError extends Error {
|
|
4
|
-
readonly errorType: ErrorType;
|
|
5
|
-
readonly context: BlockContext;
|
|
6
|
-
constructor(errorType: ErrorType, context: BlockContext, message?: string);
|
|
7
|
-
toString(): string;
|
|
8
|
-
}
|
|
9
|
-
export declare class ConnectorParseError extends ConnectSDKError {
|
|
10
|
-
constructor(context: BlockContext, message?: string);
|
|
11
|
-
}
|
|
12
|
-
export declare class MissingOperationError extends ConnectSDKError {
|
|
13
|
-
constructor(context: BlockContext, message?: string);
|
|
14
|
-
}
|
|
15
|
-
export declare class InvalidOperationInputsError extends ConnectSDKError {
|
|
16
|
-
constructor(context: BlockContext, message?: string);
|
|
17
|
-
}
|
|
18
|
-
export declare class InvalidCursorError extends ConnectSDKError {
|
|
19
|
-
constructor(context: BlockContext, message?: string);
|
|
20
|
-
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export type ErrorType = 'CONNECTOR_PARSE_ERROR' | 'MISSING_OPERATION_ERROR' | 'INVALID_OPERATION_INPUTS_ERROR' | 'INVALID_CURSOR_ERROR';
|
package/dist/types/index.d.ts
DELETED
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
export { createBlock } from './blocks/createBlock';
|
|
2
|
-
export { getOperationFromUrl } from './connectors/operations';
|
|
3
|
-
export { parseOperationInputs, parseYamlConnector } from './connectors/parsers';
|
|
4
|
-
export { ConnectSDKError } from './errors/connectSDKErrors';
|
|
5
|
-
export { ErrorType } from './errors/types';
|
|
6
|
-
export { executeStepFunction } from './runners/executeStepFunctions';
|
|
7
|
-
export { runConnectorOperation } from './runners/runConnectorOperation';
|
|
8
|
-
export { runStepOperation } from './runners/runStepOperation';
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
import { type Block, StepFunctionName, type StepFunctionParams, StepFunctionsFactory } from '@stackone/core';
|
|
2
|
-
export declare const executeStepFunction: ({ block, stepFunctionName, params, buildStepFunction, }: {
|
|
3
|
-
block: Block;
|
|
4
|
-
stepFunctionName: StepFunctionName;
|
|
5
|
-
params?: StepFunctionParams;
|
|
6
|
-
buildStepFunction?: typeof StepFunctionsFactory.build;
|
|
7
|
-
}) => Promise<Block>;
|
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
import { Account, Block, Category, Connector } from '@stackone/core';
|
|
2
|
-
import { ILogger } from '@stackone/logger';
|
|
3
|
-
import { HttpMethod } from '@stackone/transport';
|
|
4
|
-
import { createBlock } from '../blocks/createBlock';
|
|
5
|
-
import { createBlockContext } from '../blocks/createBlockContext';
|
|
6
|
-
import { getOperationFromUrl } from '../connectors/operations';
|
|
7
|
-
import { parseOperationInputs, parseYamlConnector } from '../connectors/parsers';
|
|
8
|
-
import { runStepOperation } from './runStepOperation';
|
|
9
|
-
export declare const runConnectorOperation: ({ account, connector, category, path, method, queryParams, body, headers, logger, parseConnector, getOperationFromUrlFn, parseOperationInputsFn, createBlockContextFn, createBlockFn, runStepOperationFn, }: {
|
|
10
|
-
account: Account;
|
|
11
|
-
connector: Connector | string;
|
|
12
|
-
category: Category;
|
|
13
|
-
path: string;
|
|
14
|
-
method?: HttpMethod;
|
|
15
|
-
queryParams: unknown;
|
|
16
|
-
body?: unknown;
|
|
17
|
-
headers?: Record<string, string>;
|
|
18
|
-
logger?: ILogger;
|
|
19
|
-
parseConnector?: typeof parseYamlConnector;
|
|
20
|
-
getOperationFromUrlFn?: typeof getOperationFromUrl;
|
|
21
|
-
parseOperationInputsFn?: typeof parseOperationInputs;
|
|
22
|
-
createBlockContextFn?: typeof createBlockContext;
|
|
23
|
-
createBlockFn?: typeof createBlock;
|
|
24
|
-
runStepOperationFn?: typeof runStepOperation;
|
|
25
|
-
}) => Promise<Block>;
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import { Block, StepFunctionsFactory } from '@stackone/core';
|
|
2
|
-
import { decodeInputCompositeIdentifiers } from '../compositeIds/inputs';
|
|
3
|
-
import { encodeResultCompositeIdentifiers } from '../compositeIds/outputs';
|
|
4
|
-
import { virtualPaginateResult } from '../pagination/virtualPagination';
|
|
5
|
-
export declare const runStepOperation: ({ block, buildStepFunction, virtualPaginateResultFn, encodeResultCompositeIds, decodeInputCompositeIds, }: {
|
|
6
|
-
block: Block;
|
|
7
|
-
buildStepFunction?: typeof StepFunctionsFactory.build;
|
|
8
|
-
virtualPaginateResultFn?: typeof virtualPaginateResult;
|
|
9
|
-
decodeInputCompositeIds?: typeof decodeInputCompositeIdentifiers;
|
|
10
|
-
encodeResultCompositeIds?: typeof encodeResultCompositeIdentifiers;
|
|
11
|
-
}) => Promise<Block>;
|