ReqAnthropic.Environments (ReqAnthropic v0.2.1)

Copy Markdown View Source

The Managed Agents Environments API: configure container templates (packages, network policy) that sessions run inside.

{:ok, env} =
  ReqAnthropic.Environments.create(
    name: "python-data-analysis",
    config: %{
      type: "cloud",
      packages: %{pip: ["pandas", "numpy"]},
      networking: %{type: "limited", allow_package_managers: true}
    }
  )

Summary

Functions

Update an environment. Fields omitted from the payload preserve their existing values (per the Anthropic API's documented semantics).

Functions

create(opts)

@spec create(keyword()) ::
  {:ok, map()} | {:error, ReqAnthropic.Error.t() | Exception.t()}

delete(id, opts \\ [])

@spec delete(
  String.t(),
  keyword()
) :: {:ok, map()} | {:error, ReqAnthropic.Error.t() | Exception.t()}

get(id, opts \\ [])

@spec get(
  String.t(),
  keyword()
) :: {:ok, map()} | {:error, ReqAnthropic.Error.t() | Exception.t()}

list(opts \\ [])

@spec list(keyword()) ::
  {:ok, map()} | {:error, ReqAnthropic.Error.t() | Exception.t()}

update(id, opts)

@spec update(
  String.t(),
  keyword()
) :: {:ok, map()} | {:error, ReqAnthropic.Error.t() | Exception.t()}

Update an environment. Fields omitted from the payload preserve their existing values (per the Anthropic API's documented semantics).