---
title: "Generate Context"
method: POST
path: "/api/admin/captures/{capture_id}/generate-context"
tags: ["admin"]
---

# Generate Context

`POST /api/admin/captures/{capture_id}/generate-context`

Generate context for a capture using vision LLM.

This endpoint:
1. Fetches the capture data (screenshot + DOM)
2. Sends to GPT-4o with vision capabilities
3. Returns structured context with workflows and questions

## Path parameters

- `capture_id` string, required

## Headers

- `authorization` string, required

## Response `200`

Successful Response

- GenerateContextResponse — Response from context generation (legacy Phase 4).
  - `page_summary` string, required
  - `element_descriptions` object, required
  - `workflows` WorkflowResponse[], required
    - `name` string, required
    - `description` string, required
    - `steps` string[], required
  - `ambiguities` string[], required
  - `questions_for_human` string[], required
  - `suggested_context` string, required

## Other responses

- `422` — Validation Error

---

[API](https://skmtc.dev/usecrow/apis/crow-backend-multi-tenant-saas.md) · [All operations](https://skmtc.dev/usecrow/apis/crow-backend-multi-tenant-saas/llms.txt) · [OpenAPI document](https://skmtc.dev/usecrow/apis/crow-backend-multi-tenant-saas/revisions/66e6366f8ef9?raw)
