Skip to content

ENG-2302: Add Azure DevOps Pipeline trigger and list - #73

Open
kaustav98255 wants to merge 1 commit into
mainfrom
eng-2302-trigger-azure-pipeline
Open

ENG-2302: Add Azure DevOps Pipeline trigger and list#73
kaustav98255 wants to merge 1 commit into
mainfrom
eng-2302-trigger-azure-pipeline

Conversation

@kaustav98255

@kaustav98255 kaustav98255 commented Mar 21, 2026

Copy link
Copy Markdown
Contributor

Summary

This PR adds support for triggering Azure DevOps Pipeline runs and listing available pipelines through the Paradime CLI.

Changes

New Files

  • paradime/core/scripts/azure_pipeline.py — Core implementation for Azure Pipelines operations:

    • trigger_azure_pipelines() — Triggers runs for multiple pipelines in parallel via ThreadPoolExecutor
    • trigger_pipeline_run() — Triggers a single pipeline run via POST to Azure DevOps REST API (v7.1)
    • _get_auth_headers() — Builds Basic auth headers using base64(":"+PAT) encoding
    • _wait_for_pipeline_completion() — Polls run status every 5 seconds until terminal state (completed) or timeout
    • list_azure_pipelines() — Lists all pipelines in a project with their ID, name, folder, and portal URL
  • paradime/cli/integrations/azure_pipeline.py — CLI command definitions for Azure Pipelines operations

Modified Files

  • paradime/cli/run.py — Registered azure_pipeline_trigger and azure_pipeline_list commands

CLI Commands

azure-pipeline-trigger — Trigger Azure DevOps pipeline runs

# Trigger a single pipeline
paradime run azure-pipeline-trigger \
  --organization my-org \
  --project my-project \
  --pat <personal-access-token> \
  --pipeline-ids 123

# Trigger multiple pipelines on a specific branch
paradime run azure-pipeline-trigger \
  --organization my-org \
  --project my-project \
  --pat <pat> \
  --pipeline-ids 123,456,789 \
  --branch develop \
  --wait

# Fire and forget (don't wait for completion)
paradime run azure-pipeline-trigger \
  --pipeline-ids 123 \
  --no-wait

azure-pipeline-list — List all pipelines in an Azure DevOps project

paradime run azure-pipeline-list \
  --organization my-org \
  --project my-project \
  --pat <personal-access-token>

# JSON output
paradime run azure-pipeline-list --json

Implementation Details

Aspect Details
Authentication Basic auth with PAT: base64(":"+PAT) in Authorization header
API Version Azure DevOps REST API v7.1
Pipeline Monitoring Polls run state every 5 seconds via GET /pipelines/{id}/runs/{runId}
Terminal States completed with result: succeeded, failed, canceled
Default Timeout 1440 minutes (24 hours)
Env Var Support AZURE_DEVOPS_PAT, AZURE_DEVOPS_ORGANIZATION, AZURE_DEVOPS_PROJECT via env_click_option
API Client requests library with Basic auth

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@linear

linear Bot commented Mar 21, 2026

Copy link
Copy Markdown

Base automatically changed from feature-branch-unified-cli to main March 24, 2026 10:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants