@spiffcommerce/core 25.1.4 → 26.0.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.ts +7 -49
- package/dist/index.js +2146 -2372
- package/dist/index.mjs +14648 -15162
- package/package.json +2 -2
package/dist/index.d.ts
CHANGED
|
@@ -2083,10 +2083,10 @@ declare const getWorkflow: (id: string, options?: GetWorkflowGraphqlOptions) =>
|
|
|
2083
2083
|
*/
|
|
2084
2084
|
interface ClientOptions {
|
|
2085
2085
|
/**
|
|
2086
|
-
*
|
|
2087
|
-
* authenticate with the SpiffCommerce API.
|
|
2086
|
+
* The client will use the provided application key to
|
|
2087
|
+
* authenticate with the SpiffCommerce API. This key can be generated and replaced in Spiffcommerce Hub.
|
|
2088
2088
|
*/
|
|
2089
|
-
applicationKey
|
|
2089
|
+
applicationKey: string;
|
|
2090
2090
|
}
|
|
2091
2091
|
interface GetBundleGraphqlAssetsOptions {
|
|
2092
2092
|
metadata?: boolean;
|
|
@@ -2172,8 +2172,8 @@ interface ClientConfiguration {
|
|
|
2172
2172
|
hubUrl: string;
|
|
2173
2173
|
serverUrl: string;
|
|
2174
2174
|
servicesApiUrl: string;
|
|
2175
|
-
marketplaceThemeInstallId
|
|
2176
|
-
marketplaceThemeInstallConfigurationId
|
|
2175
|
+
marketplaceThemeInstallId?: string;
|
|
2176
|
+
marketplaceThemeInstallConfigurationId?: string;
|
|
2177
2177
|
bearerAuthenticationToken?: string;
|
|
2178
2178
|
}
|
|
2179
2179
|
/**
|
|
@@ -2182,20 +2182,12 @@ interface ClientConfiguration {
|
|
|
2182
2182
|
*/
|
|
2183
2183
|
declare class SpiffCommerceClient {
|
|
2184
2184
|
private options;
|
|
2185
|
-
private initialized;
|
|
2186
2185
|
private currencyCode?;
|
|
2187
2186
|
private customer?;
|
|
2188
2187
|
private activeIntegration?;
|
|
2189
2188
|
private marketplaceThemeInstallId?;
|
|
2190
2189
|
private marketplaceThemeInstallConfigurationId?;
|
|
2191
|
-
/**
|
|
2192
|
-
* @deprecated This object is passed to the WorkflowExperience constructor and is no longer needed on this object.
|
|
2193
|
-
* Any functionality referencing this object will be removed in a future release.
|
|
2194
|
-
*/
|
|
2195
|
-
private experienceOptions?;
|
|
2196
2190
|
constructor(options: ClientOptions);
|
|
2197
|
-
/** @deprecated Use `configure` instead */
|
|
2198
|
-
configureUrls(hubUrl: string, serverUrl: string, servicesApiUrl: string): void;
|
|
2199
2191
|
configure(configuration: ClientConfiguration): void;
|
|
2200
2192
|
/**
|
|
2201
2193
|
* @returns The asset manager allows for common operations related to assets
|
|
@@ -2309,13 +2301,11 @@ declare class SpiffCommerceClient {
|
|
|
2309
2301
|
getBundleStakeholders(): Promise<BundleStakeholder[]>;
|
|
2310
2302
|
/**
|
|
2311
2303
|
* Creates a new instance of WorkflowExperience. A high level wrapper for workflows.
|
|
2312
|
-
* @param workflowId The id of the workflow to be run. Deprecated: Provide options instead.
|
|
2313
|
-
* @param workflowState An existing workflow state if available. Deprecated: Provide options instead.
|
|
2314
|
-
* @param previewServiceConstructor A function called during initialization. Takes a class implementing ThreeDPreviewService in return.
|
|
2315
2304
|
* @param options Options to configure loading the transaction and workflow.
|
|
2305
|
+
* @param previewServiceConstructor A function called during initialization. Takes a class implementing ThreeDPreviewService in return.
|
|
2316
2306
|
* @returns A workflow experience configured as requested.
|
|
2317
2307
|
*/
|
|
2318
|
-
getWorkflowExperience(
|
|
2308
|
+
getWorkflowExperience(options: GetWorkflowOptions, previewServiceConstructor?: (workflow: Workflow) => ThreeDPreviewService): Promise<WorkflowExperience>;
|
|
2319
2309
|
/**
|
|
2320
2310
|
* Gets multiple workflow experiences at once.
|
|
2321
2311
|
* @param optionsArray An array of options to configure loading the transactions and workflows.
|
|
@@ -2324,38 +2314,6 @@ declare class SpiffCommerceClient {
|
|
|
2324
2314
|
* @returns An array of workflow experiences configured as requested.
|
|
2325
2315
|
*/
|
|
2326
2316
|
getWorkflowExperiences(optionsArray: GetWorkflowOptions[], graphqlOptions?: GetWorkflowGraphqlOptions): Promise<WorkflowExperience[]>;
|
|
2327
|
-
/**
|
|
2328
|
-
* Initialize the client from an integration product.
|
|
2329
|
-
* @param integrationProductId The integration product to use.
|
|
2330
|
-
* @deprecated Use getWorkflowExperience to initialize the experience.
|
|
2331
|
-
*/
|
|
2332
|
-
initFromIntegrationProduct(integrationProductId: string): Promise<void>;
|
|
2333
|
-
/**
|
|
2334
|
-
* Initialize the client from an existing transaction.
|
|
2335
|
-
* @param transactionId The id of the transaction
|
|
2336
|
-
* @returns A promise resolving at initialization completion.
|
|
2337
|
-
* @deprecated Use getWorkflowExperience to initialize the experience.
|
|
2338
|
-
*/
|
|
2339
|
-
initFromTransaction(transactionId: string, readOnly?: boolean): Promise<void>;
|
|
2340
|
-
/**
|
|
2341
|
-
* @deprecated Remove when the initFrom functions are removed.
|
|
2342
|
-
*/
|
|
2343
|
-
private getWorkflowExperienceDeprecated;
|
|
2344
|
-
/**
|
|
2345
|
-
* @deprecated The value this returns will be changed whenever `getWorkflowExperience()` is called. Use `workflowExperience.getWorkflowManager().getPreviewService()` instead.
|
|
2346
|
-
* @returns The preview service that was provided during construction.
|
|
2347
|
-
*/
|
|
2348
|
-
getPreviewService(): ThreeDPreviewService | undefined;
|
|
2349
|
-
/**
|
|
2350
|
-
* @deprecated The value this returns will be changed whenever `getWorkflowExperience()` is called. Use `WorkflowManager.getProduct()` instead.
|
|
2351
|
-
* @returns The product associated with this client.
|
|
2352
|
-
*/
|
|
2353
|
-
getProduct(): Product;
|
|
2354
|
-
/**
|
|
2355
|
-
* @deprecated The value this returns will be changed whenever `getWorkflowExperience()` is called. Use `WorkflowManager.getTransaction()` instead.
|
|
2356
|
-
* @returns The transaction associated with this client.
|
|
2357
|
-
*/
|
|
2358
|
-
getTransaction(): Transaction;
|
|
2359
2317
|
/**
|
|
2360
2318
|
* A function used to synchronize transaction state with the server.
|
|
2361
2319
|
* @param options New state details. To be spread into the query.
|