1 | import { Header } from "../message/SupportingTypes";
|
2 | export interface WebhookRequestTriggers {
|
3 | Open?: OpenWebhookTrigger;
|
4 | Click?: WebhookTrigger;
|
5 | Delivery?: WebhookTrigger;
|
6 | Bounce?: BounceWebhookTrigger;
|
7 | SpamComplaint?: SpamWebhookTrigger;
|
8 | SubscriptionChange?: WebhookTrigger;
|
9 | }
|
10 | export declare class UpdateWebhookRequest {
|
11 | Url?: string;
|
12 | HttpAuth?: HttpAuth;
|
13 | HttpHeaders?: Header[];
|
14 | Triggers?: WebhookRequestTriggers;
|
15 | constructor(url?: string, triggers?: WebhookRequestTriggers, httpAuth?: HttpAuth, httpHeaders?: Header[]);
|
16 | }
|
17 | export declare class CreateWebhookRequest extends UpdateWebhookRequest {
|
18 | MessageStream?: string;
|
19 | constructor(url?: string, triggers?: WebhookRequestTriggers, httpAuth?: HttpAuth, httpHeaders?: Header[], messageStream?: string);
|
20 | }
|
21 | export interface WebhookTrigger {
|
22 | Enabled: boolean;
|
23 | }
|
24 | export interface OpenWebhookTrigger extends WebhookTrigger {
|
25 | PostFirstOpenOnly?: boolean;
|
26 | }
|
27 | export interface BounceWebhookTrigger extends WebhookTrigger {
|
28 | IncludeContent?: boolean;
|
29 | }
|
30 | export interface SpamWebhookTrigger extends WebhookTrigger {
|
31 | IncludeContent?: boolean;
|
32 | }
|
33 | export interface HttpAuth {
|
34 | Username: string;
|
35 | Password: string;
|
36 | }
|
37 | export interface Webhook {
|
38 | ID: number;
|
39 | Url: string;
|
40 | HttpAuth?: HttpAuth;
|
41 | HttpHeaders?: Header[];
|
42 | MessageStream: string;
|
43 | Triggers: {
|
44 | Open: OpenWebhookTrigger;
|
45 | Click: WebhookTrigger;
|
46 | Delivery: WebhookTrigger;
|
47 | Bounce: BounceWebhookTrigger;
|
48 | SpamComplaint: SpamWebhookTrigger;
|
49 | SubscriptionChange: WebhookTrigger;
|
50 | };
|
51 | }
|