---
title: "[Beta] Create the issues agent for a session"
method: POST
path: "/api/v1/platform/sessions/{session_id}/issues-agent"
tags: ["issues-agent"]
---

# \[Beta\] Create the issues agent for a session

`POST /api/v1/platform/sessions/{session_id}/issues-agent`

## Request

- Base URL: `https://api.smith.langchain.com`
- URL: `https://api.smith.langchain.com/api/v1/platform/sessions/{session_id}/issues-agent`
- Auth: one of:
  - API key in header `X-API-Key`
  - API key in header `X-Tenant-Id`
  - HTTP bearer

**Beta:** This endpoint is in active development and may change without notice.

Configures the issues agent for the given tracer session and enqueues
the initial scan. Fails if an agent already exists for the session.

## Path parameters

- `session_id` string, required

## Request body

- AgentCreateIssuesAgentRequest
  - `analysis_level` 'standard' | 'reduced' | 'expanded': AnalysisLevel is how thoroughly Engine monitors the project: "standard" (the default), "reduced" (fewer traces at lower cost), or "expanded" (more traces per run, for projects with enough tracing volume). Omit for "standard".
  - `auto_open_fix_pr` boolean: AutoOpenFixPR opens a pull request for every fix the agent produces — one per repository it changed — instead of waiting for one to be opened from the issue. Has no effect until the board tracks a repository, since a fix has nowhere to open. Omit for false.
  - `context_hub_repo_handle` string
  - `github_base_branch` string: Legacy: applies to the repo github_repo_url names.
  - `github_repo_subdir` string: Legacy: applies to the repo github_repo_url names.
  - `github_repo_url` string: Legacy: treated as a one-entry github_repos list.
  - `github_repos` AgentGithubRepoInput[]: Created with the board. Wins over the deprecated fields below.
    - `base_branch` string
    - `provider` 'github' | 'gitlab'
    - `repo_url` string
    - `subdir` string
  - `priorities` string[]
  - `run_filter` string: Runs-filter-DSL trace scope; omit/null/empty for no scope.

## Response `201`

Created

- AgentIssuesAgent
  - `agent_overview_accepted` boolean
  - `analysis_level` 'standard' | 'reduced' | 'expanded': AnalysisLevel controls coverage vs cost: "standard" (default), "reduced" (one scan a day, fewer traces per scan), or "expanded" (2x traces per run). Stored NULL in the DB means standard; reads always return a concrete value.
  - `auto_open_fix_pr` boolean: When true, every fix run on this board opens a pull request instead of parking the fix for someone to publish. Defaults to false.
  - `context_hub_repo_handle` string
  - `created_at` string
  - `cron_enabled` boolean
  - `cron_schedule` string
  - `engine_version` string
  - `github_base_branch` string: Legacy: aliases the oldest GitHub entry in GithubRepos.
  - `github_repo_subdir` string: Legacy: aliases the oldest GitHub entry in GithubRepos.
  - `github_repo_url` string: Legacy: aliases the oldest GitHub entry in GithubRepos.
  - `github_repos` AgentGithubRepo[]
    - `base_branch` string
    - `created_at` string, date-time
    - `id` string
    - `provider` 'github' | 'gitlab'
    - `repo_url` string
    - `subdir` string
    - `updated_at` string, date-time
  - `id` string
  - `issue_count` integer
  - `latest_run_id` string
  - `latest_thread_id` string: IDs of the latest run on LangSmith Deployments; NULL until first trigger.
  - `linear_available` boolean
  - `linear_integration` AgentLinearIntegration
    - `enabled` boolean
    - `project_id` string
    - `project_name` string
    - `team_id` string
    - `team_key` string
    - `team_name` string
    - `workspace_id` string
    - `workspace_name` string
  - `linear_sync_health` AgentLinearSyncHealth
    - `auth_required` integer
    - `failed` integer
    - `paused` integer
    - `pending` integer
    - `synced` integer
  - `preview_verify_enabled` boolean: PreviewVerifyEnabled lets this board's fix runs use preview deployments when issue validation is enabled for its tracing project.
  - `preview_verify_no_trigger` boolean: PreviewVerifyNoTrigger tells fix verification not to request a preview. The deployment builds one itself for the fix commit.
  - `priorities` string[]
  - `run_filter` string: RunFilter is a runs-filter-DSL string scoping which traces Engine analyzes (prompt guidance, not an enforced query). NULL = no scope. Clamped by validateRunFilter.
  - `selected_trace_count` integer: Compatibility alias for selected_trace_count_last_14_days. Deprecated: use selected_trace_count_last_14_days.
  - `selected_trace_count_last_14_days` integer: The number of traces Engine inspected in the last 14 days.
  - `selected_trace_count_last_7_days` integer: The number of traces Engine inspected in the last 7 days.
  - `session_agent_overview_repo_id` string
  - `session_id` string
  - `session_lcu_spend_limit_monthly` string: SessionLCUSpendLimitMonthly is the per-project monthly Engine LCU spend limit: NULL/negative = no limit; 0 or positive = monthly cap (spend is never negative, so a cap of 0 always reads as reached). Enforced in addition to (and independently of) the org-level limit. Serialized as a string to preserve NUMERIC(28,6) precision.
  - `session_name` string: JOINed from tracer_session
  - `target_auth` AgentTargetAuthStatus
    - `has_unreadable_credentials` boolean: True when a credential is stored but cannot be read back, so the UI can offer to replace it instead of showing an unconfigured board.
    - `header_names` string[]
  - `tenant_id` string
  - `tenant_name` string: JOINed from tenants (workspace label); resolved server-side so the org-admin list can label rows across workspaces the caller isn't a member of
  - `updated_at` string
  - `user_instructions` string: User-owned freeform preferences. Engine reads this as authoritative context and reconciles it into the Agent Overview on the next scan, but never edits it. NULL when the user hasn't set any.
  - `validation_deployment_id` string: ValidationDeploymentID selects the deployment used for baseline replay and as the parent of fix-verification previews.

## Other responses

- `400`: Bad Request
- `401`: Unauthorized
- `403`: Forbidden
- `409`: Conflict
- `500`: Internal Server Error

## Changes

- **2026-10-23** `e9b5f2bcae6f`: 2 info
  - added the new optional request property `github_repos/items/provider`
  - added the optional property `github_repos/items/provider` to the response with the `201` status
- **2026-10-22** `3c96302af436`: 1 info
  - added the optional property `preview_verify_no_trigger` to the response with the `201` status
- **2026-10-16** `1a8ee9358d81`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/langchain-ai/apis/langsmith/changes/api/v1/platform/sessions/:session_id/issues-agent/post.md)

---

[API](https://skmtc.dev/langchain-ai/apis/langsmith.md) - [All operations](https://skmtc.dev/langchain-ai/apis/langsmith/llms.txt) - [OpenAPI document](https://skmtc.dev/langchain-ai/apis/langsmith/revisions/7a01c01f75e8?raw)
