diff --git a/CHANGELOG.md b/CHANGELOG.md index 626ca4c..a62b194 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -7,6 +7,10 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0. ## [Unreleased] +### Removed + +- **[BREAKING]** `OneBlinkUploader.uploadPDFConversion()` +- ## [6.1.0] - 2026-04-10 ### Added diff --git a/src/OneBlinkUploader.ts b/src/OneBlinkUploader.ts index 1f4675d..6dfd01a 100644 --- a/src/OneBlinkUploader.ts +++ b/src/OneBlinkUploader.ts @@ -6,7 +6,7 @@ import { UploadFormSubmissionOptions, UploadOptions, UploadEmailAttachmentOptions, - UploadPDFConversionOptions, + UploadCustomPDFOptions, UploadAiBuilderAttachmentOptions, } from './types.js' import { SubmissionTypes } from '@oneblink/types' @@ -514,45 +514,6 @@ export default class OneBlinkUploader { }) } - /** - * Upload a PDF for conversion. PDF Conversions are always private. - * - * #### Example - * - * ```ts - * const abortController = new AbortController() - * const result = await uploader.uploadPDFConversion({ - * onProgress: (progress) => { - * // ... - * }, - * data: pdfData, - * formId: 1, - * abortSignal: abortController.signal, - * }) - * ``` - * - * @param data The PDF data and options - * @returns The upload result - */ - async uploadPDFConversion({ - onProgress, - abortSignal, - data, - formId, - }: UploadPDFConversionOptions) { - return await uploadToS3<{ - pdfConversionId: string - pdfConversionJobId: number - }>({ - ...this, - contentType: 'application/pdf', - body: data, - key: `forms/${formId}/pdf-conversion`, - abortSignal, - onProgress, - }) - } - /** * Upload an attachment for use with the AI builder. * @@ -620,7 +581,7 @@ export default class OneBlinkUploader { abortSignal, data, formId, - }: UploadPDFConversionOptions) { + }: UploadCustomPDFOptions) { return await uploadToS3({ ...this, contentType: 'application/pdf', diff --git a/src/types.ts b/src/types.ts index 106507a..0848def 100644 --- a/src/types.ts +++ b/src/types.ts @@ -72,7 +72,7 @@ export type UploadAssetOptions = UploadOptions & { fileName: string } -export type UploadPDFConversionOptions = UploadOptions & { +export type UploadCustomPDFOptions = UploadOptions & { /** The PDF File to upload */ data: AttachmentUploadData /** The id of the Form that the PDF Conversion is occurring on */