@combeenation/custom-code-sdk
    Preparing search index...

    Function createTempPdfFromAssets

    • Creates a temporary PDF from one or more assets which will be merged in the given order.

      Simplified helper built on top of convertDocument. Use convertDocument directly for advanced scenarios.

      Parameters

      • bundleAliasName: string

        Bundle name where the assets are stored

      • assetTasks: CreatePdfTasks[]

        One or more "assets tasks" which will be merged in the given order

      • name: string

        Optional name which will be used when downloading the file

      Returns Promise<string | undefined>

      URL to the generated cfgn file, if successful

      const resultUrl = await createTempPdfFromAssets(
      'MyBundle',
      [
      {
      type: 'PdfAsset',
      assetPath: 'quotePdfAsset',
      context: {
      subject: 'MySubject',
      },
      },
      {
      type: 'Asset',
      assetPath: 'Pdf2',
      },
      ],
      `Your_quote_${new Date().toISOString()}`
      );