Class BrowserStateBlockParam
-
- All Implemented Interfaces:
public final class BrowserStateBlockParamThe caller's browser state after a browser toolset member call — the full inventory of open tabs, which tab is active, and any side effects (tabs opened, download state changes) the call produced.
At most one per
tool_result, only on a non-error result answering a browser toolset membertool_use. The server renders the model-visible text from it; the model never sees the raw fields.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description public final classBrowserStateBlockParam.BuilderA builder for BrowserStateBlockParam.
-
Method Summary
Modifier and Type Method Description final List<BrowserStateTabEntry>tabs()All tabs open in the browser after this call — the full inventory, not a delta. final Optional<CacheControlEphemeral>cacheControl()Create a cache control breakpoint at this content block. final Optional<List<BrowserStateChange>>stateChanges()Tabs opened and download state changes during this call. final JsonValue_type()Expected to always return the following:
However, this method can be useful for debugging and logging (e.g.JsonValue.from("browser_state")final JsonField<List<BrowserStateTabEntry>>_tabs()Returns the raw JSON value of tabs. final JsonField<CacheControlEphemeral>_cacheControl()Returns the raw JSON value of cacheControl. final JsonField<List<BrowserStateChange>>_stateChanges()Returns the raw JSON value of stateChanges. final Map<String, JsonValue>_additionalProperties()final BrowserStateBlockParam.BuildertoBuilder()final BrowserStateBlockParamvalidate()Validates that the types of all values in this object match their expected types recursively. final BooleanisValid()Booleanequals(Object other)IntegerhashCode()StringtoString()final static BrowserStateBlockParam.Builderbuilder()Returns a mutable builder for constructing an instance of BrowserStateBlockParam. final static BrowserStateBlockParamof(List<BrowserStateTabEntry> tabs)Returns an immutable instance of BrowserStateBlockParam with the required tabs set to the given value. -
-
Method Detail
-
tabs
final List<BrowserStateTabEntry> tabs()
All tabs open in the browser after this call — the full inventory, not a delta. May be empty. Whenever non-empty, exactly one entry carries
active: true.
-
cacheControl
final Optional<CacheControlEphemeral> cacheControl()
Create a cache control breakpoint at this content block.
-
stateChanges
final Optional<List<BrowserStateChange>> stateChanges()
Tabs opened and download state changes during this call. "Nothing to report" is expressed by omitting the field, never by an empty list.
-
_type
final JsonValue _type()
Expected to always return the following:
JsonValue.from("browser_state")However, this method can be useful for debugging and logging (e.g. if the server responded with an unexpected value).
-
_tabs
final JsonField<List<BrowserStateTabEntry>> _tabs()
Returns the raw JSON value of tabs.
Unlike tabs, this method doesn't throw if the JSON field has an unexpected type.
-
_cacheControl
final JsonField<CacheControlEphemeral> _cacheControl()
Returns the raw JSON value of cacheControl.
Unlike cacheControl, this method doesn't throw if the JSON field has an unexpected type.
-
_stateChanges
final JsonField<List<BrowserStateChange>> _stateChanges()
Returns the raw JSON value of stateChanges.
Unlike stateChanges, this method doesn't throw if the JSON field has an unexpected type.
-
_additionalProperties
final Map<String, JsonValue> _additionalProperties()
-
toBuilder
final BrowserStateBlockParam.Builder toBuilder()
-
validate
final BrowserStateBlockParam validate()
Validates that the types of all values in this object match their expected types recursively.
This method is not forwards compatible with new types from the API for existing fields.
-
builder
final static BrowserStateBlockParam.Builder builder()
Returns a mutable builder for constructing an instance of BrowserStateBlockParam.
The following fields are required:
.tabs()
-
of
final static BrowserStateBlockParam of(List<BrowserStateTabEntry> tabs)
Returns an immutable instance of BrowserStateBlockParam with the required tabs set to the given value.
-
-
-
-