Retries that never bill twice
Network errors, 429 and 5xx responses are retried with growing pauses. Every POST carries an idempotency key, so a retry returns the first render instead of making a second one. You can set your own key, such as the invoice number.
await dda.pdf.fromHtml({ html }, {
idempotencyKey: `invoice-${id}`,
});