ultracart_rest_api_v2_typescript 4.1.220 → 4.1.221

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.
@@ -1165,6 +1165,8 @@ src/models/SfvbPageResponse.ts
1165
1165
  src/models/SfvbPageSelectors.ts
1166
1166
  src/models/SfvbPageSettingsRequest.ts
1167
1167
  src/models/SfvbPageSummary.ts
1168
+ src/models/SfvbPostcardProofRequest.ts
1169
+ src/models/SfvbPostcardProofResponse.ts
1168
1170
  src/models/SfvbPreviewAccessRequest.ts
1169
1171
  src/models/SfvbPreviewAccessResponse.ts
1170
1172
  src/models/SfvbPreviewSessionRequest.ts
package/README.md CHANGED
@@ -1,12 +1,12 @@
1
1
  # UltraCart Typescript SDK
2
- ## ultracart_rest_api_v2_typescript@4.1.220
2
+ ## ultracart_rest_api_v2_typescript@4.1.221
3
3
 
4
4
  Every API method call has a sample for every language SDK. See https://github.com/UltraCart/sdk_samples
5
5
 
6
6
  Installation
7
7
 
8
8
  ```
9
- npm install ultracart_rest_api_v2_typescript@4.1.220 --save
9
+ npm install ultracart_rest_api_v2_typescript@4.1.221 --save
10
10
  ```
11
11
 
12
12
  ```typescript
@@ -84,6 +84,7 @@ Not every change is committed to every SDK.
84
84
 
85
85
  | Version | Date | Comments |
86
86
  | --: | :-: | --- |
87
+ | 4.1.221 | 11/02/2026 | sfvb internal testing |
87
88
  | 4.1.220 | 11/02/2026 | sfvb internal testing |
88
89
  | 4.1.219 | 10/30/2026 | item - field for hsa/fsa eligibility |
89
90
  | 4.1.218 | 10/30/2026 | svfb internal testing |
@@ -10,7 +10,7 @@
10
10
  * Do not edit the class manually.
11
11
  */
12
12
  import * as runtime from '../runtime';
13
- import { SfvbApproval, SfvbApprovalCreateRequest, SfvbApprovalsResponse, SfvbArchiveRequest, SfvbBlogPostDetail, SfvbBlogPostImageRequest, SfvbBlogPostRequest, SfvbBlogPostsResponse, SfvbCampaign, SfvbCampaignWriteRequest, SfvbCampaignsResponse, SfvbCodeLibraryEmailsResponse, SfvbCommsListsResponse, SfvbCommsSegmentResponse, SfvbCommsSegmentWriteRequest, SfvbCommsSegmentsResponse, SfvbCommsSendingDomain, SfvbCommsSendingDomainsResponse, SfvbCommsTwilioAccount, SfvbCommsTwilioAccountResponse, SfvbCompileRequest, SfvbCompileResponse, SfvbContainerResponse, SfvbContainerRevertRequest, SfvbContainerVersion, SfvbContainerVersionsResponse, SfvbContainerWriteRequest, SfvbElementSchemaResponse, SfvbElementsResponse, SfvbEmail, SfvbEmailRenderRequest, SfvbEmailRenderResponse, SfvbEmailReviewRequest, SfvbEmailUpdateRequest, SfvbEventsAuthRequest, SfvbEventsAuthResponse, SfvbEventsResponse, SfvbExperiment, SfvbExperimentEndRequest, SfvbExperimentObjectivesResponse, SfvbExperimentStartRequest, SfvbExperimentVariationUpdateRequest, SfvbExperimentsResponse, SfvbFileContentResponse, SfvbFileRevertRequest, SfvbFileSearchRequest, SfvbFileSearchResponse, SfvbFileUploadRequest, SfvbFileUploadUrlResponse, SfvbFileVersionsResponse, SfvbFileWriteRequest, SfvbFileWriteResponse, SfvbFilesResponse, SfvbFlow, SfvbFlowStatusRequest, SfvbFlowWriteRequest, SfvbFlowsResponse, SfvbI18nGlossary, SfvbI18nGlossaryRequest, SfvbI18nLanguageEnableRequest, SfvbI18nLanguagesResponse, SfvbI18nMachineTranslationsResponse, SfvbI18nMessage, SfvbI18nMessageWriteRequest, SfvbI18nMessagesResponse, SfvbI18nResetResponse, SfvbItemAttributeBatchRequest, SfvbItemAttributeBatchResponse, SfvbItemAttributeUpdateRequest, SfvbItemContainersResponse, SfvbItemContentRequest, SfvbItemMultimediaDescriptionRequest, SfvbItemMultimediaRequest, SfvbItemPricing, SfvbItemPricingRequest, SfvbItemRelated, SfvbItemRelatedRequest, SfvbItemResponse, SfvbItemSeoRequest, SfvbLibraryDeleteResult, SfvbLibraryEntry, SfvbLibraryEntryRequest, SfvbLibraryHistoryResponse, SfvbLibraryInstallReceipt, SfvbLibraryInstallRequest, SfvbLibraryInstallsResponse, SfvbLibraryPublishRequest, SfvbLibraryResponse, SfvbLibraryScreenshotRequest, SfvbLibraryShareRequest, SfvbLibraryShareTargetsResponse, SfvbLibraryTaxonomyCatalog, SfvbLibraryUnshareResult, SfvbMenu, SfvbMenuWriteRequest, SfvbMenusResponse, SfvbNotFoundEntry, SfvbNotFoundEntryResponse, SfvbNotFoundPage, SfvbNotFoundResponse, SfvbPageAttributeUpdateRequest, SfvbPageBlogPostsRequest, SfvbPageBlogPostsResponse, SfvbPageCreateRequest, SfvbPageDuplicateRequest, SfvbPageItemsAddRequest, SfvbPageItemsRemoveRequest, SfvbPageItemsResponse, SfvbPageListResponse, SfvbPageMultimediaRequest, SfvbPageRefreshRequest, SfvbPageRefreshResponse, SfvbPageResponse, SfvbPageSelectors, SfvbPageSettingsRequest, SfvbPreviewAccessRequest, SfvbPreviewAccessResponse, SfvbPreviewSessionRequest, SfvbPreviewSessionResponse, SfvbPreviewUrlResponse, SfvbRecordingEventsResponse, SfvbRecordingResponse, SfvbRecordingSettingsRequest, SfvbRecordingSettingsResponse, SfvbRedirect, SfvbRedirectCheckResponse, SfvbRedirectDeleteRequest, SfvbRedirectDeleteResponse, SfvbRedirectImportRequest, SfvbRedirectImportResponse, SfvbRedirectRequest, SfvbRedirectResolveResponse, SfvbRedirectResponse, SfvbRedirectsResponse, SfvbRenderRequest, SfvbRenderResponse, SfvbSecretKindsResponse, SfvbSecretRequest, SfvbSecretRequestCreate, SfvbSecretRequestsResponse, SfvbSequence, SfvbSequenceStepCreateRequest, SfvbSequenceStepCreateResponse, SfvbSequenceStepDeleteResponse, SfvbSequenceStepMoveRequest, SfvbSequenceStepMoveResponse, SfvbSequenceStepUpdateRequest, SfvbSequenceStepUpdateResponse, SfvbServerLogDetail, SfvbServerLogsResponse, SfvbSiteAttributeUpdateRequest, SfvbSiteAttributesResponse, SfvbStorefrontsResponse, SfvbTemplateResolveResponse, SfvbTemplatesResponse, SfvbTestOrdersResponse, SfvbTheme, SfvbThemeAttributeUpdateRequest, SfvbThemeAttributesResponse, SfvbThemeDuplicateRequest, SfvbThemeJobResponse, SfvbThemesResponse, SfvbTransactionalEmailsResponse, SfvbUpsellOffer, SfvbUpsellOffersResponse, SfvbUpsellPath, SfvbUpsellPathDuplicateRequest, SfvbUpsellPathMoveRequest, SfvbUpsellPathsResponse, SfvbValidateRequest, SfvbValidationResponse, SfvbVelocityValidateRequest, SfvbVersionResponse, SfvbWhoamiResponse, SfvbWidgetIdsResponse } from '../models';
13
+ import { SfvbApproval, SfvbApprovalCreateRequest, SfvbApprovalsResponse, SfvbArchiveRequest, SfvbBlogPostDetail, SfvbBlogPostImageRequest, SfvbBlogPostRequest, SfvbBlogPostsResponse, SfvbCampaign, SfvbCampaignWriteRequest, SfvbCampaignsResponse, SfvbCodeLibraryEmailsResponse, SfvbCommsListsResponse, SfvbCommsSegmentResponse, SfvbCommsSegmentWriteRequest, SfvbCommsSegmentsResponse, SfvbCommsSendingDomain, SfvbCommsSendingDomainsResponse, SfvbCommsTwilioAccount, SfvbCommsTwilioAccountResponse, SfvbCompileRequest, SfvbCompileResponse, SfvbContainerResponse, SfvbContainerRevertRequest, SfvbContainerVersion, SfvbContainerVersionsResponse, SfvbContainerWriteRequest, SfvbElementSchemaResponse, SfvbElementsResponse, SfvbEmail, SfvbEmailRenderRequest, SfvbEmailRenderResponse, SfvbEmailReviewRequest, SfvbEmailUpdateRequest, SfvbEventsAuthRequest, SfvbEventsAuthResponse, SfvbEventsResponse, SfvbExperiment, SfvbExperimentEndRequest, SfvbExperimentObjectivesResponse, SfvbExperimentStartRequest, SfvbExperimentVariationUpdateRequest, SfvbExperimentsResponse, SfvbFileContentResponse, SfvbFileRevertRequest, SfvbFileSearchRequest, SfvbFileSearchResponse, SfvbFileUploadRequest, SfvbFileUploadUrlResponse, SfvbFileVersionsResponse, SfvbFileWriteRequest, SfvbFileWriteResponse, SfvbFilesResponse, SfvbFlow, SfvbFlowStatusRequest, SfvbFlowWriteRequest, SfvbFlowsResponse, SfvbI18nGlossary, SfvbI18nGlossaryRequest, SfvbI18nLanguageEnableRequest, SfvbI18nLanguagesResponse, SfvbI18nMachineTranslationsResponse, SfvbI18nMessage, SfvbI18nMessageWriteRequest, SfvbI18nMessagesResponse, SfvbI18nResetResponse, SfvbItemAttributeBatchRequest, SfvbItemAttributeBatchResponse, SfvbItemAttributeUpdateRequest, SfvbItemContainersResponse, SfvbItemContentRequest, SfvbItemMultimediaDescriptionRequest, SfvbItemMultimediaRequest, SfvbItemPricing, SfvbItemPricingRequest, SfvbItemRelated, SfvbItemRelatedRequest, SfvbItemResponse, SfvbItemSeoRequest, SfvbLibraryDeleteResult, SfvbLibraryEntry, SfvbLibraryEntryRequest, SfvbLibraryHistoryResponse, SfvbLibraryInstallReceipt, SfvbLibraryInstallRequest, SfvbLibraryInstallsResponse, SfvbLibraryPublishRequest, SfvbLibraryResponse, SfvbLibraryScreenshotRequest, SfvbLibraryShareRequest, SfvbLibraryShareTargetsResponse, SfvbLibraryTaxonomyCatalog, SfvbLibraryUnshareResult, SfvbMenu, SfvbMenuWriteRequest, SfvbMenusResponse, SfvbNotFoundEntry, SfvbNotFoundEntryResponse, SfvbNotFoundPage, SfvbNotFoundResponse, SfvbPageAttributeUpdateRequest, SfvbPageBlogPostsRequest, SfvbPageBlogPostsResponse, SfvbPageCreateRequest, SfvbPageDuplicateRequest, SfvbPageItemsAddRequest, SfvbPageItemsRemoveRequest, SfvbPageItemsResponse, SfvbPageListResponse, SfvbPageMultimediaRequest, SfvbPageRefreshRequest, SfvbPageRefreshResponse, SfvbPageResponse, SfvbPageSelectors, SfvbPageSettingsRequest, SfvbPostcardProofRequest, SfvbPostcardProofResponse, SfvbPreviewAccessRequest, SfvbPreviewAccessResponse, SfvbPreviewSessionRequest, SfvbPreviewSessionResponse, SfvbPreviewUrlResponse, SfvbRecordingEventsResponse, SfvbRecordingResponse, SfvbRecordingSettingsRequest, SfvbRecordingSettingsResponse, SfvbRedirect, SfvbRedirectCheckResponse, SfvbRedirectDeleteRequest, SfvbRedirectDeleteResponse, SfvbRedirectImportRequest, SfvbRedirectImportResponse, SfvbRedirectRequest, SfvbRedirectResolveResponse, SfvbRedirectResponse, SfvbRedirectsResponse, SfvbRenderRequest, SfvbRenderResponse, SfvbSecretKindsResponse, SfvbSecretRequest, SfvbSecretRequestCreate, SfvbSecretRequestsResponse, SfvbSequence, SfvbSequenceStepCreateRequest, SfvbSequenceStepCreateResponse, SfvbSequenceStepDeleteResponse, SfvbSequenceStepMoveRequest, SfvbSequenceStepMoveResponse, SfvbSequenceStepUpdateRequest, SfvbSequenceStepUpdateResponse, SfvbServerLogDetail, SfvbServerLogsResponse, SfvbSiteAttributeUpdateRequest, SfvbSiteAttributesResponse, SfvbStorefrontsResponse, SfvbTemplateResolveResponse, SfvbTemplatesResponse, SfvbTestOrdersResponse, SfvbTheme, SfvbThemeAttributeUpdateRequest, SfvbThemeAttributesResponse, SfvbThemeDuplicateRequest, SfvbThemeJobResponse, SfvbThemesResponse, SfvbTransactionalEmailsResponse, SfvbUpsellOffer, SfvbUpsellOffersResponse, SfvbUpsellPath, SfvbUpsellPathDuplicateRequest, SfvbUpsellPathMoveRequest, SfvbUpsellPathsResponse, SfvbValidateRequest, SfvbValidationResponse, SfvbVelocityValidateRequest, SfvbVersionResponse, SfvbWhoamiResponse, SfvbWidgetIdsResponse } from '../models';
14
14
  export interface AddSfvbPageBlogPostsRequest {
15
15
  storefrontOid: number;
16
16
  path: string;
@@ -655,6 +655,12 @@ export interface MoveSfvbUpsellPathRequest {
655
655
  upsellPathOid: number;
656
656
  moveRequest: SfvbUpsellPathMoveRequest;
657
657
  }
658
+ export interface ProofSfvbSequencePostcardRequest {
659
+ storefrontOid: number;
660
+ sequenceUuid: string;
661
+ stepUuid: string;
662
+ postcardProofRequest: SfvbPostcardProofRequest;
663
+ }
658
664
  export interface PublishSfvbLibraryEntryRequest {
659
665
  storefrontOid: number;
660
666
  libraryOid: number;
@@ -3282,6 +3288,23 @@ export interface SfvbApiInterface {
3282
3288
  * Move an upsell path
3283
3289
  */
3284
3290
  moveSfvbUpsellPath(requestParameters: MoveSfvbUpsellPathRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<SfvbUpsellPath>;
3291
+ /**
3292
+ * Renders both sides of the step\'s postcard as a send renders them, then has the print vendor render the card as a dry run. Returns the HTML of each side, the PNG image of each side that the vendor prints from, the vendor\'s thumbnails and its proof PDF. The QR code is the short link a send prints. No card is printed or mailed, nothing is billed, the step is not changed, and no coupon is created. A unique coupon code shows as PREVIEW-UNIQUE. The image urls are public. html_only returns the HTML alone, with no vendor render. An order must be a test order. cart_item_ids fills the cart a cart flow card shows. Works whether the step is on or off.
3293
+ * @summary Proof a postcard step without mailing it
3294
+ * @param {number} storefrontOid
3295
+ * @param {string} sequenceUuid
3296
+ * @param {string} stepUuid
3297
+ * @param {SfvbPostcardProofRequest} postcardProofRequest Who the card is addressed to, and the order or cart it shows
3298
+ * @param {*} [options] Override http request option.
3299
+ * @throws {RequiredError}
3300
+ * @memberof SfvbApiInterface
3301
+ */
3302
+ proofSfvbSequencePostcardRaw(requestParameters: ProofSfvbSequencePostcardRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<SfvbPostcardProofResponse>>;
3303
+ /**
3304
+ * Renders both sides of the step\'s postcard as a send renders them, then has the print vendor render the card as a dry run. Returns the HTML of each side, the PNG image of each side that the vendor prints from, the vendor\'s thumbnails and its proof PDF. The QR code is the short link a send prints. No card is printed or mailed, nothing is billed, the step is not changed, and no coupon is created. A unique coupon code shows as PREVIEW-UNIQUE. The image urls are public. html_only returns the HTML alone, with no vendor render. An order must be a test order. cart_item_ids fills the cart a cart flow card shows. Works whether the step is on or off.
3305
+ * Proof a postcard step without mailing it
3306
+ */
3307
+ proofSfvbSequencePostcard(requestParameters: ProofSfvbSequencePostcardRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<SfvbPostcardProofResponse>;
3285
3308
  /**
3286
3309
  * Freezes the draft as a published revision at its revision_number and sets who can see it. Owner only, with the draft\'s hash_sha256 as If-Match. Always needs sfvb_publish, because it changes what other merchants can install. Images, fonts, stylesheets and media must be relative paths, and credential shaped strings are refused. Public also needs the library publisher property on the account and no executable content at all - no script, html, embed, css or velocity elements. After those checks an automated AI review reads the fragment, which can take up to about a minute. A clear violation both of its models agree on refuses any publish with sfvb.library_ai_review_blocked. A public publish also needs its approval, otherwise sfvb.library_ai_review_inconclusive. The result is in content_manifest.ai_review.
3287
3310
  * @summary Publish a library entry\'s draft
@@ -5799,6 +5822,16 @@ export declare class SfvbApi extends runtime.BaseAPI implements SfvbApiInterface
5799
5822
  * Move an upsell path
5800
5823
  */
5801
5824
  moveSfvbUpsellPath(requestParameters: MoveSfvbUpsellPathRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<SfvbUpsellPath>;
5825
+ /**
5826
+ * Renders both sides of the step\'s postcard as a send renders them, then has the print vendor render the card as a dry run. Returns the HTML of each side, the PNG image of each side that the vendor prints from, the vendor\'s thumbnails and its proof PDF. The QR code is the short link a send prints. No card is printed or mailed, nothing is billed, the step is not changed, and no coupon is created. A unique coupon code shows as PREVIEW-UNIQUE. The image urls are public. html_only returns the HTML alone, with no vendor render. An order must be a test order. cart_item_ids fills the cart a cart flow card shows. Works whether the step is on or off.
5827
+ * Proof a postcard step without mailing it
5828
+ */
5829
+ proofSfvbSequencePostcardRaw(requestParameters: ProofSfvbSequencePostcardRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<SfvbPostcardProofResponse>>;
5830
+ /**
5831
+ * Renders both sides of the step\'s postcard as a send renders them, then has the print vendor render the card as a dry run. Returns the HTML of each side, the PNG image of each side that the vendor prints from, the vendor\'s thumbnails and its proof PDF. The QR code is the short link a send prints. No card is printed or mailed, nothing is billed, the step is not changed, and no coupon is created. A unique coupon code shows as PREVIEW-UNIQUE. The image urls are public. html_only returns the HTML alone, with no vendor render. An order must be a test order. cart_item_ids fills the cart a cart flow card shows. Works whether the step is on or off.
5832
+ * Proof a postcard step without mailing it
5833
+ */
5834
+ proofSfvbSequencePostcard(requestParameters: ProofSfvbSequencePostcardRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<SfvbPostcardProofResponse>;
5802
5835
  /**
5803
5836
  * Freezes the draft as a published revision at its revision_number and sets who can see it. Owner only, with the draft\'s hash_sha256 as If-Match. Always needs sfvb_publish, because it changes what other merchants can install. Images, fonts, stylesheets and media must be relative paths, and credential shaped strings are refused. Public also needs the library publisher property on the account and no executable content at all - no script, html, embed, css or velocity elements. After those checks an automated AI review reads the fragment, which can take up to about a minute. A clear violation both of its models agree on refuses any publish with sfvb.library_ai_review_blocked. A public publish also needs its approval, otherwise sfvb.library_ai_review_inconclusive. The result is in content_manifest.ai_review.
5804
5837
  * Publish a library entry\'s draft
@@ -9508,6 +9508,76 @@ var SfvbApi = /** @class */ (function (_super) {
9508
9508
  });
9509
9509
  });
9510
9510
  };
9511
+ /**
9512
+ * Renders both sides of the step\'s postcard as a send renders them, then has the print vendor render the card as a dry run. Returns the HTML of each side, the PNG image of each side that the vendor prints from, the vendor\'s thumbnails and its proof PDF. The QR code is the short link a send prints. No card is printed or mailed, nothing is billed, the step is not changed, and no coupon is created. A unique coupon code shows as PREVIEW-UNIQUE. The image urls are public. html_only returns the HTML alone, with no vendor render. An order must be a test order. cart_item_ids fills the cart a cart flow card shows. Works whether the step is on or off.
9513
+ * Proof a postcard step without mailing it
9514
+ */
9515
+ SfvbApi.prototype.proofSfvbSequencePostcardRaw = function (requestParameters, initOverrides) {
9516
+ return __awaiter(this, void 0, void 0, function () {
9517
+ var queryParameters, headerParameters, _a, _b, response;
9518
+ return __generator(this, function (_c) {
9519
+ switch (_c.label) {
9520
+ case 0:
9521
+ if (requestParameters.storefrontOid === null || requestParameters.storefrontOid === undefined) {
9522
+ throw new runtime.RequiredError('storefrontOid', 'Required parameter requestParameters.storefrontOid was null or undefined when calling proofSfvbSequencePostcard.');
9523
+ }
9524
+ if (requestParameters.sequenceUuid === null || requestParameters.sequenceUuid === undefined) {
9525
+ throw new runtime.RequiredError('sequenceUuid', 'Required parameter requestParameters.sequenceUuid was null or undefined when calling proofSfvbSequencePostcard.');
9526
+ }
9527
+ if (requestParameters.stepUuid === null || requestParameters.stepUuid === undefined) {
9528
+ throw new runtime.RequiredError('stepUuid', 'Required parameter requestParameters.stepUuid was null or undefined when calling proofSfvbSequencePostcard.');
9529
+ }
9530
+ if (requestParameters.postcardProofRequest === null || requestParameters.postcardProofRequest === undefined) {
9531
+ throw new runtime.RequiredError('postcardProofRequest', 'Required parameter requestParameters.postcardProofRequest was null or undefined when calling proofSfvbSequencePostcard.');
9532
+ }
9533
+ queryParameters = {};
9534
+ headerParameters = {};
9535
+ headerParameters['Content-Type'] = 'application/json';
9536
+ if (!(this.configuration && this.configuration.accessToken)) return [3 /*break*/, 2];
9537
+ // oauth required
9538
+ _a = headerParameters;
9539
+ _b = "Authorization";
9540
+ return [4 /*yield*/, this.configuration.accessToken("ultraCartOauth", [])];
9541
+ case 1:
9542
+ // oauth required
9543
+ _a[_b] = _c.sent();
9544
+ _c.label = 2;
9545
+ case 2:
9546
+ if (this.configuration && this.configuration.apiKey) {
9547
+ headerParameters["x-ultracart-simple-key"] = this.configuration.apiKey("x-ultracart-simple-key"); // ultraCartSimpleApiKey authentication
9548
+ }
9549
+ return [4 /*yield*/, this.request({
9550
+ path: "/sfvb/storefronts/{storefront_oid}/sequences/{sequence_uuid}/steps/{step_uuid}/postcard_proof".replace("{".concat("storefront_oid", "}"), encodeURIComponent(String(requestParameters.storefrontOid))).replace("{".concat("sequence_uuid", "}"), encodeURIComponent(String(requestParameters.sequenceUuid))).replace("{".concat("step_uuid", "}"), encodeURIComponent(String(requestParameters.stepUuid))),
9551
+ method: 'POST',
9552
+ headers: headerParameters,
9553
+ query: queryParameters,
9554
+ body: (0, models_1.SfvbPostcardProofRequestToJSON)(requestParameters.postcardProofRequest),
9555
+ }, initOverrides)];
9556
+ case 3:
9557
+ response = _c.sent();
9558
+ return [2 /*return*/, new runtime.JSONApiResponse(response, function (jsonValue) { return (0, models_1.SfvbPostcardProofResponseFromJSON)(jsonValue); })];
9559
+ }
9560
+ });
9561
+ });
9562
+ };
9563
+ /**
9564
+ * Renders both sides of the step\'s postcard as a send renders them, then has the print vendor render the card as a dry run. Returns the HTML of each side, the PNG image of each side that the vendor prints from, the vendor\'s thumbnails and its proof PDF. The QR code is the short link a send prints. No card is printed or mailed, nothing is billed, the step is not changed, and no coupon is created. A unique coupon code shows as PREVIEW-UNIQUE. The image urls are public. html_only returns the HTML alone, with no vendor render. An order must be a test order. cart_item_ids fills the cart a cart flow card shows. Works whether the step is on or off.
9565
+ * Proof a postcard step without mailing it
9566
+ */
9567
+ SfvbApi.prototype.proofSfvbSequencePostcard = function (requestParameters, initOverrides) {
9568
+ return __awaiter(this, void 0, void 0, function () {
9569
+ var response;
9570
+ return __generator(this, function (_a) {
9571
+ switch (_a.label) {
9572
+ case 0: return [4 /*yield*/, this.proofSfvbSequencePostcardRaw(requestParameters, initOverrides)];
9573
+ case 1:
9574
+ response = _a.sent();
9575
+ return [4 /*yield*/, response.value()];
9576
+ case 2: return [2 /*return*/, _a.sent()];
9577
+ }
9578
+ });
9579
+ });
9580
+ };
9511
9581
  /**
9512
9582
  * Freezes the draft as a published revision at its revision_number and sets who can see it. Owner only, with the draft\'s hash_sha256 as If-Match. Always needs sfvb_publish, because it changes what other merchants can install. Images, fonts, stylesheets and media must be relative paths, and credential shaped strings are refused. Public also needs the library publisher property on the account and no executable content at all - no script, html, embed, css or velocity elements. After those checks an automated AI review reads the fragment, which can take up to about a minute. A clear violation both of its models agree on refuses any publish with sfvb.library_ai_review_blocked. A public publish also needs its approval, otherwise sfvb.library_ai_review_inconclusive. The result is in content_manifest.ai_review.
9513
9583
  * Publish a library entry\'s draft
@@ -0,0 +1,79 @@
1
+ /**
2
+ * UltraCart Rest API V2
3
+ * UltraCart REST API Version 2
4
+ *
5
+ * The version of the OpenAPI document: 2.0.0
6
+ * Contact: support@ultracart.com
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ */
12
+ /**
13
+ *
14
+ * @export
15
+ * @interface SfvbPostcardProofRequest
16
+ */
17
+ export interface SfvbPostcardProofRequest {
18
+ /**
19
+ * The recipient street address. Without address1, city, state and postal_code, a sample address is used.
20
+ * @type {string}
21
+ * @memberof SfvbPostcardProofRequest
22
+ */
23
+ address1?: string;
24
+ /**
25
+ * The recipient second address line.
26
+ * @type {string}
27
+ * @memberof SfvbPostcardProofRequest
28
+ */
29
+ address2?: string;
30
+ /**
31
+ * Item ids for the cart a cart flow card renders with. The cart is made for the proof and deleted after it.
32
+ * @type {Array<string>}
33
+ * @memberof SfvbPostcardProofRequest
34
+ */
35
+ cart_item_ids?: Array<string>;
36
+ /**
37
+ * The recipient city.
38
+ * @type {string}
39
+ * @memberof SfvbPostcardProofRequest
40
+ */
41
+ city?: string;
42
+ /**
43
+ * The recipient name the card greets and is addressed to. Defaults to the signed in user.
44
+ * @type {string}
45
+ * @memberof SfvbPostcardProofRequest
46
+ */
47
+ customer_name?: string;
48
+ /**
49
+ * True to return only the rendered HTML of both sides, with no print vendor render. The default, false, also returns the images that would print and the vendor proof PDF.
50
+ * @type {boolean}
51
+ * @memberof SfvbPostcardProofRequest
52
+ */
53
+ html_only?: boolean;
54
+ /**
55
+ * A test order for an order flow card. Real orders are refused. Without one, an order flow card renders with a made up order.
56
+ * @type {string}
57
+ * @memberof SfvbPostcardProofRequest
58
+ */
59
+ order_id?: string;
60
+ /**
61
+ * The recipient postal code.
62
+ * @type {string}
63
+ * @memberof SfvbPostcardProofRequest
64
+ */
65
+ postal_code?: string;
66
+ /**
67
+ * The recipient state.
68
+ * @type {string}
69
+ * @memberof SfvbPostcardProofRequest
70
+ */
71
+ state?: string;
72
+ }
73
+ /**
74
+ * Check if a given object implements the SfvbPostcardProofRequest interface.
75
+ */
76
+ export declare function instanceOfSfvbPostcardProofRequest(value: object): boolean;
77
+ export declare function SfvbPostcardProofRequestFromJSON(json: any): SfvbPostcardProofRequest;
78
+ export declare function SfvbPostcardProofRequestFromJSONTyped(json: any, ignoreDiscriminator: boolean): SfvbPostcardProofRequest;
79
+ export declare function SfvbPostcardProofRequestToJSON(value?: SfvbPostcardProofRequest | null): any;
@@ -0,0 +1,66 @@
1
+ "use strict";
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+ /**
5
+ * UltraCart Rest API V2
6
+ * UltraCart REST API Version 2
7
+ *
8
+ * The version of the OpenAPI document: 2.0.0
9
+ * Contact: support@ultracart.com
10
+ *
11
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
12
+ * https://openapi-generator.tech
13
+ * Do not edit the class manually.
14
+ */
15
+ Object.defineProperty(exports, "__esModule", { value: true });
16
+ exports.SfvbPostcardProofRequestToJSON = exports.SfvbPostcardProofRequestFromJSONTyped = exports.SfvbPostcardProofRequestFromJSON = exports.instanceOfSfvbPostcardProofRequest = void 0;
17
+ var runtime_1 = require("../runtime");
18
+ /**
19
+ * Check if a given object implements the SfvbPostcardProofRequest interface.
20
+ */
21
+ function instanceOfSfvbPostcardProofRequest(value) {
22
+ var isInstance = true;
23
+ return isInstance;
24
+ }
25
+ exports.instanceOfSfvbPostcardProofRequest = instanceOfSfvbPostcardProofRequest;
26
+ function SfvbPostcardProofRequestFromJSON(json) {
27
+ return SfvbPostcardProofRequestFromJSONTyped(json, false);
28
+ }
29
+ exports.SfvbPostcardProofRequestFromJSON = SfvbPostcardProofRequestFromJSON;
30
+ function SfvbPostcardProofRequestFromJSONTyped(json, ignoreDiscriminator) {
31
+ if ((json === undefined) || (json === null)) {
32
+ return json;
33
+ }
34
+ return {
35
+ 'address1': !(0, runtime_1.exists)(json, 'address1') ? undefined : json['address1'],
36
+ 'address2': !(0, runtime_1.exists)(json, 'address2') ? undefined : json['address2'],
37
+ 'cart_item_ids': !(0, runtime_1.exists)(json, 'cart_item_ids') ? undefined : json['cart_item_ids'],
38
+ 'city': !(0, runtime_1.exists)(json, 'city') ? undefined : json['city'],
39
+ 'customer_name': !(0, runtime_1.exists)(json, 'customer_name') ? undefined : json['customer_name'],
40
+ 'html_only': !(0, runtime_1.exists)(json, 'html_only') ? undefined : json['html_only'],
41
+ 'order_id': !(0, runtime_1.exists)(json, 'order_id') ? undefined : json['order_id'],
42
+ 'postal_code': !(0, runtime_1.exists)(json, 'postal_code') ? undefined : json['postal_code'],
43
+ 'state': !(0, runtime_1.exists)(json, 'state') ? undefined : json['state'],
44
+ };
45
+ }
46
+ exports.SfvbPostcardProofRequestFromJSONTyped = SfvbPostcardProofRequestFromJSONTyped;
47
+ function SfvbPostcardProofRequestToJSON(value) {
48
+ if (value === undefined) {
49
+ return undefined;
50
+ }
51
+ if (value === null) {
52
+ return null;
53
+ }
54
+ return {
55
+ 'address1': value.address1,
56
+ 'address2': value.address2,
57
+ 'cart_item_ids': value.cart_item_ids,
58
+ 'city': value.city,
59
+ 'customer_name': value.customer_name,
60
+ 'html_only': value.html_only,
61
+ 'order_id': value.order_id,
62
+ 'postal_code': value.postal_code,
63
+ 'state': value.state,
64
+ };
65
+ }
66
+ exports.SfvbPostcardProofRequestToJSON = SfvbPostcardProofRequestToJSON;
@@ -0,0 +1,101 @@
1
+ /**
2
+ * UltraCart Rest API V2
3
+ * UltraCart REST API Version 2
4
+ *
5
+ * The version of the OpenAPI document: 2.0.0
6
+ * Contact: support@ultracart.com
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ */
12
+ import { SfvbErrorDetail } from './SfvbErrorDetail';
13
+ /**
14
+ *
15
+ * @export
16
+ * @interface SfvbPostcardProofResponse
17
+ */
18
+ export interface SfvbPostcardProofResponse {
19
+ /**
20
+ * The back as the send renders it, after the name tokens are filled.
21
+ * @type {string}
22
+ * @memberof SfvbPostcardProofResponse
23
+ */
24
+ back_html?: string;
25
+ /**
26
+ * The back as the PNG image the print vendor prints from. A public url.
27
+ * @type {string}
28
+ * @memberof SfvbPostcardProofResponse
29
+ */
30
+ back_image_url?: string;
31
+ /**
32
+ * The print vendor thumbnail of the back.
33
+ * @type {string}
34
+ * @memberof SfvbPostcardProofResponse
35
+ */
36
+ back_thumbnail_url?: string;
37
+ /**
38
+ * The front as the send renders it, after the name tokens are filled.
39
+ * @type {string}
40
+ * @memberof SfvbPostcardProofResponse
41
+ */
42
+ front_html?: string;
43
+ /**
44
+ * The front as the PNG image the print vendor prints from. A public url.
45
+ * @type {string}
46
+ * @memberof SfvbPostcardProofResponse
47
+ */
48
+ front_image_url?: string;
49
+ /**
50
+ * The print vendor thumbnail of the front.
51
+ * @type {string}
52
+ * @memberof SfvbPostcardProofResponse
53
+ */
54
+ front_thumbnail_url?: string;
55
+ /**
56
+ * Where the order came from. test for the order_id given, dummy for a made up one, none for no order.
57
+ * @type {string}
58
+ * @memberof SfvbPostcardProofResponse
59
+ */
60
+ order_source?: SfvbPostcardProofResponseOrderSourceEnum;
61
+ /**
62
+ * The postcard the step mails.
63
+ * @type {string}
64
+ * @memberof SfvbPostcardProofResponse
65
+ */
66
+ postcard_uuid?: string;
67
+ /**
68
+ * The print vendor proof PDF of both sides.
69
+ * @type {string}
70
+ * @memberof SfvbPostcardProofResponse
71
+ */
72
+ rendered_pdf_url?: string;
73
+ /**
74
+ * True when the print vendor rendered the card, so the image and PDF urls are set.
75
+ * @type {boolean}
76
+ * @memberof SfvbPostcardProofResponse
77
+ */
78
+ vendor_rendered?: boolean;
79
+ /**
80
+ * Where the proof differs from a send, such as a placeholder coupon code or a sample address, and anything that would make a send skip the card.
81
+ * @type {Array<SfvbErrorDetail>}
82
+ * @memberof SfvbPostcardProofResponse
83
+ */
84
+ warnings?: Array<SfvbErrorDetail>;
85
+ }
86
+ /**
87
+ * @export
88
+ */
89
+ export declare const SfvbPostcardProofResponseOrderSourceEnum: {
90
+ readonly Test: "test";
91
+ readonly Dummy: "dummy";
92
+ readonly None: "none";
93
+ };
94
+ export type SfvbPostcardProofResponseOrderSourceEnum = typeof SfvbPostcardProofResponseOrderSourceEnum[keyof typeof SfvbPostcardProofResponseOrderSourceEnum];
95
+ /**
96
+ * Check if a given object implements the SfvbPostcardProofResponse interface.
97
+ */
98
+ export declare function instanceOfSfvbPostcardProofResponse(value: object): boolean;
99
+ export declare function SfvbPostcardProofResponseFromJSON(json: any): SfvbPostcardProofResponse;
100
+ export declare function SfvbPostcardProofResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): SfvbPostcardProofResponse;
101
+ export declare function SfvbPostcardProofResponseToJSON(value?: SfvbPostcardProofResponse | null): any;
@@ -0,0 +1,79 @@
1
+ "use strict";
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+ /**
5
+ * UltraCart Rest API V2
6
+ * UltraCart REST API Version 2
7
+ *
8
+ * The version of the OpenAPI document: 2.0.0
9
+ * Contact: support@ultracart.com
10
+ *
11
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
12
+ * https://openapi-generator.tech
13
+ * Do not edit the class manually.
14
+ */
15
+ Object.defineProperty(exports, "__esModule", { value: true });
16
+ exports.SfvbPostcardProofResponseToJSON = exports.SfvbPostcardProofResponseFromJSONTyped = exports.SfvbPostcardProofResponseFromJSON = exports.instanceOfSfvbPostcardProofResponse = exports.SfvbPostcardProofResponseOrderSourceEnum = void 0;
17
+ var runtime_1 = require("../runtime");
18
+ var SfvbErrorDetail_1 = require("./SfvbErrorDetail");
19
+ /**
20
+ * @export
21
+ */
22
+ exports.SfvbPostcardProofResponseOrderSourceEnum = {
23
+ Test: 'test',
24
+ Dummy: 'dummy',
25
+ None: 'none'
26
+ };
27
+ /**
28
+ * Check if a given object implements the SfvbPostcardProofResponse interface.
29
+ */
30
+ function instanceOfSfvbPostcardProofResponse(value) {
31
+ var isInstance = true;
32
+ return isInstance;
33
+ }
34
+ exports.instanceOfSfvbPostcardProofResponse = instanceOfSfvbPostcardProofResponse;
35
+ function SfvbPostcardProofResponseFromJSON(json) {
36
+ return SfvbPostcardProofResponseFromJSONTyped(json, false);
37
+ }
38
+ exports.SfvbPostcardProofResponseFromJSON = SfvbPostcardProofResponseFromJSON;
39
+ function SfvbPostcardProofResponseFromJSONTyped(json, ignoreDiscriminator) {
40
+ if ((json === undefined) || (json === null)) {
41
+ return json;
42
+ }
43
+ return {
44
+ 'back_html': !(0, runtime_1.exists)(json, 'back_html') ? undefined : json['back_html'],
45
+ 'back_image_url': !(0, runtime_1.exists)(json, 'back_image_url') ? undefined : json['back_image_url'],
46
+ 'back_thumbnail_url': !(0, runtime_1.exists)(json, 'back_thumbnail_url') ? undefined : json['back_thumbnail_url'],
47
+ 'front_html': !(0, runtime_1.exists)(json, 'front_html') ? undefined : json['front_html'],
48
+ 'front_image_url': !(0, runtime_1.exists)(json, 'front_image_url') ? undefined : json['front_image_url'],
49
+ 'front_thumbnail_url': !(0, runtime_1.exists)(json, 'front_thumbnail_url') ? undefined : json['front_thumbnail_url'],
50
+ 'order_source': !(0, runtime_1.exists)(json, 'order_source') ? undefined : json['order_source'],
51
+ 'postcard_uuid': !(0, runtime_1.exists)(json, 'postcard_uuid') ? undefined : json['postcard_uuid'],
52
+ 'rendered_pdf_url': !(0, runtime_1.exists)(json, 'rendered_pdf_url') ? undefined : json['rendered_pdf_url'],
53
+ 'vendor_rendered': !(0, runtime_1.exists)(json, 'vendor_rendered') ? undefined : json['vendor_rendered'],
54
+ 'warnings': !(0, runtime_1.exists)(json, 'warnings') ? undefined : (json['warnings'].map(SfvbErrorDetail_1.SfvbErrorDetailFromJSON)),
55
+ };
56
+ }
57
+ exports.SfvbPostcardProofResponseFromJSONTyped = SfvbPostcardProofResponseFromJSONTyped;
58
+ function SfvbPostcardProofResponseToJSON(value) {
59
+ if (value === undefined) {
60
+ return undefined;
61
+ }
62
+ if (value === null) {
63
+ return null;
64
+ }
65
+ return {
66
+ 'back_html': value.back_html,
67
+ 'back_image_url': value.back_image_url,
68
+ 'back_thumbnail_url': value.back_thumbnail_url,
69
+ 'front_html': value.front_html,
70
+ 'front_image_url': value.front_image_url,
71
+ 'front_thumbnail_url': value.front_thumbnail_url,
72
+ 'order_source': value.order_source,
73
+ 'postcard_uuid': value.postcard_uuid,
74
+ 'rendered_pdf_url': value.rendered_pdf_url,
75
+ 'vendor_rendered': value.vendor_rendered,
76
+ 'warnings': value.warnings === undefined ? undefined : (value.warnings.map(SfvbErrorDetail_1.SfvbErrorDetailToJSON)),
77
+ };
78
+ }
79
+ exports.SfvbPostcardProofResponseToJSON = SfvbPostcardProofResponseToJSON;
@@ -1135,6 +1135,8 @@ export * from './SfvbPageResponse';
1135
1135
  export * from './SfvbPageSelectors';
1136
1136
  export * from './SfvbPageSettingsRequest';
1137
1137
  export * from './SfvbPageSummary';
1138
+ export * from './SfvbPostcardProofRequest';
1139
+ export * from './SfvbPostcardProofResponse';
1138
1140
  export * from './SfvbPreviewAccessRequest';
1139
1141
  export * from './SfvbPreviewAccessResponse';
1140
1142
  export * from './SfvbPreviewSessionRequest';
@@ -1153,6 +1153,8 @@ __exportStar(require("./SfvbPageResponse"), exports);
1153
1153
  __exportStar(require("./SfvbPageSelectors"), exports);
1154
1154
  __exportStar(require("./SfvbPageSettingsRequest"), exports);
1155
1155
  __exportStar(require("./SfvbPageSummary"), exports);
1156
+ __exportStar(require("./SfvbPostcardProofRequest"), exports);
1157
+ __exportStar(require("./SfvbPostcardProofResponse"), exports);
1156
1158
  __exportStar(require("./SfvbPreviewAccessRequest"), exports);
1157
1159
  __exportStar(require("./SfvbPreviewAccessResponse"), exports);
1158
1160
  __exportStar(require("./SfvbPreviewSessionRequest"), exports);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ultracart_rest_api_v2_typescript",
3
- "version": "4.1.220",
3
+ "version": "4.1.221",
4
4
  "description": "UltraCart Rest TypeScript SDK",
5
5
  "author": "UltraCart",
6
6
  "repository": {
@@ -363,6 +363,12 @@ import {
363
363
  SfvbPageSettingsRequest,
364
364
  SfvbPageSettingsRequestFromJSON,
365
365
  SfvbPageSettingsRequestToJSON,
366
+ SfvbPostcardProofRequest,
367
+ SfvbPostcardProofRequestFromJSON,
368
+ SfvbPostcardProofRequestToJSON,
369
+ SfvbPostcardProofResponse,
370
+ SfvbPostcardProofResponseFromJSON,
371
+ SfvbPostcardProofResponseToJSON,
366
372
  SfvbPreviewAccessRequest,
367
373
  SfvbPreviewAccessRequestFromJSON,
368
374
  SfvbPreviewAccessRequestToJSON,
@@ -1327,6 +1333,13 @@ export interface MoveSfvbUpsellPathRequest {
1327
1333
  moveRequest: SfvbUpsellPathMoveRequest;
1328
1334
  }
1329
1335
 
1336
+ export interface ProofSfvbSequencePostcardRequest {
1337
+ storefrontOid: number;
1338
+ sequenceUuid: string;
1339
+ stepUuid: string;
1340
+ postcardProofRequest: SfvbPostcardProofRequest;
1341
+ }
1342
+
1330
1343
  export interface PublishSfvbLibraryEntryRequest {
1331
1344
  storefrontOid: number;
1332
1345
  libraryOid: number;
@@ -4312,6 +4325,25 @@ export interface SfvbApiInterface {
4312
4325
  */
4313
4326
  moveSfvbUpsellPath(requestParameters: MoveSfvbUpsellPathRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<SfvbUpsellPath>;
4314
4327
 
4328
+ /**
4329
+ * Renders both sides of the step\'s postcard as a send renders them, then has the print vendor render the card as a dry run. Returns the HTML of each side, the PNG image of each side that the vendor prints from, the vendor\'s thumbnails and its proof PDF. The QR code is the short link a send prints. No card is printed or mailed, nothing is billed, the step is not changed, and no coupon is created. A unique coupon code shows as PREVIEW-UNIQUE. The image urls are public. html_only returns the HTML alone, with no vendor render. An order must be a test order. cart_item_ids fills the cart a cart flow card shows. Works whether the step is on or off.
4330
+ * @summary Proof a postcard step without mailing it
4331
+ * @param {number} storefrontOid
4332
+ * @param {string} sequenceUuid
4333
+ * @param {string} stepUuid
4334
+ * @param {SfvbPostcardProofRequest} postcardProofRequest Who the card is addressed to, and the order or cart it shows
4335
+ * @param {*} [options] Override http request option.
4336
+ * @throws {RequiredError}
4337
+ * @memberof SfvbApiInterface
4338
+ */
4339
+ proofSfvbSequencePostcardRaw(requestParameters: ProofSfvbSequencePostcardRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<SfvbPostcardProofResponse>>;
4340
+
4341
+ /**
4342
+ * Renders both sides of the step\'s postcard as a send renders them, then has the print vendor render the card as a dry run. Returns the HTML of each side, the PNG image of each side that the vendor prints from, the vendor\'s thumbnails and its proof PDF. The QR code is the short link a send prints. No card is printed or mailed, nothing is billed, the step is not changed, and no coupon is created. A unique coupon code shows as PREVIEW-UNIQUE. The image urls are public. html_only returns the HTML alone, with no vendor render. An order must be a test order. cart_item_ids fills the cart a cart flow card shows. Works whether the step is on or off.
4343
+ * Proof a postcard step without mailing it
4344
+ */
4345
+ proofSfvbSequencePostcard(requestParameters: ProofSfvbSequencePostcardRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<SfvbPostcardProofResponse>;
4346
+
4315
4347
  /**
4316
4348
  * Freezes the draft as a published revision at its revision_number and sets who can see it. Owner only, with the draft\'s hash_sha256 as If-Match. Always needs sfvb_publish, because it changes what other merchants can install. Images, fonts, stylesheets and media must be relative paths, and credential shaped strings are refused. Public also needs the library publisher property on the account and no executable content at all - no script, html, embed, css or velocity elements. After those checks an automated AI review reads the fragment, which can take up to about a minute. A clear violation both of its models agree on refuses any publish with sfvb.library_ai_review_blocked. A public publish also needs its approval, otherwise sfvb.library_ai_review_inconclusive. The result is in content_manifest.ai_review.
4317
4349
  * @summary Publish a library entry\'s draft
@@ -12561,6 +12593,62 @@ export class SfvbApi extends runtime.BaseAPI implements SfvbApiInterface {
12561
12593
  return await response.value();
12562
12594
  }
12563
12595
 
12596
+ /**
12597
+ * Renders both sides of the step\'s postcard as a send renders them, then has the print vendor render the card as a dry run. Returns the HTML of each side, the PNG image of each side that the vendor prints from, the vendor\'s thumbnails and its proof PDF. The QR code is the short link a send prints. No card is printed or mailed, nothing is billed, the step is not changed, and no coupon is created. A unique coupon code shows as PREVIEW-UNIQUE. The image urls are public. html_only returns the HTML alone, with no vendor render. An order must be a test order. cart_item_ids fills the cart a cart flow card shows. Works whether the step is on or off.
12598
+ * Proof a postcard step without mailing it
12599
+ */
12600
+ async proofSfvbSequencePostcardRaw(requestParameters: ProofSfvbSequencePostcardRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<SfvbPostcardProofResponse>> {
12601
+ if (requestParameters.storefrontOid === null || requestParameters.storefrontOid === undefined) {
12602
+ throw new runtime.RequiredError('storefrontOid','Required parameter requestParameters.storefrontOid was null or undefined when calling proofSfvbSequencePostcard.');
12603
+ }
12604
+
12605
+ if (requestParameters.sequenceUuid === null || requestParameters.sequenceUuid === undefined) {
12606
+ throw new runtime.RequiredError('sequenceUuid','Required parameter requestParameters.sequenceUuid was null or undefined when calling proofSfvbSequencePostcard.');
12607
+ }
12608
+
12609
+ if (requestParameters.stepUuid === null || requestParameters.stepUuid === undefined) {
12610
+ throw new runtime.RequiredError('stepUuid','Required parameter requestParameters.stepUuid was null or undefined when calling proofSfvbSequencePostcard.');
12611
+ }
12612
+
12613
+ if (requestParameters.postcardProofRequest === null || requestParameters.postcardProofRequest === undefined) {
12614
+ throw new runtime.RequiredError('postcardProofRequest','Required parameter requestParameters.postcardProofRequest was null or undefined when calling proofSfvbSequencePostcard.');
12615
+ }
12616
+
12617
+ const queryParameters: any = {};
12618
+
12619
+ const headerParameters: runtime.HTTPHeaders = {};
12620
+
12621
+ headerParameters['Content-Type'] = 'application/json';
12622
+
12623
+ if (this.configuration && this.configuration.accessToken) {
12624
+ // oauth required
12625
+ headerParameters["Authorization"] = await this.configuration.accessToken("ultraCartOauth", []);
12626
+ }
12627
+
12628
+ if (this.configuration && this.configuration.apiKey) {
12629
+ headerParameters["x-ultracart-simple-key"] = this.configuration.apiKey("x-ultracart-simple-key"); // ultraCartSimpleApiKey authentication
12630
+ }
12631
+
12632
+ const response = await this.request({
12633
+ path: `/sfvb/storefronts/{storefront_oid}/sequences/{sequence_uuid}/steps/{step_uuid}/postcard_proof`.replace(`{${"storefront_oid"}}`, encodeURIComponent(String(requestParameters.storefrontOid))).replace(`{${"sequence_uuid"}}`, encodeURIComponent(String(requestParameters.sequenceUuid))).replace(`{${"step_uuid"}}`, encodeURIComponent(String(requestParameters.stepUuid))),
12634
+ method: 'POST',
12635
+ headers: headerParameters,
12636
+ query: queryParameters,
12637
+ body: SfvbPostcardProofRequestToJSON(requestParameters.postcardProofRequest),
12638
+ }, initOverrides);
12639
+
12640
+ return new runtime.JSONApiResponse(response, (jsonValue) => SfvbPostcardProofResponseFromJSON(jsonValue));
12641
+ }
12642
+
12643
+ /**
12644
+ * Renders both sides of the step\'s postcard as a send renders them, then has the print vendor render the card as a dry run. Returns the HTML of each side, the PNG image of each side that the vendor prints from, the vendor\'s thumbnails and its proof PDF. The QR code is the short link a send prints. No card is printed or mailed, nothing is billed, the step is not changed, and no coupon is created. A unique coupon code shows as PREVIEW-UNIQUE. The image urls are public. html_only returns the HTML alone, with no vendor render. An order must be a test order. cart_item_ids fills the cart a cart flow card shows. Works whether the step is on or off.
12645
+ * Proof a postcard step without mailing it
12646
+ */
12647
+ async proofSfvbSequencePostcard(requestParameters: ProofSfvbSequencePostcardRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<SfvbPostcardProofResponse> {
12648
+ const response = await this.proofSfvbSequencePostcardRaw(requestParameters, initOverrides);
12649
+ return await response.value();
12650
+ }
12651
+
12564
12652
  /**
12565
12653
  * Freezes the draft as a published revision at its revision_number and sets who can see it. Owner only, with the draft\'s hash_sha256 as If-Match. Always needs sfvb_publish, because it changes what other merchants can install. Images, fonts, stylesheets and media must be relative paths, and credential shaped strings are refused. Public also needs the library publisher property on the account and no executable content at all - no script, html, embed, css or velocity elements. After those checks an automated AI review reads the fragment, which can take up to about a minute. A clear violation both of its models agree on refuses any publish with sfvb.library_ai_review_blocked. A public publish also needs its approval, otherwise sfvb.library_ai_review_inconclusive. The result is in content_manifest.ai_review.
12566
12654
  * Publish a library entry\'s draft
@@ -0,0 +1,131 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+ /**
4
+ * UltraCart Rest API V2
5
+ * UltraCart REST API Version 2
6
+ *
7
+ * The version of the OpenAPI document: 2.0.0
8
+ * Contact: support@ultracart.com
9
+ *
10
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
+ * https://openapi-generator.tech
12
+ * Do not edit the class manually.
13
+ */
14
+
15
+ import { exists, mapValues } from '../runtime';
16
+ /**
17
+ *
18
+ * @export
19
+ * @interface SfvbPostcardProofRequest
20
+ */
21
+ export interface SfvbPostcardProofRequest {
22
+ /**
23
+ * The recipient street address. Without address1, city, state and postal_code, a sample address is used.
24
+ * @type {string}
25
+ * @memberof SfvbPostcardProofRequest
26
+ */
27
+ address1?: string;
28
+ /**
29
+ * The recipient second address line.
30
+ * @type {string}
31
+ * @memberof SfvbPostcardProofRequest
32
+ */
33
+ address2?: string;
34
+ /**
35
+ * Item ids for the cart a cart flow card renders with. The cart is made for the proof and deleted after it.
36
+ * @type {Array<string>}
37
+ * @memberof SfvbPostcardProofRequest
38
+ */
39
+ cart_item_ids?: Array<string>;
40
+ /**
41
+ * The recipient city.
42
+ * @type {string}
43
+ * @memberof SfvbPostcardProofRequest
44
+ */
45
+ city?: string;
46
+ /**
47
+ * The recipient name the card greets and is addressed to. Defaults to the signed in user.
48
+ * @type {string}
49
+ * @memberof SfvbPostcardProofRequest
50
+ */
51
+ customer_name?: string;
52
+ /**
53
+ * True to return only the rendered HTML of both sides, with no print vendor render. The default, false, also returns the images that would print and the vendor proof PDF.
54
+ * @type {boolean}
55
+ * @memberof SfvbPostcardProofRequest
56
+ */
57
+ html_only?: boolean;
58
+ /**
59
+ * A test order for an order flow card. Real orders are refused. Without one, an order flow card renders with a made up order.
60
+ * @type {string}
61
+ * @memberof SfvbPostcardProofRequest
62
+ */
63
+ order_id?: string;
64
+ /**
65
+ * The recipient postal code.
66
+ * @type {string}
67
+ * @memberof SfvbPostcardProofRequest
68
+ */
69
+ postal_code?: string;
70
+ /**
71
+ * The recipient state.
72
+ * @type {string}
73
+ * @memberof SfvbPostcardProofRequest
74
+ */
75
+ state?: string;
76
+ }
77
+
78
+
79
+
80
+ /**
81
+ * Check if a given object implements the SfvbPostcardProofRequest interface.
82
+ */
83
+ export function instanceOfSfvbPostcardProofRequest(value: object): boolean {
84
+ let isInstance = true;
85
+
86
+ return isInstance;
87
+ }
88
+
89
+ export function SfvbPostcardProofRequestFromJSON(json: any): SfvbPostcardProofRequest {
90
+ return SfvbPostcardProofRequestFromJSONTyped(json, false);
91
+ }
92
+
93
+ export function SfvbPostcardProofRequestFromJSONTyped(json: any, ignoreDiscriminator: boolean): SfvbPostcardProofRequest {
94
+ if ((json === undefined) || (json === null)) {
95
+ return json;
96
+ }
97
+ return {
98
+
99
+ 'address1': !exists(json, 'address1') ? undefined : json['address1'],
100
+ 'address2': !exists(json, 'address2') ? undefined : json['address2'],
101
+ 'cart_item_ids': !exists(json, 'cart_item_ids') ? undefined : json['cart_item_ids'],
102
+ 'city': !exists(json, 'city') ? undefined : json['city'],
103
+ 'customer_name': !exists(json, 'customer_name') ? undefined : json['customer_name'],
104
+ 'html_only': !exists(json, 'html_only') ? undefined : json['html_only'],
105
+ 'order_id': !exists(json, 'order_id') ? undefined : json['order_id'],
106
+ 'postal_code': !exists(json, 'postal_code') ? undefined : json['postal_code'],
107
+ 'state': !exists(json, 'state') ? undefined : json['state'],
108
+ };
109
+ }
110
+
111
+ export function SfvbPostcardProofRequestToJSON(value?: SfvbPostcardProofRequest | null): any {
112
+ if (value === undefined) {
113
+ return undefined;
114
+ }
115
+ if (value === null) {
116
+ return null;
117
+ }
118
+ return {
119
+
120
+ 'address1': value.address1,
121
+ 'address2': value.address2,
122
+ 'cart_item_ids': value.cart_item_ids,
123
+ 'city': value.city,
124
+ 'customer_name': value.customer_name,
125
+ 'html_only': value.html_only,
126
+ 'order_id': value.order_id,
127
+ 'postal_code': value.postal_code,
128
+ 'state': value.state,
129
+ };
130
+ }
131
+
@@ -0,0 +1,165 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+ /**
4
+ * UltraCart Rest API V2
5
+ * UltraCart REST API Version 2
6
+ *
7
+ * The version of the OpenAPI document: 2.0.0
8
+ * Contact: support@ultracart.com
9
+ *
10
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
+ * https://openapi-generator.tech
12
+ * Do not edit the class manually.
13
+ */
14
+
15
+ import { exists, mapValues } from '../runtime';
16
+ import {
17
+ SfvbErrorDetail,
18
+ SfvbErrorDetailFromJSON,
19
+ SfvbErrorDetailFromJSONTyped,
20
+ SfvbErrorDetailToJSON,
21
+ } from './SfvbErrorDetail';
22
+
23
+ /**
24
+ *
25
+ * @export
26
+ * @interface SfvbPostcardProofResponse
27
+ */
28
+ export interface SfvbPostcardProofResponse {
29
+ /**
30
+ * The back as the send renders it, after the name tokens are filled.
31
+ * @type {string}
32
+ * @memberof SfvbPostcardProofResponse
33
+ */
34
+ back_html?: string;
35
+ /**
36
+ * The back as the PNG image the print vendor prints from. A public url.
37
+ * @type {string}
38
+ * @memberof SfvbPostcardProofResponse
39
+ */
40
+ back_image_url?: string;
41
+ /**
42
+ * The print vendor thumbnail of the back.
43
+ * @type {string}
44
+ * @memberof SfvbPostcardProofResponse
45
+ */
46
+ back_thumbnail_url?: string;
47
+ /**
48
+ * The front as the send renders it, after the name tokens are filled.
49
+ * @type {string}
50
+ * @memberof SfvbPostcardProofResponse
51
+ */
52
+ front_html?: string;
53
+ /**
54
+ * The front as the PNG image the print vendor prints from. A public url.
55
+ * @type {string}
56
+ * @memberof SfvbPostcardProofResponse
57
+ */
58
+ front_image_url?: string;
59
+ /**
60
+ * The print vendor thumbnail of the front.
61
+ * @type {string}
62
+ * @memberof SfvbPostcardProofResponse
63
+ */
64
+ front_thumbnail_url?: string;
65
+ /**
66
+ * Where the order came from. test for the order_id given, dummy for a made up one, none for no order.
67
+ * @type {string}
68
+ * @memberof SfvbPostcardProofResponse
69
+ */
70
+ order_source?: SfvbPostcardProofResponseOrderSourceEnum;
71
+ /**
72
+ * The postcard the step mails.
73
+ * @type {string}
74
+ * @memberof SfvbPostcardProofResponse
75
+ */
76
+ postcard_uuid?: string;
77
+ /**
78
+ * The print vendor proof PDF of both sides.
79
+ * @type {string}
80
+ * @memberof SfvbPostcardProofResponse
81
+ */
82
+ rendered_pdf_url?: string;
83
+ /**
84
+ * True when the print vendor rendered the card, so the image and PDF urls are set.
85
+ * @type {boolean}
86
+ * @memberof SfvbPostcardProofResponse
87
+ */
88
+ vendor_rendered?: boolean;
89
+ /**
90
+ * Where the proof differs from a send, such as a placeholder coupon code or a sample address, and anything that would make a send skip the card.
91
+ * @type {Array<SfvbErrorDetail>}
92
+ * @memberof SfvbPostcardProofResponse
93
+ */
94
+ warnings?: Array<SfvbErrorDetail>;
95
+ }
96
+
97
+
98
+
99
+ /**
100
+ * @export
101
+ */
102
+ export const SfvbPostcardProofResponseOrderSourceEnum = {
103
+ Test: 'test',
104
+ Dummy: 'dummy',
105
+ None: 'none'
106
+ } as const;
107
+ export type SfvbPostcardProofResponseOrderSourceEnum = typeof SfvbPostcardProofResponseOrderSourceEnum[keyof typeof SfvbPostcardProofResponseOrderSourceEnum];
108
+
109
+
110
+ /**
111
+ * Check if a given object implements the SfvbPostcardProofResponse interface.
112
+ */
113
+ export function instanceOfSfvbPostcardProofResponse(value: object): boolean {
114
+ let isInstance = true;
115
+
116
+ return isInstance;
117
+ }
118
+
119
+ export function SfvbPostcardProofResponseFromJSON(json: any): SfvbPostcardProofResponse {
120
+ return SfvbPostcardProofResponseFromJSONTyped(json, false);
121
+ }
122
+
123
+ export function SfvbPostcardProofResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): SfvbPostcardProofResponse {
124
+ if ((json === undefined) || (json === null)) {
125
+ return json;
126
+ }
127
+ return {
128
+
129
+ 'back_html': !exists(json, 'back_html') ? undefined : json['back_html'],
130
+ 'back_image_url': !exists(json, 'back_image_url') ? undefined : json['back_image_url'],
131
+ 'back_thumbnail_url': !exists(json, 'back_thumbnail_url') ? undefined : json['back_thumbnail_url'],
132
+ 'front_html': !exists(json, 'front_html') ? undefined : json['front_html'],
133
+ 'front_image_url': !exists(json, 'front_image_url') ? undefined : json['front_image_url'],
134
+ 'front_thumbnail_url': !exists(json, 'front_thumbnail_url') ? undefined : json['front_thumbnail_url'],
135
+ 'order_source': !exists(json, 'order_source') ? undefined : json['order_source'],
136
+ 'postcard_uuid': !exists(json, 'postcard_uuid') ? undefined : json['postcard_uuid'],
137
+ 'rendered_pdf_url': !exists(json, 'rendered_pdf_url') ? undefined : json['rendered_pdf_url'],
138
+ 'vendor_rendered': !exists(json, 'vendor_rendered') ? undefined : json['vendor_rendered'],
139
+ 'warnings': !exists(json, 'warnings') ? undefined : ((json['warnings'] as Array<any>).map(SfvbErrorDetailFromJSON)),
140
+ };
141
+ }
142
+
143
+ export function SfvbPostcardProofResponseToJSON(value?: SfvbPostcardProofResponse | null): any {
144
+ if (value === undefined) {
145
+ return undefined;
146
+ }
147
+ if (value === null) {
148
+ return null;
149
+ }
150
+ return {
151
+
152
+ 'back_html': value.back_html,
153
+ 'back_image_url': value.back_image_url,
154
+ 'back_thumbnail_url': value.back_thumbnail_url,
155
+ 'front_html': value.front_html,
156
+ 'front_image_url': value.front_image_url,
157
+ 'front_thumbnail_url': value.front_thumbnail_url,
158
+ 'order_source': value.order_source,
159
+ 'postcard_uuid': value.postcard_uuid,
160
+ 'rendered_pdf_url': value.rendered_pdf_url,
161
+ 'vendor_rendered': value.vendor_rendered,
162
+ 'warnings': value.warnings === undefined ? undefined : ((value.warnings as Array<any>).map(SfvbErrorDetailToJSON)),
163
+ };
164
+ }
165
+
@@ -1137,6 +1137,8 @@ export * from './SfvbPageResponse';
1137
1137
  export * from './SfvbPageSelectors';
1138
1138
  export * from './SfvbPageSettingsRequest';
1139
1139
  export * from './SfvbPageSummary';
1140
+ export * from './SfvbPostcardProofRequest';
1141
+ export * from './SfvbPostcardProofResponse';
1140
1142
  export * from './SfvbPreviewAccessRequest';
1141
1143
  export * from './SfvbPreviewAccessResponse';
1142
1144
  export * from './SfvbPreviewSessionRequest';