import type { BentoClient } from '../client'; import type { BatchSendTransactionalEmailsParameter, BatchImportEventsParameter, BatchImportSubscribersParameter } from './types'; export declare class BentoBatch { private readonly _client; private readonly _maxEmailBatchSize; private readonly _maxBatchSize; private readonly _url; constructor(_client: BentoClient); /** * **This does not trigger automations!** - If you wish to trigger automations, please batch import * events with the type set to `BentoEvents.SUBSCRIBE`, or `$subscribe`. Note that the batch event import * cannot attach custom fields and will ignore everything except the email. * * Creates a batch job to import subscribers into the system. You can pass in * between 1 and 1,000 subscribers to import. Each subscriber must have an email, * and may optionally have any additional fields. The additional fields are added * as custom fields on the subscriber. * * This method is processed by the Bento import queues and it may take between 1 and * 5 minutes for the results to appear in your dashboard. * * Returns the number of subscribers that were imported. * * @param parameters * @returns Promise\ */ importSubscribers(parameters: BatchImportSubscribersParameter): Promise; /** * Creates a batch job to import events into the system. You can pass in * between 1 and 1,000 events to import. Each event must have an email and * a type. In addition to this, you my pass in additional data in the * `details` property. * * Returns the number of events that were imported. * * @param parameters * @returns Promise\ */ importEvents(parameters: BatchImportEventsParameter): Promise; /** * Creates a batch job to send transactional emails from Bento's infrastructure. You can pass in * between 1 and 100 emails to send. * * Each email must have a `to` address, a `from` address, a `subject`, an `html_body` * and `transactional: true`. * In addition you can add a `personalizations` object to provide * liquid tags that will be injected into the email. * * Returns the number of events that were imported. * * @param parameters * @returns Promise\ */ sendTransactionalEmails(parameters: BatchSendTransactionalEmailsParameter): Promise; }