GET
/
beta
/
v2
/
enterprise
/
sessions
curl -X GET "https://api.devin.ai/beta/v2/enterprise/sessions?limit=10&skip=0" \
  -H "Authorization: Bearer YOUR_API_KEY"
{
  "items": [
    {
      "devin_id": "devin-abc123",
      "devin_status": "completed",
      "session_url": "https://app.devin.ai/sessions/abc123",
      "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,
      "prs": [
        {
          "pr_url": "https://github.com/example/repo/pull/123",
          "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"
    }
  ],
  "total": 150,
  "skip": 0,
  "limit": 10,
  "has_more": true,
  "next_cursor": 10
}
Beta Endpoint - This endpoint is currently in beta and may change. While we strive to maintain backward compatibility, the API structure and response format may be updated as we improve the feature.
This endpoint retrieves a paginated list of all Devin sessions within your enterprise, including detailed session analysis, pull request information, and ACU consumption data.

Query Parameters

skip
integer
default:"0"
Number of items to skip for pagination (minimum: 0)
limit
integer
default:"100"
Maximum number of items to return (minimum: 1, maximum: 1000)
created_date_from
string
Filter sessions created after this date (ISO 8601 format)
created_date_to
string
Filter sessions created before this date (ISO 8601 format)
updated_date_from
string
Filter sessions updated after this date (ISO 8601 format)
updated_date_to
string
Filter sessions updated before this date (ISO 8601 format)
org_ids
array
Filter sessions by organization IDs (array of strings)
user_ids
array
Filter sessions by user IDs (array of strings)
devin_ids
array
Filter sessions by specific Devin session IDs (array of strings)

Response

items
array
Array of session objects
total
integer
Total number of sessions available
skip
integer
Number of items skipped
limit
integer
Maximum number of items per page
has_more
boolean
Whether more items are available
next_cursor
integer
Cursor for the next page (if applicable)
curl -X GET "https://api.devin.ai/beta/v2/enterprise/sessions?limit=10&skip=0" \
  -H "Authorization: Bearer YOUR_API_KEY"
{
  "items": [
    {
      "devin_id": "devin-abc123",
      "devin_status": "completed",
      "session_url": "https://app.devin.ai/sessions/abc123",
      "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,
      "prs": [
        {
          "pr_url": "https://github.com/example/repo/pull/123",
          "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"
    }
  ],
  "total": 150,
  "skip": 0,
  "limit": 10,
  "has_more": true,
  "next_cursor": 10
}