Index
All Classes and Interfaces|All Packages|Serialized Form
A
- a2aMock() - Static method in class org.mockserver.client.A2aMockBuilder
- a2aMock(String) - Static method in class org.mockserver.client.A2aMockBuilder
- A2aMockBuilder - Class in org.mockserver.client
- A2aMockBuilder.A2aSkillBuilder - Class in org.mockserver.client
- A2aMockBuilder.A2aTaskHandlerBuilder - Class in org.mockserver.client
- addBreakpoint(RequestDefinition, Set<BreakpointPhase>, BreakpointRequestHandler, BreakpointResponseHandler, BreakpointStreamFrameHandler) - Method in class org.mockserver.client.MockServerClient
-
Register a breakpoint matcher with request/response/stream-frame handlers.
- addBreakpoint(RequestDefinition, Set<BreakpointPhase>, BreakpointStreamFrameHandler) - Method in class org.mockserver.client.MockServerClient
-
Register a breakpoint matcher with a stream frame handler.
- addBreakpoint(RequestDefinition, BreakpointRequestHandler) - Method in class org.mockserver.client.MockServerClient
-
Register a breakpoint matcher with a single request handler (REQUEST phase only).
- addBreakpoint(RequestDefinition, BreakpointRequestHandler, BreakpointResponseHandler) - Method in class org.mockserver.client.MockServerClient
-
Register a breakpoint matcher with request and response handlers.
- addBreakpoint(RequestDefinition, BreakpointRequestHandler, BreakpointResponseHandler, BreakpointStreamFrameHandler, BreakpointPhase...) - Method in class org.mockserver.client.MockServerClient
-
Register a breakpoint matcher with varargs phases and all handlers.
- advanceClock(Duration) - Method in class org.mockserver.client.MockServerClient
-
Advance the MockServer clock by the specified duration.
- and() - Method in class org.mockserver.client.A2aMockBuilder.A2aSkillBuilder
- and() - Method in class org.mockserver.client.A2aMockBuilder.A2aTaskHandlerBuilder
- and() - Method in class org.mockserver.client.McpMockBuilder.McpPromptBuilder
- and() - Method in class org.mockserver.client.McpMockBuilder.McpResourceBuilder
- and() - Method in class org.mockserver.client.McpMockBuilder.McpToolBuilder
- andThen() - Method in class org.mockserver.client.TurnBuilder
-
Return to the parent conversation builder for chaining additional turns.
- applyTo(MockServerClient) - Method in class org.mockserver.client.A2aMockBuilder
- applyTo(MockServerClient) - Method in class org.mockserver.client.LlmConversationBuilder
-
Build all turn expectations and register them with the MockServerClient.
- applyTo(MockServerClient) - Method in class org.mockserver.client.LlmFailoverBuilder
-
Build and register all expectations with the MockServerClient.
- applyTo(MockServerClient) - Method in class org.mockserver.client.LlmMockBuilder
-
Build the expectation and register it with the MockServerClient.
- applyTo(MockServerClient) - Method in class org.mockserver.client.McpMockBuilder
- applyTo(MockServerClient) - Method in class org.mockserver.client.TurnBuilder
-
Shortcut: build and register all turns with the MockServerClient.
- asyncApiStatus() - Method in class org.mockserver.client.MockServerClient
-
Retrieve the current AsyncAPI mocking status including loaded spec info, active channels, and recorded messages.
B
- baseScenarioName(String) - Static method in class org.mockserver.client.LlmConversationBuilder
-
Extract the base scenario name (without isolation marker suffix) from a full scenario name.
- bind(Integer...) - Method in class org.mockserver.client.MockServerClient
-
Bind new ports to listen on
- BreakpointRequestHandler - Interface in org.mockserver.client
-
Handler invoked when a REQUEST-phase breakpoint is hit.
- BreakpointResponseHandler - Interface in org.mockserver.client
-
Handler invoked when a RESPONSE-phase breakpoint is hit.
- BreakpointStreamFrameHandler - Interface in org.mockserver.client
-
Handler invoked when a RESPONSE_STREAM or INBOUND_STREAM phase breakpoint is hit.
- build() - Method in class org.mockserver.client.A2aMockBuilder
- build() - Method in class org.mockserver.client.LlmConversationBuilder
-
Build all turn expectations without registering them.
- build() - Method in class org.mockserver.client.LlmFailoverBuilder
-
Build all expectations without registering them.
- build() - Method in class org.mockserver.client.LlmMockBuilder
-
Build the expectation without registering it.
- build() - Method in class org.mockserver.client.McpMockBuilder
C
- clear(String) - Method in class org.mockserver.client.MockServerClient
-
Clear all expectations and logs that match the expectation id
- clear(String, ClearType) - Method in class org.mockserver.client.MockServerClient
-
Clear expectations, logs or both that match the expectation id
- clear(ExpectationId) - Method in class org.mockserver.client.MockServerClient
-
Clear all expectations and logs that match the expectation id
- clear(ExpectationId, ClearType) - Method in class org.mockserver.client.MockServerClient
-
Clear expectations, logs or both that match the expectation id
- clear(RequestDefinition) - Method in class org.mockserver.client.MockServerClient
-
Clear all expectations and logs that match the request matcher
- clear(RequestDefinition, ClearType) - Method in class org.mockserver.client.MockServerClient
-
Clear expectations, logs or both that match the request matcher
- clearBreakpointMatchers() - Method in class org.mockserver.client.MockServerClient
-
Clear all registered breakpoint matchers.
- clearByNamespace(String) - Method in class org.mockserver.client.MockServerClient
-
Clear only the expectations belonging to a single namespace (tenant), leaving expectations in other namespaces and global (no-namespace) expectations intact.
- clearGrpcDescriptors() - Method in class org.mockserver.client.MockServerClient
- clearLoadScenarios() - Method in class org.mockserver.client.MockServerClient
-
Remove all registered load scenarios via
DELETE /mockserver/loadScenario. - clearServiceChaos() - Method in class org.mockserver.client.MockServerClient
-
Clear all service-scoped chaos profiles.
- ClientException - Exception in org.mockserver.client
- clockStatus() - Method in class org.mockserver.client.MockServerClient
-
Retrieve the current clock status including the current instant, epoch millis, and whether the clock is frozen.
- close() - Method in class org.mockserver.client.MockServerClient
- completion() - Static method in class org.mockserver.client.Llm
-
Creates a new Completion builder.
- contextPath() - Method in class org.mockserver.client.MockServerClient
- conversation() - Static method in class org.mockserver.client.Llm
-
Creates a new LlmConversationBuilder.
- conversation() - Static method in class org.mockserver.client.LlmConversationBuilder
-
Entry point for building a multi-turn LLM conversation mock.
- cookie(String) - Static method in class org.mockserver.client.Llm
-
Creates an IsolationSource that reads the isolation key from a cookie.
- crud(CrudExpectationsDefinition) - Method in class org.mockserver.client.MockServerClient
-
Register a CRUD simulation that auto-generates RESTful endpoints for a given base path.
- currentState() - Method in record class org.mockserver.client.MockServerClient.Scenario
-
Returns the value of the
currentStaterecord component.
D
- debugMismatch(RequestDefinition) - Method in class org.mockserver.client.MockServerClient
-
Analyze why a request does not match any active expectations, showing per-field match failures for each expectation.
- decodeIsolationSource(String) - Static method in class org.mockserver.client.LlmConversationBuilder
-
Decode the isolation source from a scenario name that contains the isolation marker.
- deleteLoadScenario(String) - Method in class org.mockserver.client.MockServerClient
-
Remove a single registered load scenario by name via
DELETE /mockserver/loadScenario/{name}.
E
- embedding() - Static method in class org.mockserver.client.Llm
-
Creates a new EmbeddingResponse builder.
- equals(Object) - Method in record class org.mockserver.client.MockServerClient.Scenario
-
Indicates whether some other object is "equal to" this one.
- error(HttpError) - Method in class org.mockserver.client.ForwardChainExpectation
-
Return error when expectation is matched
- ExpectationInitializer - Interface in org.mockserver.client.initialize
-
Deprecated.instead use org.mockserver.client.initialize.PluginExpectationInitializer or org.mockserver.server.initialize.ExpectationInitializer
F
- failWith(int) - Method in class org.mockserver.client.LlmFailoverBuilder
-
Add a single failure attempt returning the given HTTP status code with a default provider-plausible error body.
- failWith(int, int) - Method in class org.mockserver.client.LlmFailoverBuilder
-
Add
countconsecutive failure attempts returning the given HTTP status code with a default provider-plausible error body. - failWith(int, String) - Method in class org.mockserver.client.LlmFailoverBuilder
-
Add a single failure attempt returning the given HTTP status code with a custom error body.
- forward(ExpectationForwardCallback) - Method in class org.mockserver.client.ForwardChainExpectation
-
Call method on object locally or remotely (over web socket) to generate request to forward when expectation is matched
- forward(ExpectationForwardCallback, ExpectationForwardAndResponseCallback) - Method in class org.mockserver.client.ForwardChainExpectation
-
Call method on object locally or remotely (over web socket) to generate request to forward when expectation is matched
- forward(ExpectationForwardCallback, ExpectationForwardAndResponseCallback, Delay) - Method in class org.mockserver.client.ForwardChainExpectation
-
Call method on object locally or remotely (over web socket) to generate request to forward when expectation is matched
- forward(ExpectationForwardCallback, Delay) - Method in class org.mockserver.client.ForwardChainExpectation
-
Call method on object locally or remotely (over web socket) to generate request to forward when expectation is matched
- forward(HttpClassCallback) - Method in class org.mockserver.client.ForwardChainExpectation
-
Call method on local class in same JVM implementing ExpectationResponseCallback to generate request to forward when expectation is matched
- forward(HttpForward) - Method in class org.mockserver.client.ForwardChainExpectation
-
Forward request to the specified host and port when expectation is matched
- forward(HttpOverrideForwardedRequest) - Method in class org.mockserver.client.ForwardChainExpectation
-
Override fields, headers, and cookies etc in request being forwarded with specified fields, headers and cookies, etc in the specified request when expectation is matched
- forward(HttpTemplate) - Method in class org.mockserver.client.ForwardChainExpectation
-
Evaluate Velocity or JavaScript template to generate request to forward when expectation is matched
- ForwardChainExpectation - Class in org.mockserver.client
- forwardWithFallback(HttpForwardWithFallback) - Method in class org.mockserver.client.ForwardChainExpectation
-
Forward request to the upstream host and return a fallback response when the upstream returns a configured status code (default 5xx) or times out.
- freezeClock() - Method in class org.mockserver.client.MockServerClient
-
Freeze the MockServer clock at the current time.
- freezeClock(Instant) - Method in class org.mockserver.client.MockServerClient
-
Freeze the MockServer clock at the specified instant.
G
- getFailureCount() - Method in class org.mockserver.client.LlmFailoverBuilder
-
Returns the total number of failure attempts configured.
- getLoadScenario(String) - Method in class org.mockserver.client.MockServerClient
-
Retrieve a single registered load scenario by name via
GET /mockserver/loadScenario/{name}. - getPort() - Method in class org.mockserver.client.MockServerClient
H
- handle(HttpRequest) - Method in interface org.mockserver.client.BreakpointRequestHandler
-
Handle a paused request at the REQUEST breakpoint phase.
- handle(HttpRequest, HttpResponse) - Method in interface org.mockserver.client.BreakpointResponseHandler
-
Handle a paused response at the RESPONSE breakpoint phase.
- handle(PausedStreamFrameDTO) - Method in interface org.mockserver.client.BreakpointStreamFrameHandler
-
Handle a paused stream frame at the RESPONSE_STREAM or INBOUND_STREAM breakpoint phase.
- hashCode() - Method in record class org.mockserver.client.MockServerClient.Scenario
-
Returns a hash code value for this object.
- hasStarted() - Method in class org.mockserver.client.MockServerClient
-
Returns whether MockServer has started, if called after MockServer has been stopped this method will block for 5 seconds while confirming MockServer is not starting
- hasStarted(int, long, TimeUnit) - Method in class org.mockserver.client.MockServerClient
-
Returns whether server MockServer has started, by polling the MockServer a configurable amount of times
- hasStopped() - Method in class org.mockserver.client.MockServerClient
-
Returns whether MockServer has stopped, if called too quickly after starting MockServer this may return false because MockServer has not yet started, to ensure MockServer has started use hasStarted()
- hasStopped(int, long, TimeUnit) - Method in class org.mockserver.client.MockServerClient
-
Returns whether server MockServer has stopped, by polling the MockServer a configurable amount of times.
- header(String) - Static method in class org.mockserver.client.Llm
-
Creates an IsolationSource that reads the isolation key from an HTTP header.
I
- importExpectations(String) - Method in class org.mockserver.client.MockServerClient
-
Import one or more expectations from a JSON document into a running MockServer.
- importExpectationsFromFile(String) - Method in class org.mockserver.client.MockServerClient
-
Import one or more expectations from a JSON file into a running MockServer.
- initializeExpectations(MockServerClient) - Method in interface org.mockserver.client.initialize.ExpectationInitializer
-
Deprecated.
- initializeExpectations(MockServerClient) - Method in interface org.mockserver.client.initialize.PluginExpectationInitializer
- inputTokens(int) - Static method in class org.mockserver.client.Llm
-
Creates a Usage with the given input tokens.
- isolateBy(IsolationSource) - Method in class org.mockserver.client.LlmConversationBuilder
-
Set isolation source for per-session state.
- isRunning() - Method in class org.mockserver.client.MockServerClient
-
Deprecated.use hasStopped() or hasStarted() instead
- isRunning(int, long, TimeUnit) - Method in class org.mockserver.client.MockServerClient
-
Deprecated.use hasStopped() or hasStarted() instead
- isSecure() - Method in class org.mockserver.client.MockServerClient
J
- jitter(double) - Static method in class org.mockserver.client.Llm
-
Creates a StreamingPhysics with the given jitter.
L
- listBreakpointMatchers() - Method in class org.mockserver.client.MockServerClient
-
List all registered breakpoint matchers.
- Llm - Class in org.mockserver.client
-
Convenience re-exports of LLM model-class static factories so that users can write a single import:
- LlmConversationBuilder - Class in org.mockserver.client
-
Builder for multi-turn LLM conversation mocks with optional per-session isolation.
- llmFailover() - Static method in class org.mockserver.client.Llm
-
Creates a new LlmFailoverBuilder for scripting provider failover/retry scenarios.
- llmFailover() - Static method in class org.mockserver.client.LlmFailoverBuilder
-
Entry point for building an LLM failover scenario.
- LlmFailoverBuilder - Class in org.mockserver.client
-
Builder for LLM provider failover/retry test scenarios.
- llmMock(String) - Static method in class org.mockserver.client.LlmMockBuilder
-
Entry point for building an LLM mock expectation.
- LlmMockBuilder - Class in org.mockserver.client
-
Fluent builder for creating LLM mock expectations.
- loadAsyncApi(String) - Method in class org.mockserver.client.MockServerClient
-
Load an AsyncAPI spec into MockServer to start async messaging mocking.
- loadScenario(LoadScenario) - Method in class org.mockserver.client.MockServerClient
-
Register (load) a load-injection scenario into the load-scenario registry via
PUT /mockserver/loadScenario. - loadScenarios() - Method in class org.mockserver.client.MockServerClient
-
List all registered load scenarios via
GET /mockserver/loadScenario.
M
- matchingMessage(String) - Method in class org.mockserver.client.A2aMockBuilder.A2aTaskHandlerBuilder
- mcpMock() - Static method in class org.mockserver.client.McpMockBuilder
- mcpMock(String) - Static method in class org.mockserver.client.McpMockBuilder
- McpMockBuilder - Class in org.mockserver.client
- McpMockBuilder.McpPromptBuilder - Class in org.mockserver.client
- McpMockBuilder.McpResourceBuilder - Class in org.mockserver.client
- McpMockBuilder.McpToolBuilder - Class in org.mockserver.client
- mockOpenIdProvider() - Method in class org.mockserver.client.MockServerClient
-
Mock a complete OpenID Connect / OAuth2 identity provider with a single call, using the default configuration (issuer
http://localhost:1080, standard endpoint paths, RS256 signing). - mockOpenIdProvider(OidcProviderConfiguration) - Method in class org.mockserver.client.MockServerClient
-
Mock a complete OpenID Connect / OAuth2 identity provider with a single call.
- mockSamlProvider() - Method in class org.mockserver.client.MockServerClient
-
Stand up a complete mock SAML 2.0 Identity Provider with default settings: a metadata endpoint, an SP-initiated Web-Browser-SSO POST endpoint, and a Single-Logout endpoint, signed with a freshly generated self-signed RSA credential whose certificate is published in the metadata.
- mockSamlProvider(SamlProviderConfiguration) - Method in class org.mockserver.client.MockServerClient
-
Stand up a complete mock SAML 2.0 Identity Provider from the given configuration.
- mockScimProvider() - Method in class org.mockserver.client.MockServerClient
-
Register a mock SCIM 2.0 provider using the default configuration (base path
/scim/v2). - mockScimProvider(ScimProviderConfiguration) - Method in class org.mockserver.client.MockServerClient
-
Register a mock SCIM 2.0 provider that auto-generates a complete set of SCIM endpoints for the configured base path (default
/scim/v2). - MockServerClient - Class in org.mockserver.client
- MockServerClient(String, int) - Constructor for class org.mockserver.client.MockServerClient
-
Start the client communicating to a MockServer at the specified host and port for example:
- MockServerClient(String, int, String) - Constructor for class org.mockserver.client.MockServerClient
-
Start the client communicating to a MockServer at the specified host and port and contextPath for example:
- MockServerClient(ClientConfiguration, String, int) - Constructor for class org.mockserver.client.MockServerClient
-
Start the client communicating to a MockServer at the specified host and port for example:
- MockServerClient(ClientConfiguration, String, int, String) - Constructor for class org.mockserver.client.MockServerClient
-
Start the client communicating to a MockServer at the specified host and port and contextPath for example:
- MockServerClient(ClientConfiguration, CompletableFuture<Integer>) - Constructor for class org.mockserver.client.MockServerClient
-
Start the client communicating to a MockServer on localhost at the port specified with the Future
- MockServerClient(Configuration, String, int) - Constructor for class org.mockserver.client.MockServerClient
-
Start the client communicating to a MockServer at the specified host and port for example:
- MockServerClient(Configuration, String, int, String) - Constructor for class org.mockserver.client.MockServerClient
-
Start the client communicating to a MockServer at the specified host and port and contextPath for example:
- MockServerClient(Configuration, CompletableFuture<Integer>) - Constructor for class org.mockserver.client.MockServerClient
-
Start the client communicating to a MockServer on localhost at the port specified with the Future
- MockServerClient.Scenario - Record Class in org.mockserver.client
-
A scenario and its current state, as returned by the scenario control-plane endpoints.
- MockServerClient.ScenarioHandle - Class in org.mockserver.client
-
Typed handle that wraps the scenario control-plane endpoints for a single named scenario.
O
- onTaskSend() - Method in class org.mockserver.client.A2aMockBuilder
- openUI() - Method in class org.mockserver.client.MockServerClient
-
Launch UI and wait the default period to allow the UI to launch and start collecting logs, this ensures that the log are visible in the UI even if MockServer is shutdown by a test shutdown function, such as After, AfterClass, AfterAll, etc
- openUI(TimeUnit, long) - Method in class org.mockserver.client.MockServerClient
-
Launch UI and wait a specified period to allow the UI to launch and start collecting logs, this ensures that the log are visible in the UI even if MockServer is shutdown by a test shutdown function, such as After, AfterClass, AfterAll, etc
- org.mockserver.client - module org.mockserver.client
- org.mockserver.client - package org.mockserver.client
- org.mockserver.client.initialize - package org.mockserver.client.initialize
- outputTokens(int) - Static method in class org.mockserver.client.Llm
-
Creates a Usage with the given output tokens.
P
- PluginExpectationInitializer - Interface in org.mockserver.client.initialize
-
If the MockServer is started using the Maven Plugin a initializationClass property can be specified to initialize expectations, when the MockServer starts.
- portFuture - Variable in class org.mockserver.client.MockServerClient
Q
- queryParameter(String) - Static method in class org.mockserver.client.Llm
-
Creates an IsolationSource that reads the isolation key from a query parameter.
R
- remoteAddress() - Method in class org.mockserver.client.MockServerClient
- removeBreakpointMatcher(String) - Method in class org.mockserver.client.MockServerClient
-
Remove a breakpoint matcher by id.
- removeServiceChaos(String) - Method in class org.mockserver.client.MockServerClient
-
Remove the service-scoped chaos profile registered for the given host.
- replay(HttpRequest) - Method in class org.mockserver.client.MockServerClient
-
Replay a request to its upstream target and return the upstream response.
- reset() - Method in class org.mockserver.client.MockServerClient
-
Reset MockServer by clearing all expectations
- resetClock() - Method in class org.mockserver.client.MockServerClient
-
Reset the MockServer clock to real wall-clock time.
- respond(List<HttpResponse>) - Method in class org.mockserver.client.ForwardChainExpectation
-
Set a list of responses to cycle through sequentially when expectation is matched.
- respond(ExpectationResponseCallback) - Method in class org.mockserver.client.ForwardChainExpectation
-
Call method on object locally or remotely (over web socket) to generate response to return when expectation is matched
- respond(ExpectationResponseCallback, Delay) - Method in class org.mockserver.client.ForwardChainExpectation
-
Call method on object locally or remotely (over web socket) to generate response to return when expectation is matched
- respond(HttpClassCallback) - Method in class org.mockserver.client.ForwardChainExpectation
-
Call method on local class in same JVM implementing ExpectationResponseCallback to generate response to return when expectation is matched
- respond(HttpResponse) - Method in class org.mockserver.client.ForwardChainExpectation
-
Return response when expectation is matched
- respond(HttpTemplate) - Method in class org.mockserver.client.ForwardChainExpectation
-
Evaluate Velocity or JavaScript template to generate response to return when expectation is matched
- respondingWith(String) - Method in class org.mockserver.client.A2aMockBuilder.A2aTaskHandlerBuilder
- respondingWith(String) - Method in class org.mockserver.client.McpMockBuilder.McpToolBuilder
- respondingWith(String, boolean) - Method in class org.mockserver.client.A2aMockBuilder.A2aTaskHandlerBuilder
- respondingWith(String, boolean) - Method in class org.mockserver.client.McpMockBuilder.McpToolBuilder
- respondingWith(String, String) - Method in class org.mockserver.client.McpMockBuilder.McpPromptBuilder
- respondingWith(Completion) - Method in class org.mockserver.client.LlmMockBuilder
- respondingWith(Completion) - Method in class org.mockserver.client.TurnBuilder
-
Set the completion to return for this turn.
- respondingWith(EmbeddingResponse) - Method in class org.mockserver.client.LlmMockBuilder
- respondWithBinary(BinaryResponse) - Method in class org.mockserver.client.ForwardChainExpectation
- respondWithDns(DnsResponse) - Method in class org.mockserver.client.ForwardChainExpectation
- respondWithGrpcBidi(GrpcBidiResponse) - Method in class org.mockserver.client.ForwardChainExpectation
- respondWithGrpcStream(GrpcStreamResponse) - Method in class org.mockserver.client.ForwardChainExpectation
- respondWithLlm(HttpLlmResponse) - Method in class org.mockserver.client.ForwardChainExpectation
- respondWithSse(HttpSseResponse) - Method in class org.mockserver.client.ForwardChainExpectation
- respondWithWebSocket(HttpWebSocketResponse) - Method in class org.mockserver.client.ForwardChainExpectation
- retrieveActiveExpectations(RequestDefinition) - Method in class org.mockserver.client.MockServerClient
-
Retrieve the active expectations match the httpRequest parameter, use null for the parameter to retrieve all expectations
- retrieveActiveExpectations(RequestDefinition, String) - Method in class org.mockserver.client.MockServerClient
-
Retrieve the active expectations visible to a single namespace (tenant): the expectations registered under
namespaceplus all global (no-namespace) expectations. - retrieveActiveExpectations(RequestDefinition, Format) - Method in class org.mockserver.client.MockServerClient
-
Retrieve the active expectations match the httpRequest parameter, use null for the parameter to retrieve all expectations
- retrieveConfiguration() - Method in class org.mockserver.client.MockServerClient
- retrieveGrpcServices() - Method in class org.mockserver.client.MockServerClient
- retrieveLogEntries(RequestDefinition) - Method in class org.mockserver.client.MockServerClient
-
Retrieve log entries as typed objects that match the httpRequest parameter, use null for the parameter to retrieve all log entries.
- retrieveLogEntries(RequestDefinition, long, long) - Method in class org.mockserver.client.MockServerClient
-
Retrieve log entries as typed objects that match the httpRequest parameter, filtered to a time window.
- retrieveLogEntriesByCorrelationId(String) - Method in class org.mockserver.client.MockServerClient
-
Retrieve log entries as typed objects filtered by correlation ID.
- retrieveLogMessages(RequestDefinition) - Method in class org.mockserver.client.MockServerClient
-
Retrieve the logs associated to a specific requests, this shows all logs for expectation matching, verification, clearing, etc
- retrieveLogMessagesArray(RequestDefinition) - Method in class org.mockserver.client.MockServerClient
-
Retrieve the logs associated to a specific requests, this shows all logs for expectation matching, verification, clearing, etc
- retrieveLogsByCorrelationId(String) - Method in class org.mockserver.client.MockServerClient
-
Retrieve all log entries that share the specified correlationId.
- retrieveMetrics() - Method in class org.mockserver.client.MockServerClient
- retrieveRecordedExpectations(RequestDefinition) - Method in class org.mockserver.client.MockServerClient
-
Retrieve the request-response combinations that have been recorded as a list of expectations, only those that match the httpRequest parameter are returned, use null to retrieve all requests
- retrieveRecordedExpectations(RequestDefinition, Format) - Method in class org.mockserver.client.MockServerClient
-
Retrieve the request-response combinations that have been recorded as a list of expectations, only those that match the httpRequest parameter are returned, use null to retrieve all requests
- retrieveRecordedRequests(RequestDefinition) - Method in class org.mockserver.client.MockServerClient
-
Retrieve the recorded requests that match the httpRequest parameter, use null for the parameter to retrieve all requests
- retrieveRecordedRequests(RequestDefinition, Format) - Method in class org.mockserver.client.MockServerClient
-
Retrieve the recorded requests that match the httpRequest parameter, use null for the parameter to retrieve all requests
- retrieveRecordedRequestsAndResponses(RequestDefinition) - Method in class org.mockserver.client.MockServerClient
-
Retrieve the recorded requests and responses that match the httpRequest parameter, use null for the parameter to retrieve all requests and responses
- retrieveRecordedRequestsAndResponses(RequestDefinition, Format) - Method in class org.mockserver.client.MockServerClient
-
Retrieve the recorded requests that match the httpRequest parameter, use null for the parameter to retrieve all requests
- runLoadScenario(LoadScenario) - Method in class org.mockserver.client.MockServerClient
-
Convenience helper that registers the given scenario and then immediately starts it, combining
MockServerClient.loadScenario(LoadScenario)andMockServerClient.startLoadScenarios(String...).
S
- scenario(String) - Method in class org.mockserver.client.MockServerClient
-
Obtain a typed handle for inspecting and driving a stateful scenario by name.
- Scenario(String, String) - Constructor for record class org.mockserver.client.MockServerClient.Scenario
-
Creates an instance of a
Scenariorecord class. - scenarioName() - Method in record class org.mockserver.client.MockServerClient.Scenario
-
Returns the value of the
scenarioNamerecord component. - scenarios() - Method in class org.mockserver.client.MockServerClient
-
List every known scenario and its current state.
- sendExpectation(Expectation...) - Method in class org.mockserver.client.MockServerClient
-
Deprecated.this is deprecated due to unclear naming, use method upsert(Expectation... expectations) instead
- serviceChaosStatus() - Method in class org.mockserver.client.MockServerClient
-
Retrieve the current service-scoped chaos registrations as a JSON string (
{"services":{host: profile, ...}}). - set(String) - Method in class org.mockserver.client.MockServerClient.ScenarioHandle
-
Set this scenario's state via
PUT /mockserver/scenario/{name}. - set(String, Long, String) - Method in class org.mockserver.client.MockServerClient.ScenarioHandle
-
Set this scenario's state and optionally schedule a timed transition to
nextStateviaPUT /mockserver/scenario/{name}. - setProxyConfiguration(ProxyConfiguration) - Method in class org.mockserver.client.MockServerClient
-
Deprecated.use withProxyConfiguration which is more consistent with MockServer API style
- setRequestOverride(HttpRequest) - Method in class org.mockserver.client.MockServerClient
-
Deprecated.use withRequestOverride which is more consistent with MockServer API style
- setServiceChaos(String, HttpChaosProfile) - Method in class org.mockserver.client.MockServerClient
-
Register a service-scoped HTTP chaos profile for an upstream host.
- setServiceChaos(String, HttpChaosProfile, long) - Method in class org.mockserver.client.MockServerClient
-
Register a service-scoped HTTP chaos profile for an upstream host that auto-reverts after
ttlMillismilliseconds (a "dead-man's switch" so the chaos self-heals even ifMockServerClient.removeServiceChaos(String)/MockServerClient.clearServiceChaos()is never called). - startLoadScenarios(String...) - Method in class org.mockserver.client.MockServerClient
-
Start one or more previously-registered load scenarios by name via
PUT /mockserver/loadScenario/startwith body{"names":[...]}. - state() - Method in class org.mockserver.client.MockServerClient.ScenarioHandle
-
Get the current state of this scenario via
GET /mockserver/scenario/{name}. - stop() - Method in class org.mockserver.client.MockServerClient
-
Stop MockServer gracefully (only support for Netty version, not supported for WAR version)
- stop(boolean) - Method in class org.mockserver.client.MockServerClient
-
Stop MockServer gracefully (only support for Netty version, not supported for WAR version)
- stopAsync() - Method in class org.mockserver.client.MockServerClient
-
Stop MockServer gracefully (only support for Netty version, not supported for WAR version)
- stopLoadScenarios(String...) - Method in class org.mockserver.client.MockServerClient
-
Stop one or more running load scenarios via
PUT /mockserver/loadScenario/stop. - streamingPhysics() - Static method in class org.mockserver.client.Llm
-
Creates a new StreamingPhysics builder.
T
- thenRespondWith(Completion) - Method in class org.mockserver.client.LlmFailoverBuilder
-
Set the completion to return after all failures are exhausted.
- timeToFirstToken(long, TimeUnit) - Static method in class org.mockserver.client.Llm
-
Creates a Delay representing the time to first token.
- tokensPerSecond(int) - Static method in class org.mockserver.client.Llm
-
Creates a StreamingPhysics with the given tokens per second.
- toolUse(String) - Static method in class org.mockserver.client.Llm
-
Creates a new ToolUse builder.
- toString() - Method in record class org.mockserver.client.MockServerClient.Scenario
-
Returns a string representation of this record class.
- trigger(String) - Method in class org.mockserver.client.MockServerClient.ScenarioHandle
-
Externally trigger a state transition via
PUT /mockserver/scenario/{name}/trigger. - turn() - Method in class org.mockserver.client.LlmConversationBuilder
-
Start defining a new turn in the conversation.
- TurnBuilder - Class in org.mockserver.client
-
Sub-builder for configuring a single turn within an LLM conversation mock.
U
- updateConfiguration(String) - Method in class org.mockserver.client.MockServerClient
- uploadGrpcDescriptor(byte[]) - Method in class org.mockserver.client.MockServerClient
- upsert() - Method in class org.mockserver.client.ForwardChainExpectation
-
Submit the expectation to MockServer without setting any additional primary action.
- upsert(Expectation...) - Method in class org.mockserver.client.MockServerClient
-
Specify one or more expectations to be create, or updated (if the id matches).
- upsert(OpenAPIExpectation...) - Method in class org.mockserver.client.MockServerClient
-
Specify OpenAPI and operations and responses to create matchers and example responses
V
- verify(Integer, ExpectationId...) - Method in class org.mockserver.client.MockServerClient
-
Verify a list of requests have been sent in the order specified for example:
- verify(Integer, RequestDefinition...) - Method in class org.mockserver.client.MockServerClient
-
Verify a list of requests have been sent in the order specified for example:
- verify(String...) - Method in class org.mockserver.client.MockServerClient
-
Verify a list of requests have been sent in the order specified for example:
- verify(String, VerificationTimes) - Method in class org.mockserver.client.MockServerClient
-
Verify a request has been sent for example:
- verify(ExpectationId...) - Method in class org.mockserver.client.MockServerClient
-
Verify a list of requests have been sent in the order specified for example:
- verify(ExpectationId, VerificationTimes) - Method in class org.mockserver.client.MockServerClient
-
Verify a request has been sent for example:
- verify(ExpectationId, VerificationTimes, Integer) - Method in class org.mockserver.client.MockServerClient
-
Verify a request has been sent for example:
- verify(HttpResponse) - Method in class org.mockserver.client.MockServerClient
-
Verify a response has been recorded (matching any request), defaulting to at least once
- verify(HttpResponse, VerificationTimes) - Method in class org.mockserver.client.MockServerClient
-
Verify a response has been recorded (matching any request) for example:
- verify(RequestDefinition...) - Method in class org.mockserver.client.MockServerClient
-
Verify a list of requests have been sent in the order specified for example:
- verify(RequestDefinition, HttpResponse, VerificationTimes) - Method in class org.mockserver.client.MockServerClient
-
Verify a request-response pair has been recorded for example:
- verify(RequestDefinition, VerificationTimes) - Method in class org.mockserver.client.MockServerClient
-
Verify a request has been sent for example:
- verify(RequestDefinition, VerificationTimes, Integer) - Method in class org.mockserver.client.MockServerClient
-
Verify a request has been sent for example:
- verify(RequestDefinition, VerificationTimes, Duration) - Method in class org.mockserver.client.MockServerClient
-
Eventual verification: poll the event log, retrying the supplied verification until it passes or the timeout expires.
- verify(Verification) - Method in class org.mockserver.client.MockServerClient
-
Verify using a pre-built Verification object for advanced use cases such as request-response pair verification:
- verify(Verification, Duration) - Method in class org.mockserver.client.MockServerClient
-
Eventual verification: poll the event log, retrying the supplied
Verificationuntil it passes or the timeout expires. - verify(VerificationSequence) - Method in class org.mockserver.client.MockServerClient
-
Verify using a pre-built VerificationSequence object for advanced use cases such as request-response sequence verification:
- verifyAll(Verification...) - Method in class org.mockserver.client.MockServerClient
-
Verify multiple verifications, collecting all failures and throwing a single
AssertionErrorthat lists every mismatch. - verifyAsyncMessage(String) - Method in class org.mockserver.client.MockServerClient
-
Verify async messages recorded by subscribers against the given criteria.
- verifyNever(RequestDefinition, Duration) - Method in class org.mockserver.client.MockServerClient
-
Negative-within-timeout verification: assert that the supplied verification stays unsatisfied for the whole window.
- verifyNever(Verification, Duration) - Method in class org.mockserver.client.MockServerClient
-
Negative-within-timeout verification: assert that the supplied
Verificationstays unsatisfied for the whole window. - verifyZeroInteractions() - Method in class org.mockserver.client.MockServerClient
-
Verify no requests have been sent.
W
- when(RequestDefinition) - Method in class org.mockserver.client.MockServerClient
-
Specify an unlimited expectation that will respond regardless of the number of matching http for example:
- when(RequestDefinition, Times) - Method in class org.mockserver.client.MockServerClient
-
Specify a limited expectation that will respond a specified number of times when the http is matched
- when(RequestDefinition, Times, TimeToLive) - Method in class org.mockserver.client.MockServerClient
-
Specify a limited expectation that will respond a specified number of times when the http is matched
- when(RequestDefinition, Times, TimeToLive, Integer) - Method in class org.mockserver.client.MockServerClient
-
Specify a limited expectation that will respond a specified number of times when the http is matched and will be matched according to priority as follows:
- whenContainsToolResultFor(String) - Method in class org.mockserver.client.TurnBuilder
-
Match when the conversation contains a tool result for a prior call of the named tool.
- whenLatestMessageContains(String) - Method in class org.mockserver.client.TurnBuilder
-
Match when the latest message's text content contains the given substring.
- whenLatestMessageContains(Pattern) - Method in class org.mockserver.client.TurnBuilder
-
Deprecated.misleading name — this overload matches by regex, not substring. Use
TurnBuilder.whenLatestMessageMatches(Pattern). Retained for source compatibility; delegates towhenLatestMessageMatches. - whenLatestMessageMatches(Pattern) - Method in class org.mockserver.client.TurnBuilder
-
Match when the latest message's text content matches the given regex.
- whenLatestMessageRole(ParsedMessage.Role) - Method in class org.mockserver.client.TurnBuilder
-
Match when the latest message has the given role.
- whenSemanticMatch(String) - Method in class org.mockserver.client.TurnBuilder
-
Opt-in fuzzy semantic match: match when the latest message expresses the given intent, judged by a runtime LLM.
- whenTurnIndex(int) - Method in class org.mockserver.client.TurnBuilder
-
Match when the conversation has exactly
nassistant turns. - withAfterAction(AfterAction) - Method in class org.mockserver.client.ForwardChainExpectation
-
Set a single after-action to execute after the primary action completes
- withAfterActions(AfterAction...) - Method in class org.mockserver.client.ForwardChainExpectation
- withAgentCardPath(String) - Method in class org.mockserver.client.A2aMockBuilder
- withAgentDescription(String) - Method in class org.mockserver.client.A2aMockBuilder
- withAgentName(String) - Method in class org.mockserver.client.A2aMockBuilder
- withAgentUrl(String) - Method in class org.mockserver.client.A2aMockBuilder
- withAgentVersion(String) - Method in class org.mockserver.client.A2aMockBuilder
- withArgument(String, String, boolean) - Method in class org.mockserver.client.McpMockBuilder.McpPromptBuilder
- withBeforeAction(AfterAction) - Method in class org.mockserver.client.ForwardChainExpectation
-
Set a single before-action to execute before the primary action.
- withBeforeActions(AfterAction...) - Method in class org.mockserver.client.ForwardChainExpectation
- withChaos(HttpChaosProfile) - Method in class org.mockserver.client.ForwardChainExpectation
-
Set a declarative HTTP chaos/fault injection profile for this expectation.
- withChaos(LlmChaosProfile) - Method in class org.mockserver.client.TurnBuilder
-
Apply a fault/chaos profile to this turn's response (probabilistic errors, mid-stream truncation, malformed SSE) for resilience testing.
- withContent(String) - Method in class org.mockserver.client.McpMockBuilder.McpResourceBuilder
- withControlPlaneJWT(String) - Method in class org.mockserver.client.MockServerClient
-
Specify JWT to use for control plane authorisation
- withControlPlaneJWT(Supplier<String>) - Method in class org.mockserver.client.MockServerClient
-
Specify JWT supplier to use for control plane authorisation
- withCrossProtocolScenario(CrossProtocolScenario) - Method in class org.mockserver.client.ForwardChainExpectation
-
Add a single cross-protocol scenario correlation to this expectation.
- withCrossProtocolScenarios(List<CrossProtocolScenario>) - Method in class org.mockserver.client.ForwardChainExpectation
-
Set the list of cross-protocol scenario correlations for this expectation.
- withDefaultTaskResponse(String) - Method in class org.mockserver.client.A2aMockBuilder
- withDescription(String) - Method in class org.mockserver.client.A2aMockBuilder.A2aSkillBuilder
- withDescription(String) - Method in class org.mockserver.client.McpMockBuilder.McpPromptBuilder
- withDescription(String) - Method in class org.mockserver.client.McpMockBuilder.McpResourceBuilder
- withDescription(String) - Method in class org.mockserver.client.McpMockBuilder.McpToolBuilder
- withExample(String) - Method in class org.mockserver.client.A2aMockBuilder.A2aSkillBuilder
- withHttpResponses(List<HttpResponse>) - Method in class org.mockserver.client.ForwardChainExpectation
-
Set a list of responses for stateful / multi-response selection.
- withId(String) - Method in class org.mockserver.client.ForwardChainExpectation
-
Set id of this expectation which can be used to update this expectation later or for clearing or verifying by expectation id.
- withInputSchema(String) - Method in class org.mockserver.client.McpMockBuilder.McpToolBuilder
- withMimeType(String) - Method in class org.mockserver.client.McpMockBuilder.McpResourceBuilder
- withModel(String) - Method in class org.mockserver.client.LlmConversationBuilder
- withModel(String) - Method in class org.mockserver.client.LlmFailoverBuilder
-
Set the model name for the success response.
- withModel(String) - Method in class org.mockserver.client.LlmMockBuilder
- withName(String) - Method in class org.mockserver.client.A2aMockBuilder.A2aSkillBuilder
- withName(String) - Method in class org.mockserver.client.McpMockBuilder.McpResourceBuilder
- withNewScenarioState(String) - Method in class org.mockserver.client.ForwardChainExpectation
- withNormalization(NormalizationOptions) - Method in class org.mockserver.client.TurnBuilder
-
Apply opt-in prompt normalisation before the
whenLatestMessage…text predicates are evaluated, so cosmetic differences (whitespace, JSON key ordering, volatile ids/timestamps) do not block a match. - withPath(String) - Method in class org.mockserver.client.LlmConversationBuilder
- withPath(String) - Method in class org.mockserver.client.LlmFailoverBuilder
-
Set the request path to match (e.g.
- withPercentage(Integer) - Method in class org.mockserver.client.ForwardChainExpectation
-
Set percentage of requests this expectation should match (0-100).
- withPriority(int) - Method in class org.mockserver.client.ForwardChainExpectation
-
Set priority of this expectation which is used to determine the matching order of expectations when a request is received.
- withPrompt(String) - Method in class org.mockserver.client.McpMockBuilder
- withPromptsCapability() - Method in class org.mockserver.client.McpMockBuilder
- withProtocolVersion(String) - Method in class org.mockserver.client.McpMockBuilder
- withProvider(Provider) - Method in class org.mockserver.client.LlmConversationBuilder
- withProvider(Provider) - Method in class org.mockserver.client.LlmFailoverBuilder
-
Set the LLM provider for the success response encoding.
- withProvider(Provider) - Method in class org.mockserver.client.LlmMockBuilder
- withProxyConfiguration(ProxyConfiguration) - Method in class org.mockserver.client.MockServerClient
-
Configure communication to MockServer to go via a proxy
- withPushNotifications(String) - Method in class org.mockserver.client.A2aMockBuilder
-
Advertise and mock A2A push notifications.
- withRequestOverride(HttpRequest) - Method in class org.mockserver.client.MockServerClient
- withResource(String) - Method in class org.mockserver.client.McpMockBuilder
- withResourcesCapability() - Method in class org.mockserver.client.McpMockBuilder
- withResponseMode(ResponseMode) - Method in class org.mockserver.client.ForwardChainExpectation
- withResponseWeights(List<Integer>) - Method in class org.mockserver.client.ForwardChainExpectation
-
Set the relative weight of each response in
httpResponses(index-aligned), used whenResponseMode.WEIGHTEDselection is active. - withScenarioName(String) - Method in class org.mockserver.client.ForwardChainExpectation
-
Set the scenario name for stateful expectation matching
- withScenarioState(String) - Method in class org.mockserver.client.ForwardChainExpectation
- withSecure(boolean) - Method in class org.mockserver.client.MockServerClient
- withServerName(String) - Method in class org.mockserver.client.McpMockBuilder
- withServerVersion(String) - Method in class org.mockserver.client.McpMockBuilder
- withSkill(String) - Method in class org.mockserver.client.A2aMockBuilder
- withSteps(List<ExpectationStep>) - Method in class org.mockserver.client.ForwardChainExpectation
-
Set an ordered list of steps for this expectation.
- withSteps(ExpectationStep...) - Method in class org.mockserver.client.ForwardChainExpectation
-
Set an ordered list of steps for this expectation.
- withStreaming() - Method in class org.mockserver.client.A2aMockBuilder
-
Advertise and mock the A2A streaming capability.
- withStreamingMethod(String) - Method in class org.mockserver.client.A2aMockBuilder
-
Override the JSON-RPC method that triggers the streaming response.
- withSwitchAfter(Integer) - Method in class org.mockserver.client.ForwardChainExpectation
-
Set the number of matches served by each response before advancing to the next, used when
ResponseMode.SWITCHselection is active (default 1). - withTag(String) - Method in class org.mockserver.client.A2aMockBuilder.A2aSkillBuilder
- withTool(String) - Method in class org.mockserver.client.McpMockBuilder
- withToolsCapability() - Method in class org.mockserver.client.McpMockBuilder
All Classes and Interfaces|All Packages|Serialized Form