Use LangSmith to record workflow, tool, or model runs with inputs, outputs, tags, metadata, and parent-child relationships. Create or update runs, retrieve a run, and attach feedback using the actions below.
Send run data to LangSmith to trace executions, attach metadata, and monitor workflow performance.
Forward a single run to LangSmith for ingestion.
Inputs and outputsParameter Type Required Description apiKeystring Yes LangSmith API key idstring No Unique run identifier namestring Yes Run name run_typestring Yes Run type (tool, chain, llm, retriever, embedding, prompt, parser) start_timestring No Run start time in ISO-8601 format end_timestring No Run end time in ISO-8601 format inputsjson No Inputs payload run_outputsjson No Outputs payload extrajson No Additional metadata (extra) tagsjson No Array of tag strings parent_run_idstring No Parent run ID trace_idstring No Trace ID session_idstring No Session ID session_namestring No Session name statusstring No Run status errorstring No Error details dotted_orderstring No Dotted order string eventsjson No Structured events array
Parameter Type Description acceptedboolean Whether the run was accepted for ingestion runIdstring Run identifier provided in the request messagestring Response message from LangSmith
Forward multiple runs to LangSmith in a single batch.
Parameter Type Required Description apiKeystring Yes LangSmith API key postjson No Array of new runs to ingest patchjson No Array of runs to update/patch
Parameter Type Description acceptedboolean Whether the batch was accepted for ingestion runIdsarray Run identifiers provided in the request messagestring Response message from LangSmith messagesarray Per-run response messages, when provided
Patch an existing LangSmith run with outputs, status, or timing once it completes.
Parameter Type Required Description apiKeystring Yes LangSmith API key runIdstring Yes ID of the run to update namestring No Corrected run name end_timestring No Run end time in ISO-8601 format outputsjson No Outputs payload extrajson No Additional metadata (extra) tagsjson No Array of tag strings statusstring No Run status errorstring No Error details eventsjson No Structured events array
No output fields are documented for this action.
Retrieve a single LangSmith run by ID.
Parameter Type Required Description apiKeystring Yes LangSmith API key runIdstring Yes ID of the run to retrieve
Parameter Type Description idstring Run ID runIdstring Run ID (alias of id, for consistency with other operations) namestring Run name runTypestring Run type (tool, chain, llm, retriever, embedding, prompt, parser) statusstring Run status startTimestring Run start time (ISO) endTimestring Run end time (ISO) inputsjson Run inputs payload outputsjson Run outputs payload errorstring Error details, if the run failed tagsarray Tags attached to the run sessionIdstring Project (session) ID the run belongs to traceIdstring Trace ID parentRunIdstring Parent run ID totalTokensnumber Total tokens consumed by the run totalCoststring Total cost of the run
Attach a score, correction, or comment to a LangSmith run.
Parameter Type Required Description apiKeystring Yes LangSmith API key runIdstring Yes ID of the run to attach feedback to keystring Yes Feedback metric name (e.g. "correctness", "user_score") scorenumber No Numeric score for the feedback metric valuestring No Categorical value for the feedback metric commentstring No Free-text comment explaining the feedback correctionjson No Corrected output for the run feedbackSourceTypestring No Origin of the feedback (api, app, or model)
Parameter Type Description idstring Feedback ID keystring Feedback metric name runIdstring ID of the run the feedback was attached to scorenumber Score recorded for the feedback valuestring Categorical value recorded for the feedback commentstring Comment recorded for the feedback createdAtstring When the feedback was created (ISO)