engineering_analytics
engineering_analytics

Jobs of a single workflow run attempt, with per-job duration, runner tier, and estimated cost. Scoped to one run_attempt (the latest unless specified) so a re-run's attempts don't merge. Returns an empty list when the job-level source isn't synced yet.

get/api/projects/{project_id}/engineering_analytics/workflow_jobs/

Request

  • Base URL: https://us.posthog.com
  • URL: https://us.posthog.com/api/projects/{project_id}/engineering_analytics/workflow_jobs/
  • Auth: HTTP bearer

Path parameters

project_idstring required

Project ID of the project you're trying to access. To find the ID of the project, make a call to /api/projects/.

Query parameters

ci_engine'depot_ci' | 'github_actions'

CI engine. Required when run_id exists in both engines.

repostring

'owner/name' repository to scope to when the selected source syncs several repositories (from the sources list). Defaults to the source's first repository.

run_attemptinteger

Which re-run attempt to scope jobs to. Omit to use the run's latest attempt; pass an explicit attempt to avoid mixing jobs across a re-run's attempts.

run_idinteger required

Workflow run id to list jobs for.

source_idstring uuid

Connected GitHub data warehouse source to read from. Defaults to the oldest connected GitHub source when the team has more than one.

Response

idinteger required

Integer job id; unique only together with ci_engine.

run_idinteger required

The workflow run id this job belongs to.

namestring required

Job name.

statusstring required

Raw job status: 'queued', 'in_progress', 'completed', etc.

conclusionstring nullable required

Job conclusion ('success', 'failure', 'cancelled', 'skipped', ...), or null while running.

started_atstring date-time nullable required

When the job started, or null while still queued.

completed_atstring date-time nullable required

When the job completed, or null while still running.

duration_secondsinteger nullable required

Wall-clock duration in seconds; null until the job completes.

runner_providerstring required

Where the job ran: 'github_hosted' (free for open source), 'self_hosted' (billable), or 'unknown'.

runner_labelstring required

Runner tier the job ran on (e.g. '16-core' or 'ubuntu-latest'), or '' when unknown.

estimated_cost_usdnumber double nullable required

Estimated cost in USD from runner tier + elapsed time; null when the tier is unknown or the job hasn't finished.

native_run_idstring nullable

Source-native run id; use with ci_engine for identity.

native_workflow_run_idstring nullable

Source-native workflow run id; use with ci_engine for identity.

native_job_idstring nullable

Source-native job id; use with ci_engine for identity.

native_attempt_idstring nullable

Source-native attempt id; use with ci_engine for identity.

Changes

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