@gorgo/medusa-integration 0.0.5 → 0.0.6

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.
@@ -4,6 +4,10 @@ export type { IntegrationDescriptor, IntegrationDescriptorInput, CategoryKind, O
4
4
  export type { FieldControl, I18nKey } from "./modules/integration/descriptor/meta";
5
5
  export { collectValidationIssues, isDescriptorComplete } from "./modules/integration/descriptor/validate";
6
6
  export type { IntegrationSectionData } from "./types";
7
+ export { resolveIntegrationOptions } from "./lib/resolve-integration-options";
8
+ export type { ResolveIntegrationOptionsInput } from "./lib/resolve-integration-options";
9
+ export { getResolvedIntegrationOptionsWorkflow, getResolvedIntegrationOptionsStep, } from "./workflows/integration";
10
+ export type { GetResolvedIntegrationOptionsWorkflowInput, GetResolvedIntegrationOptionsStepInput, } from "./workflows/integration";
7
11
  export { INTEGRATION_MODULE } from "./modules/integration";
8
12
  export { default as IntegrationModuleService } from "./modules/integration/services/integration-module";
9
13
  export type { ResolvedOptions } from "./modules/integration/services/integration-module";
@@ -3,7 +3,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
3
3
  return (mod && mod.__esModule) ? mod : { "default": mod };
4
4
  };
5
5
  Object.defineProperty(exports, "__esModule", { value: true });
6
- exports.IntegrationModuleService = exports.INTEGRATION_MODULE = exports.isDescriptorComplete = exports.collectValidationIssues = exports.AbstractIntegrationProvider = exports.z = exports.defineIntegration = void 0;
6
+ exports.IntegrationModuleService = exports.INTEGRATION_MODULE = exports.getResolvedIntegrationOptionsStep = exports.getResolvedIntegrationOptionsWorkflow = exports.resolveIntegrationOptions = exports.isDescriptorComplete = exports.collectValidationIssues = exports.AbstractIntegrationProvider = exports.z = exports.defineIntegration = void 0;
7
7
  // ── For integration-provider authors ─────────────────────────────────────────
8
8
  var define_1 = require("./modules/integration/descriptor/define");
9
9
  Object.defineProperty(exports, "defineIntegration", { enumerable: true, get: function () { return define_1.defineIntegration; } });
@@ -14,9 +14,15 @@ Object.defineProperty(exports, "AbstractIntegrationProvider", { enumerable: true
14
14
  var validate_1 = require("./modules/integration/descriptor/validate");
15
15
  Object.defineProperty(exports, "collectValidationIssues", { enumerable: true, get: function () { return validate_1.collectValidationIssues; } });
16
16
  Object.defineProperty(exports, "isDescriptorComplete", { enumerable: true, get: function () { return validate_1.isDescriptorComplete; } });
17
+ // Runtime options resolver — for providers reading their config from this module.
18
+ var resolve_integration_options_1 = require("./lib/resolve-integration-options");
19
+ Object.defineProperty(exports, "resolveIntegrationOptions", { enumerable: true, get: function () { return resolve_integration_options_1.resolveIntegrationOptions; } });
20
+ var integration_1 = require("./workflows/integration");
21
+ Object.defineProperty(exports, "getResolvedIntegrationOptionsWorkflow", { enumerable: true, get: function () { return integration_1.getResolvedIntegrationOptionsWorkflow; } });
22
+ Object.defineProperty(exports, "getResolvedIntegrationOptionsStep", { enumerable: true, get: function () { return integration_1.getResolvedIntegrationOptionsStep; } });
17
23
  // ── For consumers of the integration module ──────────────────────────────────
18
- var integration_1 = require("./modules/integration");
19
- Object.defineProperty(exports, "INTEGRATION_MODULE", { enumerable: true, get: function () { return integration_1.INTEGRATION_MODULE; } });
24
+ var integration_2 = require("./modules/integration");
25
+ Object.defineProperty(exports, "INTEGRATION_MODULE", { enumerable: true, get: function () { return integration_2.INTEGRATION_MODULE; } });
20
26
  var integration_module_1 = require("./modules/integration/services/integration-module");
21
27
  Object.defineProperty(exports, "IntegrationModuleService", { enumerable: true, get: function () { return __importDefault(integration_module_1).default; } });
22
- //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW5kZXguanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi9zcmMvaW5kZXgudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6Ijs7Ozs7O0FBQUEsZ0ZBQWdGO0FBQ2hGLGtFQUE4RTtBQUFyRSwyR0FBQSxpQkFBaUIsT0FBQTtBQUFFLDJGQUFBLENBQUMsT0FBQTtBQUM3QiwyR0FBdUc7QUFBOUYsNElBQUEsMkJBQTJCLE9BQUE7QUFZcEMsZ0ZBQWdGO0FBQ2hGLHNFQUF5RztBQUFoRyxtSEFBQSx1QkFBdUIsT0FBQTtBQUFFLGdIQUFBLG9CQUFvQixPQUFBO0FBSXRELGdGQUFnRjtBQUNoRixxREFBMEQ7QUFBakQsaUhBQUEsa0JBQWtCLE9BQUE7QUFDM0Isd0ZBQXVHO0FBQTlGLCtJQUFBLE9BQU8sT0FBNEIifQ==
28
+ //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW5kZXguanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi9zcmMvaW5kZXgudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6Ijs7Ozs7O0FBQUEsZ0ZBQWdGO0FBQ2hGLGtFQUE4RTtBQUFyRSwyR0FBQSxpQkFBaUIsT0FBQTtBQUFFLDJGQUFBLENBQUMsT0FBQTtBQUM3QiwyR0FBdUc7QUFBOUYsNElBQUEsMkJBQTJCLE9BQUE7QUFZcEMsZ0ZBQWdGO0FBQ2hGLHNFQUF5RztBQUFoRyxtSEFBQSx1QkFBdUIsT0FBQTtBQUFFLGdIQUFBLG9CQUFvQixPQUFBO0FBSXRELGtGQUFrRjtBQUNsRixpRkFBNkU7QUFBcEUsd0lBQUEseUJBQXlCLE9BQUE7QUFFbEMsdURBR2dDO0FBRjlCLG9JQUFBLHFDQUFxQyxPQUFBO0FBQ3JDLGdJQUFBLGlDQUFpQyxPQUFBO0FBT25DLGdGQUFnRjtBQUNoRixxREFBMEQ7QUFBakQsaUhBQUEsa0JBQWtCLE9BQUE7QUFDM0Isd0ZBQXVHO0FBQTlGLCtJQUFBLE9BQU8sT0FBNEIifQ==
@@ -0,0 +1,29 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ const utils_1 = require("@medusajs/framework/utils");
4
+ const resolve_integration_options_1 = require("../resolve-integration-options");
5
+ const resolved = {
6
+ options: { terminalKey: "tk", password: "pw" },
7
+ meta: { provider_id: "int_tkassa", category: "payment", is_enabled: true },
8
+ };
9
+ describe("unwrapResolvedOptions", () => {
10
+ it("returns the resolved options when present", () => {
11
+ const out = (0, resolve_integration_options_1.unwrapResolvedOptions)(resolved, "tkassa");
12
+ expect(out).toEqual({ terminalKey: "tk", password: "pw" });
13
+ });
14
+ it("throws a NOT_ALLOWED MedusaError naming the identifier when not configured", () => {
15
+ expect(() => (0, resolve_integration_options_1.unwrapResolvedOptions)(null, "tkassa")).toThrow(utils_1.MedusaError);
16
+ try {
17
+ (0, resolve_integration_options_1.unwrapResolvedOptions)(null, "tkassa");
18
+ throw new Error("expected to throw");
19
+ }
20
+ catch (e) {
21
+ expect(e.type).toBe(utils_1.MedusaError.Types.NOT_ALLOWED);
22
+ expect(e.message).toContain('"tkassa"');
23
+ }
24
+ });
25
+ it("returns null when not configured and optional is true", () => {
26
+ expect((0, resolve_integration_options_1.unwrapResolvedOptions)(null, "tkassa", true)).toBeNull();
27
+ });
28
+ });
29
+ //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicmVzb2x2ZS1pbnRlZ3JhdGlvbi1vcHRpb25zLnVuaXQuc3BlYy5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uLy4uL3NyYy9saWIvX190ZXN0c19fL3Jlc29sdmUtaW50ZWdyYXRpb24tb3B0aW9ucy51bml0LnNwZWMudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6Ijs7QUFBQSxxREFBdUQ7QUFDdkQsZ0ZBQXNFO0FBR3RFLE1BQU0sUUFBUSxHQUFvQjtJQUNoQyxPQUFPLEVBQUUsRUFBRSxXQUFXLEVBQUUsSUFBSSxFQUFFLFFBQVEsRUFBRSxJQUFJLEVBQUU7SUFDOUMsSUFBSSxFQUFFLEVBQUUsV0FBVyxFQUFFLFlBQVksRUFBRSxRQUFRLEVBQUUsU0FBUyxFQUFFLFVBQVUsRUFBRSxJQUFJLEVBQUU7Q0FDM0UsQ0FBQTtBQUVELFFBQVEsQ0FBQyx1QkFBdUIsRUFBRSxHQUFHLEVBQUU7SUFDckMsRUFBRSxDQUFDLDJDQUEyQyxFQUFFLEdBQUcsRUFBRTtRQUNuRCxNQUFNLEdBQUcsR0FBRyxJQUFBLG1EQUFxQixFQUE0QyxRQUFRLEVBQUUsUUFBUSxDQUFDLENBQUE7UUFDaEcsTUFBTSxDQUFDLEdBQUcsQ0FBQyxDQUFDLE9BQU8sQ0FBQyxFQUFFLFdBQVcsRUFBRSxJQUFJLEVBQUUsUUFBUSxFQUFFLElBQUksRUFBRSxDQUFDLENBQUE7SUFDNUQsQ0FBQyxDQUFDLENBQUE7SUFFRixFQUFFLENBQUMsNEVBQTRFLEVBQUUsR0FBRyxFQUFFO1FBQ3BGLE1BQU0sQ0FBQyxHQUFHLEVBQUUsQ0FBQyxJQUFBLG1EQUFxQixFQUFDLElBQUksRUFBRSxRQUFRLENBQUMsQ0FBQyxDQUFDLE9BQU8sQ0FBQyxtQkFBVyxDQUFDLENBQUE7UUFDeEUsSUFBSSxDQUFDO1lBQ0gsSUFBQSxtREFBcUIsRUFBQyxJQUFJLEVBQUUsUUFBUSxDQUFDLENBQUE7WUFDckMsTUFBTSxJQUFJLEtBQUssQ0FBQyxtQkFBbUIsQ0FBQyxDQUFBO1FBQ3RDLENBQUM7UUFBQyxPQUFPLENBQU0sRUFBRSxDQUFDO1lBQ2hCLE1BQU0sQ0FBQyxDQUFDLENBQUMsSUFBSSxDQUFDLENBQUMsSUFBSSxDQUFDLG1CQUFXLENBQUMsS0FBSyxDQUFDLFdBQVcsQ0FBQyxDQUFBO1lBQ2xELE1BQU0sQ0FBQyxDQUFDLENBQUMsT0FBTyxDQUFDLENBQUMsU0FBUyxDQUFDLFVBQVUsQ0FBQyxDQUFBO1FBQ3pDLENBQUM7SUFDSCxDQUFDLENBQUMsQ0FBQTtJQUVGLEVBQUUsQ0FBQyx1REFBdUQsRUFBRSxHQUFHLEVBQUU7UUFDL0QsTUFBTSxDQUFDLElBQUEsbURBQXFCLEVBQUMsSUFBSSxFQUFFLFFBQVEsRUFBRSxJQUFJLENBQUMsQ0FBQyxDQUFDLFFBQVEsRUFBRSxDQUFBO0lBQ2hFLENBQUMsQ0FBQyxDQUFBO0FBQ0osQ0FBQyxDQUFDLENBQUEifQ==
@@ -0,0 +1,23 @@
1
+ import type { ResolvedOptions } from "../modules/integration/services/integration-module";
2
+ export type ResolveIntegrationOptionsInput = {
3
+ identifier: string;
4
+ instance_id?: string | null;
5
+ };
6
+ /**
7
+ * Apply the not-configured policy to a resolved-options result. Pure — the unit-tested core.
8
+ * `resolved === null` means the integration is not configured / disabled / incomplete.
9
+ */
10
+ export declare function unwrapResolvedOptions<T = Record<string, unknown>>(resolved: ResolvedOptions | null, identifier: string, optional?: boolean): T | null;
11
+ /**
12
+ * Resolve an integration provider's decrypted options at runtime. Intended for payment/
13
+ * fulfillment/etc. providers that live in their own (isolated) module container and can't
14
+ * resolve the integration module directly — this runs the resolver workflow in the global
15
+ * app container. Throws MedusaError(NOT_ALLOWED) when not configured, unless `{ optional: true }`.
16
+ */
17
+ export declare function resolveIntegrationOptions<T = Record<string, unknown>>(input: ResolveIntegrationOptionsInput): Promise<T>;
18
+ export declare function resolveIntegrationOptions<T = Record<string, unknown>>(input: ResolveIntegrationOptionsInput, config: {
19
+ optional?: false;
20
+ }): Promise<T>;
21
+ export declare function resolveIntegrationOptions<T = Record<string, unknown>>(input: ResolveIntegrationOptionsInput, config: {
22
+ optional: true;
23
+ }): Promise<T | null>;
@@ -0,0 +1,23 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.unwrapResolvedOptions = unwrapResolvedOptions;
4
+ exports.resolveIntegrationOptions = resolveIntegrationOptions;
5
+ const utils_1 = require("@medusajs/framework/utils");
6
+ const integration_1 = require("../workflows/integration");
7
+ /**
8
+ * Apply the not-configured policy to a resolved-options result. Pure — the unit-tested core.
9
+ * `resolved === null` means the integration is not configured / disabled / incomplete.
10
+ */
11
+ function unwrapResolvedOptions(resolved, identifier, optional) {
12
+ if (!resolved) {
13
+ if (optional)
14
+ return null;
15
+ throw new utils_1.MedusaError(utils_1.MedusaError.Types.NOT_ALLOWED, `Integration provider "${identifier}" is not available: it is either not configured, disabled, or missing required options. Configure and enable it before use.`);
16
+ }
17
+ return resolved.options;
18
+ }
19
+ async function resolveIntegrationOptions(input, config) {
20
+ const { result } = await (0, integration_1.getResolvedIntegrationOptionsWorkflow)().run({ input });
21
+ return unwrapResolvedOptions(result, input.identifier, config?.optional);
22
+ }
23
+ //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicmVzb2x2ZS1pbnRlZ3JhdGlvbi1vcHRpb25zLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vLi4vLi4vc3JjL2xpYi9yZXNvbHZlLWludGVncmF0aW9uLW9wdGlvbnMudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6Ijs7QUFhQSxzREFhQztBQW1CRCw4REFNQztBQW5ERCxxREFBdUQ7QUFDdkQsMERBQWdGO0FBUWhGOzs7R0FHRztBQUNILFNBQWdCLHFCQUFxQixDQUNuQyxRQUFnQyxFQUNoQyxVQUFrQixFQUNsQixRQUFrQjtJQUVsQixJQUFJLENBQUMsUUFBUSxFQUFFLENBQUM7UUFDZCxJQUFJLFFBQVE7WUFBRSxPQUFPLElBQUksQ0FBQTtRQUN6QixNQUFNLElBQUksbUJBQVcsQ0FDbkIsbUJBQVcsQ0FBQyxLQUFLLENBQUMsV0FBVyxFQUM3Qix5QkFBeUIsVUFBVSw2SEFBNkgsQ0FDakssQ0FBQTtJQUNILENBQUM7SUFDRCxPQUFPLFFBQVEsQ0FBQyxPQUFZLENBQUE7QUFDOUIsQ0FBQztBQW1CTSxLQUFLLFVBQVUseUJBQXlCLENBQzdDLEtBQXFDLEVBQ3JDLE1BQStCO0lBRS9CLE1BQU0sRUFBRSxNQUFNLEVBQUUsR0FBRyxNQUFNLElBQUEsbURBQXFDLEdBQUUsQ0FBQyxHQUFHLENBQUMsRUFBRSxLQUFLLEVBQUUsQ0FBQyxDQUFBO0lBQy9FLE9BQU8scUJBQXFCLENBQUksTUFBTSxFQUFFLEtBQUssQ0FBQyxVQUFVLEVBQUUsTUFBTSxFQUFFLFFBQVEsQ0FBQyxDQUFBO0FBQzdFLENBQUMifQ==
@@ -0,0 +1,6 @@
1
+ export type GetResolvedIntegrationOptionsStepInput = {
2
+ identifier: string;
3
+ instance_id?: string | null;
4
+ };
5
+ export declare const getResolvedIntegrationOptionsStepId = "get-resolved-integration-options";
6
+ export declare const getResolvedIntegrationOptionsStep: import("@medusajs/framework/workflows-sdk").StepFunction<GetResolvedIntegrationOptionsStepInput, import("../../../modules/integration/services/integration-module").ResolvedOptions | null>;
@@ -0,0 +1,12 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.getResolvedIntegrationOptionsStep = exports.getResolvedIntegrationOptionsStepId = void 0;
4
+ const workflows_sdk_1 = require("@medusajs/framework/workflows-sdk");
5
+ const integration_1 = require("../../../modules/integration");
6
+ exports.getResolvedIntegrationOptionsStepId = "get-resolved-integration-options";
7
+ exports.getResolvedIntegrationOptionsStep = (0, workflows_sdk_1.createStep)(exports.getResolvedIntegrationOptionsStepId, async (input, { container }) => {
8
+ const service = container.resolve(integration_1.INTEGRATION_MODULE);
9
+ const resolved = await service.getResolvedOptions(input.identifier, input.instance_id);
10
+ return new workflows_sdk_1.StepResponse(resolved);
11
+ });
12
+ //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZ2V0LXJlc29sdmVkLWludGVncmF0aW9uLW9wdGlvbnMuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi8uLi9zcmMvd29ya2Zsb3dzL2ludGVncmF0aW9uL3N0ZXBzL2dldC1yZXNvbHZlZC1pbnRlZ3JhdGlvbi1vcHRpb25zLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiI7OztBQUFBLHFFQUE0RTtBQUM1RSw4REFBaUU7QUFRcEQsUUFBQSxtQ0FBbUMsR0FBRyxrQ0FBa0MsQ0FBQTtBQUV4RSxRQUFBLGlDQUFpQyxHQUFHLElBQUEsMEJBQVUsRUFDekQsMkNBQW1DLEVBQ25DLEtBQUssRUFBRSxLQUE2QyxFQUFFLEVBQUUsU0FBUyxFQUFFLEVBQUUsRUFBRTtJQUNyRSxNQUFNLE9BQU8sR0FBRyxTQUFTLENBQUMsT0FBTyxDQUFDLGdDQUFrQixDQUE2QixDQUFBO0lBQ2pGLE1BQU0sUUFBUSxHQUFHLE1BQU0sT0FBTyxDQUFDLGtCQUFrQixDQUFDLEtBQUssQ0FBQyxVQUFVLEVBQUUsS0FBSyxDQUFDLFdBQVcsQ0FBQyxDQUFBO0lBQ3RGLE9BQU8sSUFBSSw0QkFBWSxDQUFDLFFBQVEsQ0FBQyxDQUFBO0FBQ25DLENBQUMsQ0FDRixDQUFBIn0=
@@ -4,3 +4,5 @@ export { emitIntegrationEventStep } from "./emit-integration-event";
4
4
  export { runTestConnectionStep } from "./run-test-connection";
5
5
  export { setIntegrationEnabledStep } from "./set-integration-enabled";
6
6
  export { upsertIntegrationRecordStep } from "./upsert-integration-record";
7
+ export { getResolvedIntegrationOptionsStep, getResolvedIntegrationOptionsStepId, } from "./get-resolved-integration-options";
8
+ export type { GetResolvedIntegrationOptionsStepInput } from "./get-resolved-integration-options";
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.upsertIntegrationRecordStep = exports.setIntegrationEnabledStep = exports.runTestConnectionStep = exports.emitIntegrationEventStep = exports.deleteIntegrationRecordStep = exports.applyIntegrationSectionStep = void 0;
3
+ exports.getResolvedIntegrationOptionsStepId = exports.getResolvedIntegrationOptionsStep = exports.upsertIntegrationRecordStep = exports.setIntegrationEnabledStep = exports.runTestConnectionStep = exports.emitIntegrationEventStep = exports.deleteIntegrationRecordStep = exports.applyIntegrationSectionStep = void 0;
4
4
  var apply_integration_section_1 = require("./apply-integration-section");
5
5
  Object.defineProperty(exports, "applyIntegrationSectionStep", { enumerable: true, get: function () { return apply_integration_section_1.applyIntegrationSectionStep; } });
6
6
  var delete_integration_record_1 = require("./delete-integration-record");
@@ -13,4 +13,7 @@ var set_integration_enabled_1 = require("./set-integration-enabled");
13
13
  Object.defineProperty(exports, "setIntegrationEnabledStep", { enumerable: true, get: function () { return set_integration_enabled_1.setIntegrationEnabledStep; } });
14
14
  var upsert_integration_record_1 = require("./upsert-integration-record");
15
15
  Object.defineProperty(exports, "upsertIntegrationRecordStep", { enumerable: true, get: function () { return upsert_integration_record_1.upsertIntegrationRecordStep; } });
16
- //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW5kZXguanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi8uLi9zcmMvd29ya2Zsb3dzL2ludGVncmF0aW9uL3N0ZXBzL2luZGV4LnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiI7OztBQUFBLHlFQUF5RTtBQUFoRSx3SUFBQSwyQkFBMkIsT0FBQTtBQUNwQyx5RUFBeUU7QUFBaEUsd0lBQUEsMkJBQTJCLE9BQUE7QUFDcEMsbUVBQW1FO0FBQTFELGtJQUFBLHdCQUF3QixPQUFBO0FBQ2pDLDZEQUE2RDtBQUFwRCw0SEFBQSxxQkFBcUIsT0FBQTtBQUM5QixxRUFBcUU7QUFBNUQsb0lBQUEseUJBQXlCLE9BQUE7QUFDbEMseUVBQXlFO0FBQWhFLHdJQUFBLDJCQUEyQixPQUFBIn0=
16
+ var get_resolved_integration_options_1 = require("./get-resolved-integration-options");
17
+ Object.defineProperty(exports, "getResolvedIntegrationOptionsStep", { enumerable: true, get: function () { return get_resolved_integration_options_1.getResolvedIntegrationOptionsStep; } });
18
+ Object.defineProperty(exports, "getResolvedIntegrationOptionsStepId", { enumerable: true, get: function () { return get_resolved_integration_options_1.getResolvedIntegrationOptionsStepId; } });
19
+ //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW5kZXguanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi8uLi9zcmMvd29ya2Zsb3dzL2ludGVncmF0aW9uL3N0ZXBzL2luZGV4LnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiI7OztBQUFBLHlFQUF5RTtBQUFoRSx3SUFBQSwyQkFBMkIsT0FBQTtBQUNwQyx5RUFBeUU7QUFBaEUsd0lBQUEsMkJBQTJCLE9BQUE7QUFDcEMsbUVBQW1FO0FBQTFELGtJQUFBLHdCQUF3QixPQUFBO0FBQ2pDLDZEQUE2RDtBQUFwRCw0SEFBQSxxQkFBcUIsT0FBQTtBQUM5QixxRUFBcUU7QUFBNUQsb0lBQUEseUJBQXlCLE9BQUE7QUFDbEMseUVBQXlFO0FBQWhFLHdJQUFBLDJCQUEyQixPQUFBO0FBQ3BDLHVGQUcyQztBQUZ6QyxxSkFBQSxpQ0FBaUMsT0FBQTtBQUNqQyx1SkFBQSxtQ0FBbUMsT0FBQSJ9
@@ -0,0 +1,6 @@
1
+ export type GetResolvedIntegrationOptionsWorkflowInput = {
2
+ identifier: string;
3
+ instance_id?: string | null;
4
+ };
5
+ export declare const getResolvedIntegrationOptionsWorkflowId = "get-resolved-integration-options";
6
+ export declare const getResolvedIntegrationOptionsWorkflow: import("@medusajs/framework/workflows-sdk").ReturnWorkflow<GetResolvedIntegrationOptionsWorkflowInput, import("../../..").ResolvedOptions | null, []>;
@@ -0,0 +1,8 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.getResolvedIntegrationOptionsWorkflow = exports.getResolvedIntegrationOptionsWorkflowId = void 0;
4
+ const workflows_sdk_1 = require("@medusajs/framework/workflows-sdk");
5
+ const steps_1 = require("../steps");
6
+ exports.getResolvedIntegrationOptionsWorkflowId = "get-resolved-integration-options";
7
+ exports.getResolvedIntegrationOptionsWorkflow = (0, workflows_sdk_1.createWorkflow)(exports.getResolvedIntegrationOptionsWorkflowId, (input) => new workflows_sdk_1.WorkflowResponse((0, steps_1.getResolvedIntegrationOptionsStep)(input)));
8
+ //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZ2V0LXJlc29sdmVkLWludGVncmF0aW9uLW9wdGlvbnMuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi8uLi9zcmMvd29ya2Zsb3dzL2ludGVncmF0aW9uL3dvcmtmbG93cy9nZXQtcmVzb2x2ZWQtaW50ZWdyYXRpb24tb3B0aW9ucy50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiOzs7QUFBQSxxRUFBb0Y7QUFDcEYsb0NBQTREO0FBTy9DLFFBQUEsdUNBQXVDLEdBQUcsa0NBQWtDLENBQUE7QUFFNUUsUUFBQSxxQ0FBcUMsR0FBRyxJQUFBLDhCQUFjLEVBQ2pFLCtDQUF1QyxFQUN2QyxDQUFDLEtBQWlELEVBQUUsRUFBRSxDQUNwRCxJQUFJLGdDQUFnQixDQUFDLElBQUEseUNBQWlDLEVBQUMsS0FBSyxDQUFDLENBQUMsQ0FDakUsQ0FBQSJ9
@@ -2,3 +2,5 @@ export { upsertIntegrationWorkflow } from "./upsert-integration";
2
2
  export { deleteIntegrationWorkflow } from "./delete-integration";
3
3
  export { testIntegrationConnectionWorkflow } from "./test-integration-connection";
4
4
  export { setIntegrationEnabledWorkflow } from "./set-integration-enabled";
5
+ export { getResolvedIntegrationOptionsWorkflow } from "./get-resolved-integration-options";
6
+ export type { GetResolvedIntegrationOptionsWorkflowInput } from "./get-resolved-integration-options";
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.setIntegrationEnabledWorkflow = exports.testIntegrationConnectionWorkflow = exports.deleteIntegrationWorkflow = exports.upsertIntegrationWorkflow = void 0;
3
+ exports.getResolvedIntegrationOptionsWorkflow = exports.setIntegrationEnabledWorkflow = exports.testIntegrationConnectionWorkflow = exports.deleteIntegrationWorkflow = exports.upsertIntegrationWorkflow = void 0;
4
4
  var upsert_integration_1 = require("./upsert-integration");
5
5
  Object.defineProperty(exports, "upsertIntegrationWorkflow", { enumerable: true, get: function () { return upsert_integration_1.upsertIntegrationWorkflow; } });
6
6
  var delete_integration_1 = require("./delete-integration");
@@ -9,4 +9,6 @@ var test_integration_connection_1 = require("./test-integration-connection");
9
9
  Object.defineProperty(exports, "testIntegrationConnectionWorkflow", { enumerable: true, get: function () { return test_integration_connection_1.testIntegrationConnectionWorkflow; } });
10
10
  var set_integration_enabled_1 = require("./set-integration-enabled");
11
11
  Object.defineProperty(exports, "setIntegrationEnabledWorkflow", { enumerable: true, get: function () { return set_integration_enabled_1.setIntegrationEnabledWorkflow; } });
12
- //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW5kZXguanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi8uLi9zcmMvd29ya2Zsb3dzL2ludGVncmF0aW9uL3dvcmtmbG93cy9pbmRleC50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiOzs7QUFBQSwyREFBZ0U7QUFBdkQsK0hBQUEseUJBQXlCLE9BQUE7QUFDbEMsMkRBQWdFO0FBQXZELCtIQUFBLHlCQUF5QixPQUFBO0FBQ2xDLDZFQUFpRjtBQUF4RSxnSkFBQSxpQ0FBaUMsT0FBQTtBQUMxQyxxRUFBeUU7QUFBaEUsd0lBQUEsNkJBQTZCLE9BQUEifQ==
12
+ var get_resolved_integration_options_1 = require("./get-resolved-integration-options");
13
+ Object.defineProperty(exports, "getResolvedIntegrationOptionsWorkflow", { enumerable: true, get: function () { return get_resolved_integration_options_1.getResolvedIntegrationOptionsWorkflow; } });
14
+ //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW5kZXguanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi8uLi9zcmMvd29ya2Zsb3dzL2ludGVncmF0aW9uL3dvcmtmbG93cy9pbmRleC50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiOzs7QUFBQSwyREFBZ0U7QUFBdkQsK0hBQUEseUJBQXlCLE9BQUE7QUFDbEMsMkRBQWdFO0FBQXZELCtIQUFBLHlCQUF5QixPQUFBO0FBQ2xDLDZFQUFpRjtBQUF4RSxnSkFBQSxpQ0FBaUMsT0FBQTtBQUMxQyxxRUFBeUU7QUFBaEUsd0lBQUEsNkJBQTZCLE9BQUE7QUFDdEMsdUZBQTBGO0FBQWpGLHlKQUFBLHFDQUFxQyxPQUFBIn0=
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@gorgo/medusa-integration",
3
- "version": "0.0.5",
3
+ "version": "0.0.6",
4
4
  "description": "Integration module for Medusa",
5
5
  "author": {
6
6
  "name": "Gorgo",