# Agent Configs

## Create Agent Config

`client.AgentConfigs.New(ctx, body) (*AgentConfigNewResponse, error)`

**post** `/v5/agent_configs`

Create a reusable agent configuration (system prompt, harness, model, allowed tools) under the caller's account.

The config is a template that a chat session or a non-chat trigger later turns
into task params; creating one does not start any task. `persistent_workspace`
opts tasks made from this config into a durable `/workspace` that survives
sandbox death (off by default, and fixed once a task starts), and `repos`
overrides which repositories provisioning clones into that workspace — omit it
(null) to use the deployment default, or pass an empty list to clone nothing.
A `repos` override is rejected with a 422 on the model-agnostic (litellm)
harness unless `persistent_workspace` is also true, because non-persistent
litellm tasks run in a pre-cloned warm-pool sandbox where the override would be
ignored. `allowed_tools` may name MCP servers (Slack, Linear, GitHub, ...)
alongside harness tools, and granting an MCP server name authorizes every tool
it exposes.

### Parameters

- `body AgentConfigNewParams`

  - `Harness param.Field[AgentConfigNewParamsHarness]`

    Harness strategy. See Harness enum for supported values.

    - `const AgentConfigNewParamsHarnessClaudeCode AgentConfigNewParamsHarness = "claude-code"`

    - `const AgentConfigNewParamsHarnessCodex AgentConfigNewParamsHarness = "codex"`

    - `const AgentConfigNewParamsHarnessLitellm AgentConfigNewParamsHarness = "litellm"`

  - `Model param.Field[string]`

  - `Name param.Field[string]`

  - `SystemPrompt param.Field[string]`

  - `AllowedTools param.Field[[]string]`

    Tools enabled for this config. See AllowedTool enum for the catalogue.

    - `const AgentConfigNewParamsAllowedToolRead AgentConfigNewParamsAllowedTool = "Read"`

    - `const AgentConfigNewParamsAllowedToolWrite AgentConfigNewParamsAllowedTool = "Write"`

    - `const AgentConfigNewParamsAllowedToolEdit AgentConfigNewParamsAllowedTool = "Edit"`

    - `const AgentConfigNewParamsAllowedToolBash AgentConfigNewParamsAllowedTool = "Bash"`

    - `const AgentConfigNewParamsAllowedToolGlob AgentConfigNewParamsAllowedTool = "Glob"`

    - `const AgentConfigNewParamsAllowedToolGrep AgentConfigNewParamsAllowedTool = "Grep"`

    - `const AgentConfigNewParamsAllowedToolList AgentConfigNewParamsAllowedTool = "List"`

    - `const AgentConfigNewParamsAllowedToolWebFetch AgentConfigNewParamsAllowedTool = "WebFetch"`

    - `const AgentConfigNewParamsAllowedToolWebSearch AgentConfigNewParamsAllowedTool = "WebSearch"`

    - `const AgentConfigNewParamsAllowedToolTask AgentConfigNewParamsAllowedTool = "Task"`

    - `const AgentConfigNewParamsAllowedToolTodoWrite AgentConfigNewParamsAllowedTool = "TodoWrite"`

    - `const AgentConfigNewParamsAllowedToolNotebookEdit AgentConfigNewParamsAllowedTool = "NotebookEdit"`

    - `const AgentConfigNewParamsAllowedToolExitPlanMode AgentConfigNewParamsAllowedTool = "ExitPlanMode"`

    - `const AgentConfigNewParamsAllowedToolSlack AgentConfigNewParamsAllowedTool = "Slack"`

    - `const AgentConfigNewParamsAllowedToolLinear AgentConfigNewParamsAllowedTool = "Linear"`

    - `const AgentConfigNewParamsAllowedToolGitHub AgentConfigNewParamsAllowedTool = "GitHub"`

    - `const AgentConfigNewParamsAllowedToolConfluence AgentConfigNewParamsAllowedTool = "Confluence"`

    - `const AgentConfigNewParamsAllowedToolNotion AgentConfigNewParamsAllowedTool = "Notion"`

    - `const AgentConfigNewParamsAllowedToolDatadog AgentConfigNewParamsAllowedTool = "Datadog"`

    - `const AgentConfigNewParamsAllowedToolPagerDuty AgentConfigNewParamsAllowedTool = "PagerDuty"`

    - `const AgentConfigNewParamsAllowedToolSalesforce AgentConfigNewParamsAllowedTool = "Salesforce"`

    - `const AgentConfigNewParamsAllowedToolFigma AgentConfigNewParamsAllowedTool = "Figma"`

    - `const AgentConfigNewParamsAllowedToolGranola AgentConfigNewParamsAllowedTool = "Granola"`

    - `const AgentConfigNewParamsAllowedToolJira AgentConfigNewParamsAllowedTool = "Jira"`

    - `const AgentConfigNewParamsAllowedToolGmail AgentConfigNewParamsAllowedTool = "Gmail"`

    - `const AgentConfigNewParamsAllowedToolGoogleCalendar AgentConfigNewParamsAllowedTool = "GoogleCalendar"`

    - `const AgentConfigNewParamsAllowedToolGoogleDrive AgentConfigNewParamsAllowedTool = "GoogleDrive"`

    - `const AgentConfigNewParamsAllowedToolGoogleDocs AgentConfigNewParamsAllowedTool = "GoogleDocs"`

    - `const AgentConfigNewParamsAllowedToolGoogleSheets AgentConfigNewParamsAllowedTool = "GoogleSheets"`

    - `const AgentConfigNewParamsAllowedToolGoogleSlides AgentConfigNewParamsAllowedTool = "GoogleSlides"`

    - `const AgentConfigNewParamsAllowedToolSnowflake AgentConfigNewParamsAllowedTool = "Snowflake"`

    - `const AgentConfigNewParamsAllowedToolRedash AgentConfigNewParamsAllowedTool = "Redash"`

    - `const AgentConfigNewParamsAllowedToolTableau AgentConfigNewParamsAllowedTool = "Tableau"`

    - `const AgentConfigNewParamsAllowedToolMetabase AgentConfigNewParamsAllowedTool = "Metabase"`

    - `const AgentConfigNewParamsAllowedToolGong AgentConfigNewParamsAllowedTool = "Gong"`

    - `const AgentConfigNewParamsAllowedToolZoomInfo AgentConfigNewParamsAllowedTool = "ZoomInfo"`

    - `const AgentConfigNewParamsAllowedToolClay AgentConfigNewParamsAllowedTool = "Clay"`

  - `Description param.Field[string]`

  - `PersistentWorkspace param.Field[bool]`

    Give tasks a persistent /workspace that survives sandbox death. Fixed for a task's life; defaults off.

  - `Repos param.Field[[]RepoSpec]`

    Per-config repo override. None uses the deployment default; an empty list clones nothing.

    - `URL string`

    - `Depth int64`

    - `Path string`

### Returns

- `type AgentConfigNewResponse struct{…}`

  - `ID string`

  - `AllowedTools []string`

  - `CreatedAt Time`

  - `Harness string`

  - `Model string`

  - `Name string`

  - `SystemPrompt string`

  - `UpdatedAt Time`

  - `Description string`

  - `Object AgentConfigNewResponseObject`

    - `const AgentConfigNewResponseObjectAgentConfig AgentConfigNewResponseObject = "agent_config"`

  - `PersistentWorkspace bool`

  - `Repos []RepoSpec`

    - `URL string`

    - `Depth int64`

    - `Path string`

### Example

```go
package main

import (
  "context"
  "fmt"

  "github.com/scaleapi/sgp-dev-go"
  "github.com/scaleapi/sgp-dev-go/option"
)

func main() {
  client := sgpdev.NewClient(
    option.WithAPIKey("My API Key"),
    option.WithAccountID("My Account ID"),
  )
  agentConfig, err := client.AgentConfigs.New(context.TODO(), sgpdev.AgentConfigNewParams{
    Harness: sgpdev.AgentConfigNewParamsHarnessClaudeCode,
    Model: "x",
    Name: "x",
    SystemPrompt: "x",
  })
  if err != nil {
    panic(err.Error())
  }
  fmt.Printf("%+v\n", agentConfig.ID)
}
```

#### Response

```json
{
  "id": "id",
  "allowed_tools": [
    "string"
  ],
  "created_at": "2019-12-27T18:11:19.117Z",
  "harness": "harness",
  "model": "model",
  "name": "name",
  "system_prompt": "system_prompt",
  "updated_at": "2019-12-27T18:11:19.117Z",
  "description": "description",
  "object": "agent_config",
  "persistent_workspace": true,
  "repos": [
    {
      "url": "x",
      "depth": 1,
      "path": "path"
    }
  ]
}
```

## List Agent Configs

`client.AgentConfigs.List(ctx, query) (*CursorPage[AgentConfigListResponse], error)`

**get** `/v5/agent_configs`

List agent configurations visible to the caller, with cursor-based pagination.

A user caller sees only the configs they created unless fine-grained access
control (FGAC) grants them access to others; a service-account caller sees
every config under the account. This returns the stored config records as-is —
use `{agent_config_id}/resolve` instead when you need a config projected into
the params a task would run with. Because deleting a config removes it outright
rather than archiving it, there are no archived configs to page through here.

### Parameters

- `query AgentConfigListParams`

  - `EndingBefore param.Field[string]`

  - `Limit param.Field[int64]`

  - `SortBy param.Field[string]`

  - `SortOrder param.Field[SortOrder]`

  - `StartingAfter param.Field[string]`

### Returns

- `type AgentConfigListResponse struct{…}`

  - `ID string`

  - `AllowedTools []string`

  - `CreatedAt Time`

  - `Harness string`

  - `Model string`

  - `Name string`

  - `SystemPrompt string`

  - `UpdatedAt Time`

  - `Description string`

  - `Object AgentConfigListResponseObject`

    - `const AgentConfigListResponseObjectAgentConfig AgentConfigListResponseObject = "agent_config"`

  - `PersistentWorkspace bool`

  - `Repos []RepoSpec`

    - `URL string`

    - `Depth int64`

    - `Path string`

### Example

```go
package main

import (
  "context"
  "fmt"

  "github.com/scaleapi/sgp-dev-go"
  "github.com/scaleapi/sgp-dev-go/option"
)

func main() {
  client := sgpdev.NewClient(
    option.WithAPIKey("My API Key"),
    option.WithAccountID("My Account ID"),
  )
  page, err := client.AgentConfigs.List(context.TODO(), sgpdev.AgentConfigListParams{

  })
  if err != nil {
    panic(err.Error())
  }
  fmt.Printf("%+v\n", page)
}
```

#### Response

```json
{
  "has_more": true,
  "items": [
    {
      "id": "id",
      "allowed_tools": [
        "string"
      ],
      "created_at": "2019-12-27T18:11:19.117Z",
      "harness": "harness",
      "model": "model",
      "name": "name",
      "system_prompt": "system_prompt",
      "updated_at": "2019-12-27T18:11:19.117Z",
      "description": "description",
      "object": "agent_config",
      "persistent_workspace": true,
      "repos": [
        {
          "url": "x",
          "depth": 1,
          "path": "path"
        }
      ]
    }
  ],
  "total": 0,
  "limit": 0,
  "object": "list"
}
```

## List MCP Tool Names

`client.AgentConfigs.ListMcpTools(ctx) (*[]AgentConfigListMcpToolsResponse, error)`

**get** `/v5/agent_configs/mcp_tools`

Return the fixed set of tool names that route to MCP servers rather than harness-provided tools.

These are the subset of `allowed_tools` values (Slack, Linear, GitHub, ...)
the platform treats as MCP servers; the list is a static enum, not account
data, so it is identical for every caller. It is exposed mainly so the
generated SDK carries the `McpTool` type and the frontend can assert its own
MCP-versus-harness tool classifier against the backend to prevent drift. It
does not list configs or the tools actually granted to any particular config.

### Returns

- `type AgentConfigListMcpToolsResponse []AgentConfigListMcpToolsResponse`

  - `const AgentConfigListMcpToolsResponseSlack AgentConfigListMcpToolsResponse = "Slack"`

  - `const AgentConfigListMcpToolsResponseLinear AgentConfigListMcpToolsResponse = "Linear"`

  - `const AgentConfigListMcpToolsResponseGitHub AgentConfigListMcpToolsResponse = "GitHub"`

  - `const AgentConfigListMcpToolsResponseConfluence AgentConfigListMcpToolsResponse = "Confluence"`

  - `const AgentConfigListMcpToolsResponseNotion AgentConfigListMcpToolsResponse = "Notion"`

  - `const AgentConfigListMcpToolsResponseDatadog AgentConfigListMcpToolsResponse = "Datadog"`

  - `const AgentConfigListMcpToolsResponsePagerDuty AgentConfigListMcpToolsResponse = "PagerDuty"`

  - `const AgentConfigListMcpToolsResponseSalesforce AgentConfigListMcpToolsResponse = "Salesforce"`

  - `const AgentConfigListMcpToolsResponseFigma AgentConfigListMcpToolsResponse = "Figma"`

  - `const AgentConfigListMcpToolsResponseGranola AgentConfigListMcpToolsResponse = "Granola"`

  - `const AgentConfigListMcpToolsResponseJira AgentConfigListMcpToolsResponse = "Jira"`

  - `const AgentConfigListMcpToolsResponseGmail AgentConfigListMcpToolsResponse = "Gmail"`

  - `const AgentConfigListMcpToolsResponseGoogleCalendar AgentConfigListMcpToolsResponse = "GoogleCalendar"`

  - `const AgentConfigListMcpToolsResponseGoogleDrive AgentConfigListMcpToolsResponse = "GoogleDrive"`

  - `const AgentConfigListMcpToolsResponseGoogleDocs AgentConfigListMcpToolsResponse = "GoogleDocs"`

  - `const AgentConfigListMcpToolsResponseGoogleSheets AgentConfigListMcpToolsResponse = "GoogleSheets"`

  - `const AgentConfigListMcpToolsResponseGoogleSlides AgentConfigListMcpToolsResponse = "GoogleSlides"`

  - `const AgentConfigListMcpToolsResponseSnowflake AgentConfigListMcpToolsResponse = "Snowflake"`

  - `const AgentConfigListMcpToolsResponseRedash AgentConfigListMcpToolsResponse = "Redash"`

  - `const AgentConfigListMcpToolsResponseTableau AgentConfigListMcpToolsResponse = "Tableau"`

  - `const AgentConfigListMcpToolsResponseMetabase AgentConfigListMcpToolsResponse = "Metabase"`

  - `const AgentConfigListMcpToolsResponseGong AgentConfigListMcpToolsResponse = "Gong"`

  - `const AgentConfigListMcpToolsResponseZoomInfo AgentConfigListMcpToolsResponse = "ZoomInfo"`

  - `const AgentConfigListMcpToolsResponseClay AgentConfigListMcpToolsResponse = "Clay"`

### Example

```go
package main

import (
  "context"
  "fmt"

  "github.com/scaleapi/sgp-dev-go"
  "github.com/scaleapi/sgp-dev-go/option"
)

func main() {
  client := sgpdev.NewClient(
    option.WithAPIKey("My API Key"),
    option.WithAccountID("My Account ID"),
  )
  response, err := client.AgentConfigs.ListMcpTools(context.TODO())
  if err != nil {
    panic(err.Error())
  }
  fmt.Printf("%+v\n", response)
}
```

#### Response

```json
[
  "Slack"
]
```

## Get Agent Config

`client.AgentConfigs.Get(ctx, agentConfigID) (*AgentConfigGetResponse, error)`

**get** `/v5/agent_configs/{agent_config_id}`

Fetch a single stored agent configuration by id, including its `persistent_workspace` flag and any `repos` override.

This returns the saved record as-is and does not compute task params; use
`{agent_config_id}/resolve` when you need the config projected into the params
a task would run with. A user caller can only read a config they created unless
fine-grained access control grants access, while a service account can read any
config under the account; a missing or out-of-scope id returns a 404.

### Parameters

- `agentConfigID string`

### Returns

- `type AgentConfigGetResponse struct{…}`

  - `ID string`

  - `AllowedTools []string`

  - `CreatedAt Time`

  - `Harness string`

  - `Model string`

  - `Name string`

  - `SystemPrompt string`

  - `UpdatedAt Time`

  - `Description string`

  - `Object AgentConfigGetResponseObject`

    - `const AgentConfigGetResponseObjectAgentConfig AgentConfigGetResponseObject = "agent_config"`

  - `PersistentWorkspace bool`

  - `Repos []RepoSpec`

    - `URL string`

    - `Depth int64`

    - `Path string`

### Example

```go
package main

import (
  "context"
  "fmt"

  "github.com/scaleapi/sgp-dev-go"
  "github.com/scaleapi/sgp-dev-go/option"
)

func main() {
  client := sgpdev.NewClient(
    option.WithAPIKey("My API Key"),
    option.WithAccountID("My Account ID"),
  )
  agentConfig, err := client.AgentConfigs.Get(context.TODO(), "agent_config_id")
  if err != nil {
    panic(err.Error())
  }
  fmt.Printf("%+v\n", agentConfig.ID)
}
```

#### Response

```json
{
  "id": "id",
  "allowed_tools": [
    "string"
  ],
  "created_at": "2019-12-27T18:11:19.117Z",
  "harness": "harness",
  "model": "model",
  "name": "name",
  "system_prompt": "system_prompt",
  "updated_at": "2019-12-27T18:11:19.117Z",
  "description": "description",
  "object": "agent_config",
  "persistent_workspace": true,
  "repos": [
    {
      "url": "x",
      "depth": 1,
      "path": "path"
    }
  ]
}
```

## Update Agent Config

`client.AgentConfigs.Update(ctx, agentConfigID, params) (*AgentConfigUpdateResponse, error)`

**patch** `/v5/agent_configs/{agent_config_id}`

Partially update a stored agent config; only fields present in the request body are changed.

`persistent_workspace` and `repos` are both patchable — an explicit null on
`repos` clears the override back to the deployment default, while the
always-present fields (name, system_prompt, harness, allowed_tools, model, and
persistent_workspace) reject an explicit null. Because `persistent_workspace`
and `repos` are read when a task is created and are fixed for a task's life,
changing them affects only tasks created afterward, not one already running. The
optional `task_id` query parameter opts into a live-config side effect: after
the row is persisted, the changed pass-through fields (system_prompt, model,
harness, and allowed_tools split into harness tools versus MCP servers) are
shallow-merged into that running task's params on Agentex in a background task so
the worker picks them up on its next turn; `persistent_workspace` and `repos`
are intentionally not forwarded to a running task. That side effect runs after
the response is sent, is best-effort, and no-ops if the task does not exist or the
caller does not own it. A user caller can only update a config they created unless
fine-grained access control grants access.

### Parameters

- `agentConfigID string`

- `params AgentConfigUpdateParams`

  - `TaskID param.Field[string]`

    Query param: If set, after persisting the patch we shallow-merge the changed fields into this task's params column on Agentex so the worker picks up the new values on its next turn. Caller-provided context — Agentex enforces task ownership via its own auth, so the side-effect no-ops if the caller doesn't own the task.

  - `AllowedTools param.Field[[]string]`

    Body param

    - `const AgentConfigUpdateParamsAllowedToolRead AgentConfigUpdateParamsAllowedTool = "Read"`

    - `const AgentConfigUpdateParamsAllowedToolWrite AgentConfigUpdateParamsAllowedTool = "Write"`

    - `const AgentConfigUpdateParamsAllowedToolEdit AgentConfigUpdateParamsAllowedTool = "Edit"`

    - `const AgentConfigUpdateParamsAllowedToolBash AgentConfigUpdateParamsAllowedTool = "Bash"`

    - `const AgentConfigUpdateParamsAllowedToolGlob AgentConfigUpdateParamsAllowedTool = "Glob"`

    - `const AgentConfigUpdateParamsAllowedToolGrep AgentConfigUpdateParamsAllowedTool = "Grep"`

    - `const AgentConfigUpdateParamsAllowedToolList AgentConfigUpdateParamsAllowedTool = "List"`

    - `const AgentConfigUpdateParamsAllowedToolWebFetch AgentConfigUpdateParamsAllowedTool = "WebFetch"`

    - `const AgentConfigUpdateParamsAllowedToolWebSearch AgentConfigUpdateParamsAllowedTool = "WebSearch"`

    - `const AgentConfigUpdateParamsAllowedToolTask AgentConfigUpdateParamsAllowedTool = "Task"`

    - `const AgentConfigUpdateParamsAllowedToolTodoWrite AgentConfigUpdateParamsAllowedTool = "TodoWrite"`

    - `const AgentConfigUpdateParamsAllowedToolNotebookEdit AgentConfigUpdateParamsAllowedTool = "NotebookEdit"`

    - `const AgentConfigUpdateParamsAllowedToolExitPlanMode AgentConfigUpdateParamsAllowedTool = "ExitPlanMode"`

    - `const AgentConfigUpdateParamsAllowedToolSlack AgentConfigUpdateParamsAllowedTool = "Slack"`

    - `const AgentConfigUpdateParamsAllowedToolLinear AgentConfigUpdateParamsAllowedTool = "Linear"`

    - `const AgentConfigUpdateParamsAllowedToolGitHub AgentConfigUpdateParamsAllowedTool = "GitHub"`

    - `const AgentConfigUpdateParamsAllowedToolConfluence AgentConfigUpdateParamsAllowedTool = "Confluence"`

    - `const AgentConfigUpdateParamsAllowedToolNotion AgentConfigUpdateParamsAllowedTool = "Notion"`

    - `const AgentConfigUpdateParamsAllowedToolDatadog AgentConfigUpdateParamsAllowedTool = "Datadog"`

    - `const AgentConfigUpdateParamsAllowedToolPagerDuty AgentConfigUpdateParamsAllowedTool = "PagerDuty"`

    - `const AgentConfigUpdateParamsAllowedToolSalesforce AgentConfigUpdateParamsAllowedTool = "Salesforce"`

    - `const AgentConfigUpdateParamsAllowedToolFigma AgentConfigUpdateParamsAllowedTool = "Figma"`

    - `const AgentConfigUpdateParamsAllowedToolGranola AgentConfigUpdateParamsAllowedTool = "Granola"`

    - `const AgentConfigUpdateParamsAllowedToolJira AgentConfigUpdateParamsAllowedTool = "Jira"`

    - `const AgentConfigUpdateParamsAllowedToolGmail AgentConfigUpdateParamsAllowedTool = "Gmail"`

    - `const AgentConfigUpdateParamsAllowedToolGoogleCalendar AgentConfigUpdateParamsAllowedTool = "GoogleCalendar"`

    - `const AgentConfigUpdateParamsAllowedToolGoogleDrive AgentConfigUpdateParamsAllowedTool = "GoogleDrive"`

    - `const AgentConfigUpdateParamsAllowedToolGoogleDocs AgentConfigUpdateParamsAllowedTool = "GoogleDocs"`

    - `const AgentConfigUpdateParamsAllowedToolGoogleSheets AgentConfigUpdateParamsAllowedTool = "GoogleSheets"`

    - `const AgentConfigUpdateParamsAllowedToolGoogleSlides AgentConfigUpdateParamsAllowedTool = "GoogleSlides"`

    - `const AgentConfigUpdateParamsAllowedToolSnowflake AgentConfigUpdateParamsAllowedTool = "Snowflake"`

    - `const AgentConfigUpdateParamsAllowedToolRedash AgentConfigUpdateParamsAllowedTool = "Redash"`

    - `const AgentConfigUpdateParamsAllowedToolTableau AgentConfigUpdateParamsAllowedTool = "Tableau"`

    - `const AgentConfigUpdateParamsAllowedToolMetabase AgentConfigUpdateParamsAllowedTool = "Metabase"`

    - `const AgentConfigUpdateParamsAllowedToolGong AgentConfigUpdateParamsAllowedTool = "Gong"`

    - `const AgentConfigUpdateParamsAllowedToolZoomInfo AgentConfigUpdateParamsAllowedTool = "ZoomInfo"`

    - `const AgentConfigUpdateParamsAllowedToolClay AgentConfigUpdateParamsAllowedTool = "Clay"`

  - `Description param.Field[string]`

    Body param

  - `Harness param.Field[AgentConfigUpdateParamsHarness]`

    Body param: Supported agent harness strategies.

    Mirrors `PROVIDERS` in golden-agent's `project/harness/activity.py`.

    - `const AgentConfigUpdateParamsHarnessClaudeCode AgentConfigUpdateParamsHarness = "claude-code"`

    - `const AgentConfigUpdateParamsHarnessCodex AgentConfigUpdateParamsHarness = "codex"`

    - `const AgentConfigUpdateParamsHarnessLitellm AgentConfigUpdateParamsHarness = "litellm"`

  - `Model param.Field[string]`

    Body param

  - `Name param.Field[string]`

    Body param

  - `PersistentWorkspace param.Field[bool]`

    Body param

  - `Repos param.Field[[]RepoSpec]`

    Body param

    - `URL string`

    - `Depth int64`

    - `Path string`

  - `SystemPrompt param.Field[string]`

    Body param

### Returns

- `type AgentConfigUpdateResponse struct{…}`

  - `ID string`

  - `AllowedTools []string`

  - `CreatedAt Time`

  - `Harness string`

  - `Model string`

  - `Name string`

  - `SystemPrompt string`

  - `UpdatedAt Time`

  - `Description string`

  - `Object AgentConfigUpdateResponseObject`

    - `const AgentConfigUpdateResponseObjectAgentConfig AgentConfigUpdateResponseObject = "agent_config"`

  - `PersistentWorkspace bool`

  - `Repos []RepoSpec`

    - `URL string`

    - `Depth int64`

    - `Path string`

### Example

```go
package main

import (
  "context"
  "fmt"

  "github.com/scaleapi/sgp-dev-go"
  "github.com/scaleapi/sgp-dev-go/option"
)

func main() {
  client := sgpdev.NewClient(
    option.WithAPIKey("My API Key"),
    option.WithAccountID("My Account ID"),
  )
  agentConfig, err := client.AgentConfigs.Update(
    context.TODO(),
    "agent_config_id",
    sgpdev.AgentConfigUpdateParams{

    },
  )
  if err != nil {
    panic(err.Error())
  }
  fmt.Printf("%+v\n", agentConfig.ID)
}
```

#### Response

```json
{
  "id": "id",
  "allowed_tools": [
    "string"
  ],
  "created_at": "2019-12-27T18:11:19.117Z",
  "harness": "harness",
  "model": "model",
  "name": "name",
  "system_prompt": "system_prompt",
  "updated_at": "2019-12-27T18:11:19.117Z",
  "description": "description",
  "object": "agent_config",
  "persistent_workspace": true,
  "repos": [
    {
      "url": "x",
      "depth": 1,
      "path": "path"
    }
  ]
}
```

## Delete Agent Config (hard delete)

`client.AgentConfigs.Delete(ctx, agentConfigID) (*AgentConfigDeleteResponse, error)`

**delete** `/v5/agent_configs/{agent_config_id}`

Permanently delete an agent config; this is a hard delete, not an archive, so the row is removed and cannot be restored.

Because a config is only a template, deleting it does not stop or alter any task
already created from it. A user caller can only delete a config they created
unless fine-grained access control grants access. The response echoes the
deleted id.

### Parameters

- `agentConfigID string`

### Returns

- `type AgentConfigDeleteResponse struct{…}`

  - `ID string`

  - `Deleted bool`

  - `Object AgentConfigDeleteResponseObject`

    - `const AgentConfigDeleteResponseObjectAgentConfig AgentConfigDeleteResponseObject = "agent_config"`

### Example

```go
package main

import (
  "context"
  "fmt"

  "github.com/scaleapi/sgp-dev-go"
  "github.com/scaleapi/sgp-dev-go/option"
)

func main() {
  client := sgpdev.NewClient(
    option.WithAPIKey("My API Key"),
    option.WithAccountID("My Account ID"),
  )
  agentConfig, err := client.AgentConfigs.Delete(context.TODO(), "agent_config_id")
  if err != nil {
    panic(err.Error())
  }
  fmt.Printf("%+v\n", agentConfig.ID)
}
```

#### Response

```json
{
  "id": "id",
  "deleted": true,
  "object": "agent_config"
}
```

## Domain Types

### Repo Spec

- `type RepoSpec struct{…}`

  A single repo the agent should clone into its workspace.

  Mirrors the per-entry shape the golden agent's `_validate_repos` accepts:
  `url` is required, the rest are optional passthrough hints. Sent verbatim
  as `task.params.repos` so provisioning clones these instead of the
  deployment-global default.

  - `URL string`

  - `Depth int64`

  - `Path string`
