An Integration is a connection from a SendGrid Marketing Campaign to a supported third-party application. Integrations with different external applications allow you to sync data and create a more cohesive cross-product data experience.
Currently, only Segment Integrations are supported. Segment Integrations allow you to customize and automate email event forwarding to your Segment account.
The Integrations API allows you to create, retrieve, update, and delete your Integrations.
This endpoint updates an existing Integration.
Bearer <<YOUR_API_KEY_HERE>>
The ID of the Integration you would like to update.
application/json
The third-party application you would like to forward your email events to.
Segment
The configurable filters for SendGrid to destination email event forwarding.
The properties of an Integration required to send events to a specific third-party application.
The nickname for the Integration.
Untitled Integration
Successful Operation
The unique ID of an Integration.
Your Twilio SendGrid account ID.
The configurable filters for SendGrid to destination email event forwarding.
The properties of an Integration required to send events to a specific third-party application.
The nickname for the Integration.
Untitled Integration
The third-party application you would like to forward your events to.
Segment
1const client = require("@sendgrid/client");2client.setApiKey(process.env.SENDGRID_API_KEY);34const id = "ZGkrHSypTsudrGkmdpJJ";5const data = {6label: "My New Segment Integration!",7};89const request = {10url: `/v3/marketing/integrations/${id}`,11method: "PATCH",12body: data,13};1415client16.request(request)17.then(([response, body]) => {18console.log(response.statusCode);19console.log(response.body);20})21.catch((error) => {22console.error(error);23});