LangChain Reference home pageLangChain ReferenceLangChain Reference
  • GitHub
  • Main Docs
Deep Agents
LangChain
LangGraph
Integrations
LangSmith
  • Overview
  • Client
  • AsyncClient
  • Run Helpers
  • Run Trees
  • Evaluation
  • Schemas
  • Utilities
  • Wrappers
  • Anonymizer
  • Testing
  • Expect API
  • Middleware
  • Pytest Plugin
  • Deployment SDK
⌘I

LangChain Assistant

Ask a question to get started

Enter to send•Shift+Enter new line

Menu

OverviewClientAsyncClientRun HelpersRun TreesEvaluationSchemasUtilitiesWrappersAnonymizerTestingExpect APIMiddlewarePytest PluginDeployment SDK
Language
Theme
Pythonlangsmithresourcesprompt_webhooksPromptWebhooksResourcetest
Methodā—Since v0.14

test

Copy
test(
  self,
  *,
  payload: prompt_webhook_test_params.Payload,
  webhook: prompt_webhook_test_params.Webhook,
  extra_headers:

Used in Docs

  • How to run evaluations with pytest
View source on GitHub
Headers
|
None
=
None
,
extra_query
:
Query
|
None
=
None
,
extra_body
:
Body
|
None
=
None
,
timeout
:
float
|
httpx
.
Timeout
|
None
|
NotGiven
=
not_given
)
->
PromptWebhookTestResponse

Parameters

NameTypeDescription
webhook*prompt_webhook_test_params.Webhook

Base schema for prompt webhooks.

extra_headersHeaders | None
Default:None

Send extra headers

extra_queryQuery | None
Default:None

Add additional query parameters to the request

extra_bodyBody | None
Default:None
timeoutfloat | httpx.Timeout | None | NotGiven
Default:not_given

Test a specific prompt webhook.

Sends the sample payload to the webhook configuration in the request body without saving it, but only if the webhook's triggers include the payload's event and its prompt filters match the payload's prompt. Otherwise nothing is sent. Fails if the destination does not accept the payload.

Add additional JSON properties to the request

Override the client-level default timeout for this request, in seconds