Class A2AClientInvalidArgsError

All Implemented Interfaces:
Serializable

public class A2AClientInvalidArgsError extends A2AClientError
Client exception indicating invalid arguments provided to a client operation.

This exception is thrown when parameters passed to A2A client SDK methods fail validation. This is distinct from InvalidParamsError, which represents server-side parameter validation errors.

Common scenarios:

  • Null values for required parameters
  • Invalid parameter combinations
  • Parameter values outside acceptable ranges
  • Malformed URIs or identifiers

Usage example:


 if (agentUrl == null || agentUrl.isEmpty()) {
     throw new A2AClientInvalidArgsError("agentUrl cannot be null or empty");
 }
 
See Also:
  • Constructor Details

    • A2AClientInvalidArgsError

      public A2AClientInvalidArgsError()
      Creates a new invalid arguments error with no message.
    • A2AClientInvalidArgsError

      public A2AClientInvalidArgsError(String message)
      Creates a new invalid arguments error with the specified message.
      Parameters:
      message - the error message
    • A2AClientInvalidArgsError

      public A2AClientInvalidArgsError(String message, Throwable cause)
      Creates a new invalid arguments error with the specified message and cause.
      Parameters:
      message - the error message
      cause - the underlying cause