Skip to main content
GET
/
v2
/
enterprise
/
sessions
/
{session_id}
curl -X GET "https://api.devin.ai/v2/enterprise/sessions/abc123" \
  -H "Authorization: Bearer YOUR_API_KEY"
{
  "session_id": "abc123",
  "url": "https://app.devin.ai/sessions/abc123",
  "status": "exit",
  "title": "Fix authentication bug",
  "tags": ["bug-fix", "auth"],
  "user_id": "user_456",
  "org_id": "org_789",
  "created_at": "2024-01-15T10:30:00Z",
  "updated_at": "2024-01-15T11:45:00Z",
  "acus_consumed": 25.5,
  "pull_requests": [
    {
      "pr_url": "https://github.com/example/repo/pull/123",
      "pr_state": "merged",
      "state": "merged"
    }
  ],
  "session_analysis": {
    "issues": [
      {
        "issue": "Missing environment variables",
        "impact": "High",
        "label": "Configuration"
      }
    ],
    "timeline": [
      {
        "title": "Started repository setup",
        "description": "Devin began setting up the development environment"
      }
    ],
    "action_items": [
      {
        "issue_id": "issue_1",
        "type": "machine_setup",
        "action_item": "Configure environment variables for database connection"
      }
    ],
    "suggested_prompt": {
      "original_prompt": "Fix the bug",
      "suggested_prompt": "Fix the authentication bug in the login endpoint by checking the JWT token validation",
      "feedback_items": [
        {
          "issue_id": "issue_1",
          "summary": "Prompt too vague",
          "excerpt": "Fix the bug",
          "details": "The prompt should specify which bug and provide more context"
        }
      ]
    }
  },
  "initial_user_message": "Please fix the authentication issue in our login system"
}
Retrieves detailed information about a specific Devin session within your enterprise, including comprehensive session analysis, initial user message, pull request information, and ACU consumption data.

Path Parameters

session_id
string
required
The unique identifier of the Devin session (e.g., “abc123”)

Response

session_id
string
required
Unique identifier for the Devin session
url
string
required
URL to view the session in the Devin interface
status
string
required
Current status of the Devin session (new, claimed, running, exit, error, suspended, resuming)
title
string
Title of the session
tags
array
required
List of tags associated with the session
user_id
string
ID of the user who created the session
org_id
string
required
ID of the organization the session belongs to
created_at
string
required
Timestamp when the session was created
updated_at
string
required
Timestamp when the session was last updated
acus_consumed
number
required
Number of ACUs (Agent Compute Units) consumed by the session
pull_requests
array
required
List of pull requests created during the session
session_analysis
object
Analysis data for the session (if available)
initial_user_message
string
The initial message provided by the user to start the session
curl -X GET "https://api.devin.ai/v2/enterprise/sessions/abc123" \
  -H "Authorization: Bearer YOUR_API_KEY"
{
  "session_id": "abc123",
  "url": "https://app.devin.ai/sessions/abc123",
  "status": "exit",
  "title": "Fix authentication bug",
  "tags": ["bug-fix", "auth"],
  "user_id": "user_456",
  "org_id": "org_789",
  "created_at": "2024-01-15T10:30:00Z",
  "updated_at": "2024-01-15T11:45:00Z",
  "acus_consumed": 25.5,
  "pull_requests": [
    {
      "pr_url": "https://github.com/example/repo/pull/123",
      "pr_state": "merged",
      "state": "merged"
    }
  ],
  "session_analysis": {
    "issues": [
      {
        "issue": "Missing environment variables",
        "impact": "High",
        "label": "Configuration"
      }
    ],
    "timeline": [
      {
        "title": "Started repository setup",
        "description": "Devin began setting up the development environment"
      }
    ],
    "action_items": [
      {
        "issue_id": "issue_1",
        "type": "machine_setup",
        "action_item": "Configure environment variables for database connection"
      }
    ],
    "suggested_prompt": {
      "original_prompt": "Fix the bug",
      "suggested_prompt": "Fix the authentication bug in the login endpoint by checking the JWT token validation",
      "feedback_items": [
        {
          "issue_id": "issue_1",
          "summary": "Prompt too vague",
          "excerpt": "Fix the bug",
          "details": "The prompt should specify which bug and provide more context"
        }
      ]
    }
  },
  "initial_user_message": "Please fix the authentication issue in our login system"
}