header('X-API-SECURITY') && $request->header('X-API-SECURITY') == config('postmark.secret')) { } } // { // "RecordType": "Delivery", // "ServerID": 23, // "MessageStream": "outbound", // "MessageID": "00000000-0000-0000-0000-000000000000", // "Recipient": "john@example.com", // "Tag": "welcome-email", // "DeliveredAt": "2021-02-21T16:34:52Z", // "Details": "Test delivery webhook details", // "Metadata": { // "example": "value", // "example_2": "value" // } // } private function processDelivery($request) { } // { // "Metadata": { // "example": "value", // "example_2": "value" // }, // "RecordType": "Bounce", // "ID": 42, // "Type": "HardBounce", // "TypeCode": 1, // "Name": "Hard bounce", // "Tag": "Test", // "MessageID": "00000000-0000-0000-0000-000000000000", // "ServerID": 1234, // "MessageStream": "outbound", // "Description": "The server was unable to deliver your message (ex: unknown user, mailbox not found).", // "Details": "Test bounce details", // "Email": "john@example.com", // "From": "sender@example.com", // "BouncedAt": "2021-02-21T16:34:52Z", // "DumpAvailable": true, // "Inactive": true, // "CanActivate": true, // "Subject": "Test subject", // "Content": "Test content" // } private function processBounce($request) { } // { // "Metadata": { // "example": "value", // "example_2": "value" // }, // "RecordType": "SpamComplaint", // "ID": 42, // "Type": "SpamComplaint", // "TypeCode": 100001, // "Name": "Spam complaint", // "Tag": "Test", // "MessageID": "00000000-0000-0000-0000-000000000000", // "ServerID": 1234, // "MessageStream": "outbound", // "Description": "The subscriber explicitly marked this message as spam.", // "Details": "Test spam complaint details", // "Email": "john@example.com", // "From": "sender@example.com", // "BouncedAt": "2021-02-21T16:34:52Z", // "DumpAvailable": true, // "Inactive": true, // "CanActivate": false, // "Subject": "Test subject", // "Content": "Test content" // } private function processSpamComplaint($request) { } }