vendor_fabric.google.jules

Google Jules Connector - HTTP client for Google Jules AI Agent API.

Jules is Google’s AI coding agent that can analyze code, create PRs, and automate development tasks.

Usage: from vendor_fabric.google.jules import JulesConnector

connector = JulesConnector(api_key="...")

# List available sources (GitHub repos)
sources = connector.list_sources()

# Create a session
session = connector.create_session(
    prompt="Fix the login bug",
    source="sources/github/org/repo",
    automation_mode="AUTO_CREATE_PR"
)

# Poll for completion
status = connector.get_session(session["name"])

Reference: https://developers.google.com/jules/api

Module Contents

Classes

SessionState

Jules session states.

AutomationMode

Automation modes for Jules sessions.

Source

A connected source (e.g., GitHub repository).

SourceContext

Context for a session’s source.

PullRequestOutput

Pull request created by Jules.

Session

A Jules session.

JulesConnector

Connector for Google Jules AI Agent API.

API

class vendor_fabric.google.jules.SessionState

Bases: enum.StrEnum

Jules session states.

Initialization

Initialize self. See help(type(self)) for accurate signature.

UNSPECIFIED = 'SESSION_STATE_UNSPECIFIED'
RUNNING = 'RUNNING'
PAUSED = 'PAUSED'
COMPLETED = 'COMPLETED'
FAILED = 'FAILED'
AWAITING_PLAN_APPROVAL = 'AWAITING_PLAN_APPROVAL'
AWAITING_USER_RESPONSE = 'AWAITING_USER_RESPONSE'
CANCELLED = 'CANCELLED'
IN_PROGRESS = 'IN_PROGRESS'
PENDING = 'PENDING'
BLOCKED = 'BLOCKED'
capitalize()
casefold()
center()
count()
encode()
endswith()
expandtabs()
find()
format()
format_map()
index()
isalnum()
isalpha()
isascii()
isdecimal()
isdigit()
isidentifier()
islower()
isnumeric()
isprintable()
isspace()
istitle()
isupper()
join()
ljust()
lower()
lstrip()
partition()
removeprefix()
removesuffix()
replace()
rfind()
rindex()
rjust()
rpartition()
rsplit()
rstrip()
split()
splitlines()
startswith()
strip()
swapcase()
title()
translate()
upper()
zfill()
name()
value()
class vendor_fabric.google.jules.AutomationMode

Bases: enum.StrEnum

Automation modes for Jules sessions.

Initialization

Initialize self. See help(type(self)) for accurate signature.

UNSPECIFIED = 'AUTOMATION_MODE_UNSPECIFIED'
AUTO_CREATE_PR = 'AUTO_CREATE_PR'
MANUAL = 'MANUAL'
capitalize()
casefold()
center()
count()
encode()
endswith()
expandtabs()
find()
format()
format_map()
index()
isalnum()
isalpha()
isascii()
isdecimal()
isdigit()
isidentifier()
islower()
isnumeric()
isprintable()
isspace()
istitle()
isupper()
join()
ljust()
lower()
lstrip()
partition()
removeprefix()
removesuffix()
replace()
rfind()
rindex()
rjust()
rpartition()
rsplit()
rstrip()
split()
splitlines()
startswith()
strip()
swapcase()
title()
translate()
upper()
zfill()
name()
value()
class vendor_fabric.google.jules.Source(/, **data: Any)

Bases: pydantic.BaseModel

A connected source (e.g., GitHub repository).

Initialization

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

name: str = 'Field(...)'
id: str = 'Field(...)'
github_repo: dict[str, Any] | None = 'Field(...)'
model_config: ClassVar[pydantic.config.ConfigDict] = 'ConfigDict(...)'
classmethod model_fields() dict[str, pydantic.fields.FieldInfo]
classmethod model_computed_fields() dict[str, pydantic.fields.ComputedFieldInfo]
property model_extra: dict[str, Any] | None
property model_fields_set: set[str]
classmethod model_construct(_fields_set: set[str] | None = None, **values: Any) typing_extensions.Self
model_copy(*, update: collections.abc.Mapping[str, Any] | None = None, deep: bool = False) typing_extensions.Self
model_dump(*, mode: Literal[json, python] | str = 'python', include: pydantic.main.IncEx | None = None, exclude: pydantic.main.IncEx | None = None, context: Any | None = None, by_alias: bool | None = None, exclude_unset: bool = False, exclude_defaults: bool = False, exclude_none: bool = False, exclude_computed_fields: bool = False, round_trip: bool = False, warnings: bool | Literal[none, warn, error] = True, fallback: Callable[[Any], Any] | None = None, serialize_as_any: bool = False, polymorphic_serialization: bool | None = None) dict[str, Any]
model_dump_json(*, indent: int | None = None, ensure_ascii: bool = False, include: pydantic.main.IncEx | None = None, exclude: pydantic.main.IncEx | None = None, context: Any | None = None, by_alias: bool | None = None, exclude_unset: bool = False, exclude_defaults: bool = False, exclude_none: bool = False, exclude_computed_fields: bool = False, round_trip: bool = False, warnings: bool | Literal[none, warn, error] = True, fallback: Callable[[Any], Any] | None = None, serialize_as_any: bool = False, polymorphic_serialization: bool | None = None) str
classmethod model_json_schema(by_alias: bool = True, ref_template: str = DEFAULT_REF_TEMPLATE, schema_generator: type[pydantic.json_schema.GenerateJsonSchema] = GenerateJsonSchema, mode: pydantic.json_schema.JsonSchemaMode = 'validation', *, union_format: Literal[any_of, primitive_type_array] = 'any_of') dict[str, Any]
classmethod model_parametrized_name(params: tuple[type[Any], ...]) str
model_post_init(context: Any, /) None
classmethod model_rebuild(*, force: bool = False, raise_errors: bool = True, _parent_namespace_depth: int = 2, _types_namespace: pydantic._internal._namespace_utils.MappingNamespace | None = None) bool | None
classmethod model_validate(obj: Any, *, strict: bool | None = None, extra: pydantic.config.ExtraValues | None = None, from_attributes: bool | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) typing_extensions.Self
classmethod model_validate_json(json_data: str | bytes | bytearray, *, strict: bool | None = None, extra: pydantic.config.ExtraValues | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) typing_extensions.Self
classmethod model_validate_strings(obj: Any, *, strict: bool | None = None, extra: pydantic.config.ExtraValues | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) typing_extensions.Self
dict(*, include: pydantic.main.IncEx | None = None, exclude: pydantic.main.IncEx | None = None, by_alias: bool = False, exclude_unset: bool = False, exclude_defaults: bool = False, exclude_none: bool = False) Dict[str, Any]
json(*, include: pydantic.main.IncEx | None = None, exclude: pydantic.main.IncEx | None = None, by_alias: bool = False, exclude_unset: bool = False, exclude_defaults: bool = False, exclude_none: bool = False, encoder: Callable[[Any], Any] | None = PydanticUndefined, models_as_dict: bool = PydanticUndefined, **dumps_kwargs: Any) str
classmethod parse_obj(obj: Any) typing_extensions.Self
classmethod parse_raw(b: str | bytes, *, content_type: str | None = None, encoding: str = 'utf8', proto: pydantic.deprecated.parse.Protocol | None = None, allow_pickle: bool = False) typing_extensions.Self
classmethod parse_file(path: str | pathlib.Path, *, content_type: str | None = None, encoding: str = 'utf8', proto: pydantic.deprecated.parse.Protocol | None = None, allow_pickle: bool = False) typing_extensions.Self
classmethod from_orm(obj: Any) typing_extensions.Self
classmethod construct(_fields_set: set[str] | None = None, **values: Any) typing_extensions.Self
copy(*, include: pydantic._internal._utils.AbstractSetIntStr | pydantic._internal._utils.MappingIntStrAny | None = None, exclude: pydantic._internal._utils.AbstractSetIntStr | pydantic._internal._utils.MappingIntStrAny | None = None, update: Dict[str, Any] | None = None, deep: bool = False) typing_extensions.Self
classmethod schema(by_alias: bool = True, ref_template: str = DEFAULT_REF_TEMPLATE) Dict[str, Any]
classmethod schema_json(*, by_alias: bool = True, ref_template: str = DEFAULT_REF_TEMPLATE, **dumps_kwargs: Any) str
classmethod validate(value: Any) typing_extensions.Self
classmethod update_forward_refs(**localns: Any) None
class vendor_fabric.google.jules.SourceContext(/, **data: Any)

Bases: pydantic.BaseModel

Context for a session’s source.

Initialization

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

source: str = 'Field(...)'
github_repo_context: dict[str, Any] | None = 'Field(...)'
model_config: ClassVar[pydantic.config.ConfigDict] = 'ConfigDict(...)'
classmethod model_fields() dict[str, pydantic.fields.FieldInfo]
classmethod model_computed_fields() dict[str, pydantic.fields.ComputedFieldInfo]
property model_extra: dict[str, Any] | None
property model_fields_set: set[str]
classmethod model_construct(_fields_set: set[str] | None = None, **values: Any) typing_extensions.Self
model_copy(*, update: collections.abc.Mapping[str, Any] | None = None, deep: bool = False) typing_extensions.Self
model_dump(*, mode: Literal[json, python] | str = 'python', include: pydantic.main.IncEx | None = None, exclude: pydantic.main.IncEx | None = None, context: Any | None = None, by_alias: bool | None = None, exclude_unset: bool = False, exclude_defaults: bool = False, exclude_none: bool = False, exclude_computed_fields: bool = False, round_trip: bool = False, warnings: bool | Literal[none, warn, error] = True, fallback: Callable[[Any], Any] | None = None, serialize_as_any: bool = False, polymorphic_serialization: bool | None = None) dict[str, Any]
model_dump_json(*, indent: int | None = None, ensure_ascii: bool = False, include: pydantic.main.IncEx | None = None, exclude: pydantic.main.IncEx | None = None, context: Any | None = None, by_alias: bool | None = None, exclude_unset: bool = False, exclude_defaults: bool = False, exclude_none: bool = False, exclude_computed_fields: bool = False, round_trip: bool = False, warnings: bool | Literal[none, warn, error] = True, fallback: Callable[[Any], Any] | None = None, serialize_as_any: bool = False, polymorphic_serialization: bool | None = None) str
classmethod model_json_schema(by_alias: bool = True, ref_template: str = DEFAULT_REF_TEMPLATE, schema_generator: type[pydantic.json_schema.GenerateJsonSchema] = GenerateJsonSchema, mode: pydantic.json_schema.JsonSchemaMode = 'validation', *, union_format: Literal[any_of, primitive_type_array] = 'any_of') dict[str, Any]
classmethod model_parametrized_name(params: tuple[type[Any], ...]) str
model_post_init(context: Any, /) None
classmethod model_rebuild(*, force: bool = False, raise_errors: bool = True, _parent_namespace_depth: int = 2, _types_namespace: pydantic._internal._namespace_utils.MappingNamespace | None = None) bool | None
classmethod model_validate(obj: Any, *, strict: bool | None = None, extra: pydantic.config.ExtraValues | None = None, from_attributes: bool | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) typing_extensions.Self
classmethod model_validate_json(json_data: str | bytes | bytearray, *, strict: bool | None = None, extra: pydantic.config.ExtraValues | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) typing_extensions.Self
classmethod model_validate_strings(obj: Any, *, strict: bool | None = None, extra: pydantic.config.ExtraValues | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) typing_extensions.Self
dict(*, include: pydantic.main.IncEx | None = None, exclude: pydantic.main.IncEx | None = None, by_alias: bool = False, exclude_unset: bool = False, exclude_defaults: bool = False, exclude_none: bool = False) Dict[str, Any]
json(*, include: pydantic.main.IncEx | None = None, exclude: pydantic.main.IncEx | None = None, by_alias: bool = False, exclude_unset: bool = False, exclude_defaults: bool = False, exclude_none: bool = False, encoder: Callable[[Any], Any] | None = PydanticUndefined, models_as_dict: bool = PydanticUndefined, **dumps_kwargs: Any) str
classmethod parse_obj(obj: Any) typing_extensions.Self
classmethod parse_raw(b: str | bytes, *, content_type: str | None = None, encoding: str = 'utf8', proto: pydantic.deprecated.parse.Protocol | None = None, allow_pickle: bool = False) typing_extensions.Self
classmethod parse_file(path: str | pathlib.Path, *, content_type: str | None = None, encoding: str = 'utf8', proto: pydantic.deprecated.parse.Protocol | None = None, allow_pickle: bool = False) typing_extensions.Self
classmethod from_orm(obj: Any) typing_extensions.Self
classmethod construct(_fields_set: set[str] | None = None, **values: Any) typing_extensions.Self
copy(*, include: pydantic._internal._utils.AbstractSetIntStr | pydantic._internal._utils.MappingIntStrAny | None = None, exclude: pydantic._internal._utils.AbstractSetIntStr | pydantic._internal._utils.MappingIntStrAny | None = None, update: Dict[str, Any] | None = None, deep: bool = False) typing_extensions.Self
classmethod schema(by_alias: bool = True, ref_template: str = DEFAULT_REF_TEMPLATE) Dict[str, Any]
classmethod schema_json(*, by_alias: bool = True, ref_template: str = DEFAULT_REF_TEMPLATE, **dumps_kwargs: Any) str
classmethod validate(value: Any) typing_extensions.Self
classmethod update_forward_refs(**localns: Any) None
class vendor_fabric.google.jules.PullRequestOutput(/, **data: Any)

Bases: pydantic.BaseModel

Pull request created by Jules.

Initialization

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

url: str = 'Field(...)'
title: str = 'Field(...)'
description: str = 'Field(...)'
model_config: ClassVar[pydantic.config.ConfigDict] = 'ConfigDict(...)'
classmethod model_fields() dict[str, pydantic.fields.FieldInfo]
classmethod model_computed_fields() dict[str, pydantic.fields.ComputedFieldInfo]
property model_extra: dict[str, Any] | None
property model_fields_set: set[str]
classmethod model_construct(_fields_set: set[str] | None = None, **values: Any) typing_extensions.Self
model_copy(*, update: collections.abc.Mapping[str, Any] | None = None, deep: bool = False) typing_extensions.Self
model_dump(*, mode: Literal[json, python] | str = 'python', include: pydantic.main.IncEx | None = None, exclude: pydantic.main.IncEx | None = None, context: Any | None = None, by_alias: bool | None = None, exclude_unset: bool = False, exclude_defaults: bool = False, exclude_none: bool = False, exclude_computed_fields: bool = False, round_trip: bool = False, warnings: bool | Literal[none, warn, error] = True, fallback: Callable[[Any], Any] | None = None, serialize_as_any: bool = False, polymorphic_serialization: bool | None = None) dict[str, Any]
model_dump_json(*, indent: int | None = None, ensure_ascii: bool = False, include: pydantic.main.IncEx | None = None, exclude: pydantic.main.IncEx | None = None, context: Any | None = None, by_alias: bool | None = None, exclude_unset: bool = False, exclude_defaults: bool = False, exclude_none: bool = False, exclude_computed_fields: bool = False, round_trip: bool = False, warnings: bool | Literal[none, warn, error] = True, fallback: Callable[[Any], Any] | None = None, serialize_as_any: bool = False, polymorphic_serialization: bool | None = None) str
classmethod model_json_schema(by_alias: bool = True, ref_template: str = DEFAULT_REF_TEMPLATE, schema_generator: type[pydantic.json_schema.GenerateJsonSchema] = GenerateJsonSchema, mode: pydantic.json_schema.JsonSchemaMode = 'validation', *, union_format: Literal[any_of, primitive_type_array] = 'any_of') dict[str, Any]
classmethod model_parametrized_name(params: tuple[type[Any], ...]) str
model_post_init(context: Any, /) None
classmethod model_rebuild(*, force: bool = False, raise_errors: bool = True, _parent_namespace_depth: int = 2, _types_namespace: pydantic._internal._namespace_utils.MappingNamespace | None = None) bool | None
classmethod model_validate(obj: Any, *, strict: bool | None = None, extra: pydantic.config.ExtraValues | None = None, from_attributes: bool | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) typing_extensions.Self
classmethod model_validate_json(json_data: str | bytes | bytearray, *, strict: bool | None = None, extra: pydantic.config.ExtraValues | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) typing_extensions.Self
classmethod model_validate_strings(obj: Any, *, strict: bool | None = None, extra: pydantic.config.ExtraValues | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) typing_extensions.Self
dict(*, include: pydantic.main.IncEx | None = None, exclude: pydantic.main.IncEx | None = None, by_alias: bool = False, exclude_unset: bool = False, exclude_defaults: bool = False, exclude_none: bool = False) Dict[str, Any]
json(*, include: pydantic.main.IncEx | None = None, exclude: pydantic.main.IncEx | None = None, by_alias: bool = False, exclude_unset: bool = False, exclude_defaults: bool = False, exclude_none: bool = False, encoder: Callable[[Any], Any] | None = PydanticUndefined, models_as_dict: bool = PydanticUndefined, **dumps_kwargs: Any) str
classmethod parse_obj(obj: Any) typing_extensions.Self
classmethod parse_raw(b: str | bytes, *, content_type: str | None = None, encoding: str = 'utf8', proto: pydantic.deprecated.parse.Protocol | None = None, allow_pickle: bool = False) typing_extensions.Self
classmethod parse_file(path: str | pathlib.Path, *, content_type: str | None = None, encoding: str = 'utf8', proto: pydantic.deprecated.parse.Protocol | None = None, allow_pickle: bool = False) typing_extensions.Self
classmethod from_orm(obj: Any) typing_extensions.Self
classmethod construct(_fields_set: set[str] | None = None, **values: Any) typing_extensions.Self
copy(*, include: pydantic._internal._utils.AbstractSetIntStr | pydantic._internal._utils.MappingIntStrAny | None = None, exclude: pydantic._internal._utils.AbstractSetIntStr | pydantic._internal._utils.MappingIntStrAny | None = None, update: Dict[str, Any] | None = None, deep: bool = False) typing_extensions.Self
classmethod schema(by_alias: bool = True, ref_template: str = DEFAULT_REF_TEMPLATE) Dict[str, Any]
classmethod schema_json(*, by_alias: bool = True, ref_template: str = DEFAULT_REF_TEMPLATE, **dumps_kwargs: Any) str
classmethod validate(value: Any) typing_extensions.Self
classmethod update_forward_refs(**localns: Any) None
class vendor_fabric.google.jules.Session(/, **data: Any)

Bases: pydantic.BaseModel

A Jules session.

Initialization

Create a new model by parsing and validating input data from keyword arguments.

Raises [ValidationError][pydantic_core.ValidationError] if the input data cannot be validated to form a valid model.

self is explicitly positional-only to allow self as a field name.

model_config = None
name: str = 'Field(...)'
id: str = 'Field(...)'
title: str = 'Field(...)'
prompt: str = 'Field(...)'
state: str | None = 'Field(...)'
source_context: vendor_fabric.google.jules.SourceContext | None = 'Field(...)'
outputs: list[dict[str, Any]] = 'Field(...)'
property pull_request: vendor_fabric.google.jules.PullRequestOutput | None

Get the pull request output if available.

classmethod model_fields() dict[str, pydantic.fields.FieldInfo]
classmethod model_computed_fields() dict[str, pydantic.fields.ComputedFieldInfo]
property model_extra: dict[str, Any] | None
property model_fields_set: set[str]
classmethod model_construct(_fields_set: set[str] | None = None, **values: Any) typing_extensions.Self
model_copy(*, update: collections.abc.Mapping[str, Any] | None = None, deep: bool = False) typing_extensions.Self
model_dump(*, mode: Literal[json, python] | str = 'python', include: pydantic.main.IncEx | None = None, exclude: pydantic.main.IncEx | None = None, context: Any | None = None, by_alias: bool | None = None, exclude_unset: bool = False, exclude_defaults: bool = False, exclude_none: bool = False, exclude_computed_fields: bool = False, round_trip: bool = False, warnings: bool | Literal[none, warn, error] = True, fallback: Callable[[Any], Any] | None = None, serialize_as_any: bool = False, polymorphic_serialization: bool | None = None) dict[str, Any]
model_dump_json(*, indent: int | None = None, ensure_ascii: bool = False, include: pydantic.main.IncEx | None = None, exclude: pydantic.main.IncEx | None = None, context: Any | None = None, by_alias: bool | None = None, exclude_unset: bool = False, exclude_defaults: bool = False, exclude_none: bool = False, exclude_computed_fields: bool = False, round_trip: bool = False, warnings: bool | Literal[none, warn, error] = True, fallback: Callable[[Any], Any] | None = None, serialize_as_any: bool = False, polymorphic_serialization: bool | None = None) str
classmethod model_json_schema(by_alias: bool = True, ref_template: str = DEFAULT_REF_TEMPLATE, schema_generator: type[pydantic.json_schema.GenerateJsonSchema] = GenerateJsonSchema, mode: pydantic.json_schema.JsonSchemaMode = 'validation', *, union_format: Literal[any_of, primitive_type_array] = 'any_of') dict[str, Any]
classmethod model_parametrized_name(params: tuple[type[Any], ...]) str
model_post_init(context: Any, /) None
classmethod model_rebuild(*, force: bool = False, raise_errors: bool = True, _parent_namespace_depth: int = 2, _types_namespace: pydantic._internal._namespace_utils.MappingNamespace | None = None) bool | None
classmethod model_validate(obj: Any, *, strict: bool | None = None, extra: pydantic.config.ExtraValues | None = None, from_attributes: bool | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) typing_extensions.Self
classmethod model_validate_json(json_data: str | bytes | bytearray, *, strict: bool | None = None, extra: pydantic.config.ExtraValues | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) typing_extensions.Self
classmethod model_validate_strings(obj: Any, *, strict: bool | None = None, extra: pydantic.config.ExtraValues | None = None, context: Any | None = None, by_alias: bool | None = None, by_name: bool | None = None) typing_extensions.Self
dict(*, include: pydantic.main.IncEx | None = None, exclude: pydantic.main.IncEx | None = None, by_alias: bool = False, exclude_unset: bool = False, exclude_defaults: bool = False, exclude_none: bool = False) Dict[str, Any]
json(*, include: pydantic.main.IncEx | None = None, exclude: pydantic.main.IncEx | None = None, by_alias: bool = False, exclude_unset: bool = False, exclude_defaults: bool = False, exclude_none: bool = False, encoder: Callable[[Any], Any] | None = PydanticUndefined, models_as_dict: bool = PydanticUndefined, **dumps_kwargs: Any) str
classmethod parse_obj(obj: Any) typing_extensions.Self
classmethod parse_raw(b: str | bytes, *, content_type: str | None = None, encoding: str = 'utf8', proto: pydantic.deprecated.parse.Protocol | None = None, allow_pickle: bool = False) typing_extensions.Self
classmethod parse_file(path: str | pathlib.Path, *, content_type: str | None = None, encoding: str = 'utf8', proto: pydantic.deprecated.parse.Protocol | None = None, allow_pickle: bool = False) typing_extensions.Self
classmethod from_orm(obj: Any) typing_extensions.Self
classmethod construct(_fields_set: set[str] | None = None, **values: Any) typing_extensions.Self
copy(*, include: pydantic._internal._utils.AbstractSetIntStr | pydantic._internal._utils.MappingIntStrAny | None = None, exclude: pydantic._internal._utils.AbstractSetIntStr | pydantic._internal._utils.MappingIntStrAny | None = None, update: Dict[str, Any] | None = None, deep: bool = False) typing_extensions.Self
classmethod schema(by_alias: bool = True, ref_template: str = DEFAULT_REF_TEMPLATE) Dict[str, Any]
classmethod schema_json(*, by_alias: bool = True, ref_template: str = DEFAULT_REF_TEMPLATE, **dumps_kwargs: Any) str
classmethod validate(value: Any) typing_extensions.Self
classmethod update_forward_refs(**localns: Any) None
exception vendor_fabric.google.jules.JulesError(message: str, code: int = 0, details: Any = None)

Bases: Exception

Error from Jules API.

Initialization

Initialize self. See help(type(self)) for accurate signature.

add_note()
class args
with_traceback()
class vendor_fabric.google.jules.JulesConnector(api_key: str | None = None, base_url: str | None = None, timeout: float = 60.0, **kwargs: Any)

Bases: vendor_fabric.base.ConnectorBase

Connector for Google Jules AI Agent API.

Provides methods to interact with Jules for automated coding tasks.

Initialization

Initialize the Jules connector.

Args: api_key: Jules API key. Defaults to JULES_API_KEY env var. base_url: API base URL. Defaults to production. timeout: Request timeout in seconds. **kwargs: Extra arguments for base class.

BASE_URL = 'https://jules.googleapis.com/v1alpha'
API_KEY_ENV = 'JULES_API_KEY'
list_sources(page_size: int = 100, page_token: str = '') extended_data.containers.ExtendedList[extended_data.containers.ExtendedDict]

List available sources (connected GitHub repos).

Args: page_size: Maximum number of results. page_token: Pagination token.

Returns: List of Source objects.

create_session(prompt: str, source: str, title: str = '', starting_branch: str = 'main', automation_mode: str = 'AUTO_CREATE_PR', require_plan_approval: bool = False) extended_data.containers.ExtendedDict

Create a new Jules session.

Args: prompt: Task description for Jules. source: Source resource name (e.g., sources/github/org/repo). title: Optional session title. starting_branch: Git branch to start from. automation_mode: AUTO_CREATE_PR or MANUAL. require_plan_approval: Whether to require explicit plan approval.

Returns: Created Session object.

get_session(session_name: str) extended_data.containers.ExtendedDict

Get a session by name.

Args: session_name: Full resource name (e.g., sessions/123).

Returns: Session object with current state.

list_sessions(page_size: int = 20, page_token: str = '') extended_data.containers.ExtendedList[extended_data.containers.ExtendedDict]

List sessions.

Args: page_size: Maximum number of results. page_token: Pagination token.

Returns: List of Session objects.

approve_plan(session_name: str) extended_data.containers.ExtendedDict

Approve the plan for a session that requires approval.

Args: session_name: Full resource name.

Returns: Updated Session object.

add_user_response(session_name: str, message: str) extended_data.containers.ExtendedDict

Add a follow-up message to a session or resume it.

Note: The Jules API uses the :sendMessage endpoint with a required prompt body. The response body is empty on success, so this method fetches and returns the updated session.

Args: session_name: Full resource name. message: Optional user message.

Returns: Updated Session object.

resume_session(session_name: str, message: str) extended_data.containers.ExtendedDict

Resume a paused or awaiting session by sending a follow-up prompt.

Args: session_name: Full resource name. message: User prompt to send to the session.

Returns: Updated Session object.

CONNECTOR_CATEGORY: ClassVar[str] = 'external'
CONNECTOR_CAPABILITIES: ClassVar[tuple[str, ...]] = ()
TIMEOUT: ClassVar[float] = 300.0
MIN_REQUEST_INTERVAL: ClassVar[float] = 0.0
MAX_RETRIES: ClassVar[int] = 5
property api_key: str
property client: httpx.Client
close() None
request(method: str, endpoint: str, *, headers: dict[str, str] | None = None, **kwargs: Any) httpx.Response
decode_response(response: httpx.Response, *, suffix: str | None = None, as_extended: bool = True) Any
decode_response_file(response: httpx.Response, *, source: str | None = None, suffix: str | None = None, as_extended: bool = True, metadata: collections.abc.Mapping[str, Any] | None = None) extended_data.io.DataFile
extend_result(value: Any) Any
request_data(method: str, endpoint: str, *, headers: dict[str, str] | None = None, suffix: str | None = None, as_extended: bool = True, **kwargs: Any) Any
request_data_file(method: str, endpoint: str, *, headers: dict[str, str] | None = None, suffix: str | None = None, as_extended: bool = True, **kwargs: Any) extended_data.io.DataFile
request_workflow(method: str, endpoint: str, *, headers: dict[str, str] | None = None, suffix: str | None = None, as_extended: bool = True, **kwargs: Any) extended_data.workflows.DataWorkflow
get(endpoint: str, **kwargs: Any) httpx.Response
get_data(endpoint: str, *, suffix: str | None = None, as_extended: bool = True, **kwargs: Any) Any
get_workflow(endpoint: str, *, suffix: str | None = None, as_extended: bool = True, **kwargs: Any) extended_data.workflows.DataWorkflow
post(endpoint: str, **kwargs: Any) httpx.Response
post_data(endpoint: str, *, suffix: str | None = None, as_extended: bool = True, **kwargs: Any) Any
post_workflow(endpoint: str, *, suffix: str | None = None, as_extended: bool = True, **kwargs: Any) extended_data.workflows.DataWorkflow
put(endpoint: str, **kwargs: Any) httpx.Response
put_data(endpoint: str, *, suffix: str | None = None, as_extended: bool = True, **kwargs: Any) Any
put_workflow(endpoint: str, *, suffix: str | None = None, as_extended: bool = True, **kwargs: Any) extended_data.workflows.DataWorkflow
delete(endpoint: str, **kwargs: Any) httpx.Response
delete_data(endpoint: str, *, suffix: str | None = None, as_extended: bool = True, **kwargs: Any) Any
delete_workflow(endpoint: str, *, suffix: str | None = None, as_extended: bool = True, **kwargs: Any) extended_data.workflows.DataWorkflow
patch(endpoint: str, **kwargs: Any) httpx.Response
patch_data(endpoint: str, *, suffix: str | None = None, as_extended: bool = True, **kwargs: Any) Any
patch_workflow(endpoint: str, *, suffix: str | None = None, as_extended: bool = True, **kwargs: Any) extended_data.workflows.DataWorkflow
download(url: str, output_path: str) int
vendor_capabilities: ClassVar[dict[str, vendor_fabric.capabilities.CapabilitySpec]] = None
vendor_capability_methods: ClassVar[dict[str, str]] = None
get_input(k: str, default: Any | None = None, required: bool = False, is_bool: bool = False, is_integer: bool = False, is_float: bool = False, is_path: bool = False, is_datetime: bool = False, as_extended: bool = False) Any
decode_input(k: str, default: Any | None = None, required: bool = False, decode_from_json: bool = False, decode_from_yaml: bool = False, decode_from_base64: bool = False, allow_none: bool = True, as_extended: bool = False) Any
freeze_inputs() extended_data.containers.mappings.ExtendedDict
thaw_inputs() extended_data.containers.mappings.ExtendedDict
snapshot_inputs(*, frozen: bool = False) extended_data.containers.mappings.ExtendedDict
replace_inputs(new_inputs: collections.abc.Mapping[str, Any] | None, *, clear_frozen: bool = True) extended_data.containers.mappings.ExtendedDict
merge_inputs(new_inputs: collections.abc.Mapping[str, Any] | None) extended_data.containers.mappings.ExtendedDict
shift_inputs() extended_data.containers.mappings.ExtendedDict