Interface BetaManagedAgentsSessionErrorEvent.Error.Visitor
-
- All Implemented Interfaces:
public interface BetaManagedAgentsSessionErrorEvent.Error.Visitor<T extends Object>
-
-
Method Summary
Modifier and Type Method Description abstract TvisitUnknown(BetaManagedAgentsUnknownError unknown)An unknown or unexpected error occurred during session execution. abstract TvisitModelOverloaded(BetaManagedAgentsModelOverloadedError modelOverloaded)The model is currently overloaded. abstract TvisitModelRateLimited(BetaManagedAgentsModelRateLimitedError modelRateLimited)The model request was rate-limited. abstract TvisitModelRequestFailed(BetaManagedAgentsModelRequestFailedError modelRequestFailed)A model request failed for a reason other than overload or rate-limiting. abstract TvisitMcpConnectionFailed(BetaManagedAgentsMcpConnectionFailedError mcpConnectionFailed)Failed to connect to an MCP server. abstract TvisitMcpAuthenticationFailed(BetaManagedAgentsMcpAuthenticationFailedError mcpAuthenticationFailed)Authentication to an MCP server failed. abstract TvisitBilling(BetaManagedAgentsBillingError billing)The caller's organization or workspace cannot make model requests — out of credits or spend limit reached. abstract TvisitCredentialHostUnreachable(BetaManagedAgentsCredentialHostUnreachableError credentialHostUnreachable)An environment_variablecredential'sauth.networking.allowed_hostsincludes a host the environment's network policy does not permit.abstract TvisitToolUseLimitReached(BetaManagedAgentsToolUseLimitReachedError toolUseLimitReached)The turn stopped because the agent loop reached its limit on tool-use rounds (one model response that calls tools, plus running those tools, is one round), not because a request failed. abstract TvisitCompactionLimitReached(BetaManagedAgentsCompactionLimitReachedError compactionLimitReached)The turn stopped because the context was compacted the maximum number of times in a row without the model producing a message or a tool call, not because a request failed. abstract TvisitRepositoryAuthentication(BetaManagedAgentsRepositoryAuthenticationError repositoryAuthentication)The repository host rejected the credentials, or required credentials and received none. abstract TvisitRepositoryForbidden(BetaManagedAgentsRepositoryForbiddenError repositoryForbidden)The repository host refused access to the repository. abstract TvisitRepositoryNotFound(BetaManagedAgentsRepositoryNotFoundError repositoryNotFound)The repository host reported the repository as not found. abstract TvisitRepositoryCheckout(BetaManagedAgentsRepositoryCheckoutError repositoryCheckout)The requested branch or commit does not exist in the repository. abstract TvisitRepositoryClone(BetaManagedAgentsRepositoryCloneError repositoryClone)The repository could not be cloned. Tunknown(JsonValue json)Maps an unknown variant of Error to a value of type T. -
-
Method Detail
-
visitUnknown
abstract T visitUnknown(BetaManagedAgentsUnknownError unknown)
An unknown or unexpected error occurred during session execution. A fallback variant; clients that don't recognize a new error code can match on
retry_statusandmessagealone.
-
visitModelOverloaded
abstract T visitModelOverloaded(BetaManagedAgentsModelOverloadedError modelOverloaded)
The model is currently overloaded. Emitted after automatic retries are exhausted.
-
visitModelRateLimited
abstract T visitModelRateLimited(BetaManagedAgentsModelRateLimitedError modelRateLimited)
The model request was rate-limited.
-
visitModelRequestFailed
abstract T visitModelRequestFailed(BetaManagedAgentsModelRequestFailedError modelRequestFailed)
A model request failed for a reason other than overload or rate-limiting.
-
visitMcpConnectionFailed
abstract T visitMcpConnectionFailed(BetaManagedAgentsMcpConnectionFailedError mcpConnectionFailed)
Failed to connect to an MCP server.
-
visitMcpAuthenticationFailed
abstract T visitMcpAuthenticationFailed(BetaManagedAgentsMcpAuthenticationFailedError mcpAuthenticationFailed)
Authentication to an MCP server failed.
-
visitBilling
abstract T visitBilling(BetaManagedAgentsBillingError billing)
The caller's organization or workspace cannot make model requests — out of credits or spend limit reached. Retrying with the same credentials will not succeed; the caller must resolve the billing state.
-
visitCredentialHostUnreachable
abstract T visitCredentialHostUnreachable(BetaManagedAgentsCredentialHostUnreachableError credentialHostUnreachable)
An
environment_variablecredential'sauth.networking.allowed_hostsincludes a host the environment's network policy does not permit.
-
visitToolUseLimitReached
abstract T visitToolUseLimitReached(BetaManagedAgentsToolUseLimitReachedError toolUseLimitReached)
The turn stopped because the agent loop reached its limit on tool-use rounds (one model response that calls tools, plus running those tools, is one round), not because a request failed. The thread goes idle with
stop_reason: retries_exhausted(a child thread then terminates); the nextuser.messagestarts a new turn.
-
visitCompactionLimitReached
abstract T visitCompactionLimitReached(BetaManagedAgentsCompactionLimitReachedError compactionLimitReached)
The turn stopped because the context was compacted the maximum number of times in a row without the model producing a message or a tool call, not because a request failed. The thread goes idle with
stop_reason: retries_exhausted(a child thread then terminates); the nextuser.messagestarts a new turn.
-
visitRepositoryAuthentication
abstract T visitRepositoryAuthentication(BetaManagedAgentsRepositoryAuthenticationError repositoryAuthentication)
The repository host rejected the credentials, or required credentials and received none.
-
visitRepositoryForbidden
abstract T visitRepositoryForbidden(BetaManagedAgentsRepositoryForbiddenError repositoryForbidden)
The repository host refused access to the repository.
-
visitRepositoryNotFound
abstract T visitRepositoryNotFound(BetaManagedAgentsRepositoryNotFoundError repositoryNotFound)
The repository host reported the repository as not found.
-
visitRepositoryCheckout
abstract T visitRepositoryCheckout(BetaManagedAgentsRepositoryCheckoutError repositoryCheckout)
The requested branch or commit does not exist in the repository.
-
visitRepositoryClone
abstract T visitRepositoryClone(BetaManagedAgentsRepositoryCloneError repositoryClone)
The repository could not be cloned.
-
unknown
T unknown(JsonValue json)
Maps an unknown variant of Error to a value of type T.
An instance of Error can contain an unknown variant if it was deserialized from data that doesn't match any known variant. For example, if the SDK is on an older version than the API, then the API may respond with new variants that the SDK is unaware of.
-
-
-
-