Analysis

Calculate Critical Path (Async)

Submit CPM calculation as async job (for large schedules >1,000 tasks).

This endpoint queues a CPM calculation job for background processing. Use GET /api/v1/jobs/{job_id} to poll for completion.

Tier Restrictions:

  • Demo/Free: Blocked (use sync endpoint ≤1,000 tasks)
  • Starter+: Allowed

Task Limits:

  • Starter: 2,000 tasks
  • Professional: 5,000 tasks
  • Enterprise: 50,000 tasks
  • Government: 100,000 tasks

Args: request: CPM calculation request api_key: API key for authentication

Returns: Job submission response with job_id and polling_url

Raises: HTTPException 402: Task count exceeds tier limit HTTPException 403: Async not available for tier (demo/free)

post/api/v1/analysis/cpm/async

Request

  • Base URL: https://api.bellatorsi.com (the document declares no server; this is the origin it was published from)
  • URL: https://api.bellatorsi.com/api/v1/analysis/cpm/async
  • Auth: none declared

Headers

x-api-keystring nullable
authorizationstring nullable
x-bellator-internal-dispatchstring nullable

Request body

Example request

{
  "options": {
    "include_network_details": true
  },
  "tasks": [
    {
      "duration_days": 5,
      "id": "T1",
      "predecessors": []
    },
    {
      "duration_days": 3,
      "id": "T2",
      "predecessors": [
        "T1"
      ]
    },
    {
      "duration_days": 7,
      "id": "T3",
      "predecessors": [
        "T1"
      ]
    },
    {
      "duration_days": 2,
      "id": "T4",
      "predecessors": [
        "T2",
        "T3"
      ]
    }
  ]
}

Response

Successful Response

job_idstring required

Unique job identifier

status'queued' | 'processing' | 'completed' | 'failed' | 'cancelled' required

Status of an async job.

Job lifecycle:

  1. QUEUED - Job submitted to queue, waiting for worker
  2. PROCESSING - Worker picked up job and is executing
  3. COMPLETED - Job finished successfully
  4. FAILED - Job encountered an error
  5. CANCELLED - Job was cancelled by user before completion
estimated_completion_secondsinteger required

Estimated time until completion

status_urlstring required

URL to poll job status

created_atstring date-time

Job creation timestamp

Example response

{
  "created_at": "2025-01-08T12:00:00Z",
  "estimated_completion_seconds": 15,
  "job_id": "550e8400-e29b-41d4-a716-446655440000",
  "status": "queued",
  "status_url": "/api/v1/jobs/550e8400-e29b-41d4-a716-446655440000"
}

Changes

No recorded changes to this operation across all 1 revision of this API.