langsmith.async_client.AsyncClient.create_presigned_feedback_token#
- async AsyncClient.create_presigned_feedback_token(run_id: UUID | str, feedback_key: str, *, expiration: datetime | timedelta | None = None, feedback_config: FeedbackConfig | None = None, feedback_id: UUID | str | None = None) FeedbackIngestToken[source]#
Create a pre-signed URL to send feedback data to.
This is useful for giving browser-based clients a way to upload feedback data directly to LangSmith without accessing the API key.
- Parameters:
run_id (UUID | str) –
feedback_key (str) –
expiration (datetime | timedelta | None) – The expiration time of the pre-signed URL. Either a datetime or a timedelta offset from now. Default to 3 hours.
feedback_config (FeedbackConfig | None) – FeedbackConfig or None. If creating a feedback_key for the first time, this defines how the metric should be interpreted, such as a continuous score (w/ optional bounds), or distribution over categorical values.
feedback_id (UUID | str | None) – The ID of the feedback to create. If not provided, a new feedback will be created.
- Returns:
The pre-signed URL for uploading feedback data.
- Return type: