You can add drains to your project by following the configuration steps below. When you configure the destination, choose between sending data to a custom HTTP endpoint and using a native integration or an external integration to send your data to popular services.
Teams on Pro and Enterprise plans can configure drains to forward observability data. You can send logs, traces, speed insights, and analytics data to a custom HTTP endpoint or use integrations from the Vercel Marketplace to send logs and traces data to popular services.
Select the type of observability data you want to drain:
Logs: Runtime, build and static logs from your deployments
Traces: Distributed tracing data using OpenTelemetry Protocol
Speed Insights: Performance metrics and web vitals
Web Analytics: Page views and custom events
At any time, you can also add an external integration to available connectable account log drain integrations by clicking the External Integrations link on the top right of the Add Drain side bar.
Configure a custom HTTP endpoint to receive drain data for any data type.
Endpoint URL
This is the URL of the endpoint we will send your data to. The request will be sent over HTTPS using the POST method. Make sure your endpoint responds with a 200 OK status code.
Format
Choose the delivery format based on your data type:
Native integrations are available for log and traces data. You have 2 options:
Installed Products
If you've already installed a marketplace integration product that supports drains, you can select it here. The integration will handle endpoint configuration automatically.
Available Products
Browse and install available product integrations for this drain type:
Click Install on any available product. This opens the Marketplace integration creation page in a new window.
Update the default product name if needed and select a subscription plan
Click Create and click Done once the integration has been created
Go back to the Project's settings Drains page and select your newly created integration
You can also add a Drain from your team's Integrations tab
Select the installed integration from the list. (Trace data shows under "Observability" and log data shows under "Logging")
Click Manage and select your installed product
Under Drains, click Add Drain
Configure which project you would like to send data from and click Create Drain
Once you have configured all settings, click Create Drain. If you configured a custom endpoint, it will be tested automatically when you create the drain. Vercel will immediately start forwarding data based on your configuration.
You can test your endpoint anytime by clicking the Test button to ensure it receives the data correctly.
Vercel automatically correlates logs with distributed traces when using OpenTelemetry. Any logs generated during traced requests are enriched with correlation identifiers:
traceId - The trace identifier
spanId - The span identifier
This correlation happens automatically without code changes. For example, this log:
From the Vercel dashboard, go to Team Settings > Drains and click Add Drain.
Click the External Integrations link on the top right of the Add Drain side modal.
From the External Integration Log Drains modal, select the installed or available external integration you would like to use and follow the steps to create the drain to that service.
Occasionally your drain endpoints can return an error. If more than 80% of drain deliveries fail or the number of failures exceed 50 for the past hour, we will send a notification email and indicate the error status on your Drains page.