---
title: "Generate session insights"
method: POST
path: "/v3/enterprise/sessions/{devin_id}/insights/generate"
tags: ["sessions"]
---

# Generate session insights

`POST /v3/enterprise/sessions/{devin_id}/insights/generate`

## Request

- The document declares no server URL.
- Auth: HTTP bearer
- TypeScript: <https://skmtc.dev/devinenterprise/apis/devin-api-v1/docs/v3/enterprise/sessions/:devin_id/insights/generate/post.ts> (a function with typed inputs; its response is checked against the schema)

Trigger on-demand generation of session insights.

Returns ``already_exists`` if insights have already been generated.
Otherwise kicks off generation in the background. Poll the
GET insights endpoint to retrieve results once generation completes.

## Path parameters

- `devin_id` string, nullable, required

## Query parameters

- `org_id` string, nullable

## Response `200`

Successful Response

- SessionInsightsGenerateResponse: Response from triggering session insights generation.
  - `session_id` string, required: The session ID for which insights generation was triggered.
  - `status` string, required: The status of the generation request.

## Other responses

- `401`: Unauthorized
- `403`: Forbidden
- `404`: Not Found
- `409`: Conflict
- `422`: Unprocessable Content
- `429`: Too Many Requests

---

[API](https://skmtc.dev/devinenterprise/apis/devin-api-v1.md) - [All operations](https://skmtc.dev/devinenterprise/apis/devin-api-v1/llms.txt) - [OpenAPI document](https://skmtc.dev/devinenterprise/apis/devin-api-v1/revisions/e3244476af1c?raw)
