Custom metadata in AI Gateway allows you to tag requests with user IDs or other identifiers, enabling better tracking and analysis of your requests. Metadata values can be strings, numbers, or booleans, and will appear in your logs, making it easy to search and filter through your data.
Key Features
Custom Tagging: Add user IDs, team names, test indicators, and other relevant information to your requests.
Enhanced Logging: Metadata appears in your logs, allowing for detailed inspection and troubleshooting.
Search and Filter: Use metadata to efficiently search and filter through logged requests.
Supported Metadata Types
String
Number
Boolean
Implementations
Using cURL
To include custom metadata in your request using cURL:
Using SDK
To include custom metadata in your request using the OpenAI SDK:
Using Binding
To include custom metadata in your request using Bindings:
Was this helpful?
What did you like?
What went wrong?
Thank you for helping improve Cloudflare's documentation!