CPU.Notifications

<back to all web services

SendGridEvents

Requires Authentication
The following routes are available for this service:
POST/sendgridevents
"use strict";
export class SendGridEvent {
    /** @param {{sg_event_id?:string,sg_message_id?:string,email?:string,timestamp?:number,smtp_id?:string,event?:string,type?:string,category?:string[],reason?:string,status?:string,userAgent?:string,ip?:string,url?:string,url_offset?:string,sg_machine_open?:boolean,tls?:string,unique_args?:{ [index:string]: string; },custom_args?:{ [index:string]: string; },marketing_campaign_id?:string,marketing_campaign_name?:string,singlesend_id?:string,singlesend_name?:string,bounce_classification?:string}} [init] */
    constructor(init) { Object.assign(this, init) }
    /** @type {?string} */
    sg_event_id;
    /** @type {?string} */
    sg_message_id;
    /** @type {?string} */
    email;
    /** @type {number} */
    timestamp;
    /** @type {?string} */
    smtp_id;
    /** @type {?string} */
    event;
    /** @type {?string} */
    type;
    /** @type {?string[]} */
    category;
    /** @type {?string} */
    reason;
    /** @type {?string} */
    status;
    /** @type {?string} */
    userAgent;
    /** @type {?string} */
    ip;
    /** @type {?string} */
    url;
    /** @type {?string} */
    url_offset;
    /** @type {boolean} */
    sg_machine_open;
    /** @type {?string} */
    tls;
    /** @type {?{ [index:string]: string; }} */
    unique_args;
    /** @type {?{ [index:string]: string; }} */
    custom_args;
    /** @type {?string} */
    marketing_campaign_id;
    /** @type {?string} */
    marketing_campaign_name;
    /** @type {?string} */
    singlesend_id;
    /** @type {?string} */
    singlesend_name;
    /** @type {?string} */
    bounce_classification;
}
export class SendGridEvents extends Array {
    constructor(init) { super(init); Object.assign(this, init) }
}

JavaScript SendGridEvents DTOs

To override the Content-type in your clients, use the HTTP Accept Header, append the .csv suffix or ?format=csv

HTTP + CSV

The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.

POST /sendgridevents HTTP/1.1 
Host: cpmwebservices-t.clarkpud.com 
Accept: text/csv
Content-Type: text/csv
Content-Length: length

[]
HTTP/1.1 200 OK
Content-Type: text/csv
Content-Length: length

(string)