/*
 * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
 */
import { triggersCreateTrigger } from "../funcs/triggersCreateTrigger.js";
import { triggersDeleteTrigger } from "../funcs/triggersDeleteTrigger.js";
import { triggersListTrigger } from "../funcs/triggersListTrigger.js";
import { triggersUpdateTrigger } from "../funcs/triggersUpdateTrigger.js";
import { ClientSDK } from "../lib/sdks.js";
import { unwrapAsync } from "../types/fp.js";
export class Triggers extends ClientSDK {
    /**
     * Lists all webhook notification triggers configured for your product environmentcloudinary
     *
     * @remarks
     * Retrieves a list of all event triggers and notifications within your product environment.
     */
    async listTrigger(eventType, options) {
        return unwrapAsync(triggersListTrigger(this, eventType, options));
    }
    /**
     * Creates a new notification trigger (webhook) by specifying an event type and a destination
     *
     * @remarks
     * Creates a new trigger.
     * Your product environment supports triggers up to a maximum determined by multiplying the number of unique event types by the limit of 30 notification URLs.
     */
    async createTrigger(request, options) {
        return unwrapAsync(triggersCreateTrigger(this, request, options));
    }
    /**
     * Updates the callback URL of an existing webhook trigger in your Cloudinary account
     *
     * @remarks
     * Updates a notification URL for a trigger.
     */
    async updateTrigger(id, requestBody, options) {
        return unwrapAsync(triggersUpdateTrigger(this, id, requestBody, options));
    }
    /**
     * Deletes a notification trigger
     *
     * @remarks
     * Deletes a trigger.
     */
    async deleteTrigger(id, options) {
        return unwrapAsync(triggersDeleteTrigger(this, id, options));
    }
}
//# sourceMappingURL=triggers.js.map