arazzo: 1.0.1 info: title: GitLab Find and Run a Pending Manual Job summary: List project jobs, pick the first manual job, and trigger it. description: >- A pipeline-unblocking flow. The workflow lists jobs filtered to the manual scope, selects the first one returned, and triggers it to run. Every step spells out its request inline so the flow can be read and executed without opening the underlying OpenAPI description. version: 1.0.0 sourceDescriptions: - name: gitlabProjectsApi url: ../openapi/gitlab-api-v4-projects-openapi-original.yml type: openapi workflows: - workflowId: find-and-run-manual-job summary: Locate a manual job in a project and start it. description: >- Lists jobs scoped to manual, captures the first job id, and triggers that job. inputs: type: object required: - privateToken - projectId properties: privateToken: type: string description: GitLab Private-Token used to authenticate the API calls. projectId: type: integer description: The ID of the project. steps: - stepId: listManualJobs description: List jobs scoped to manual so a runnable job can be selected. operationId: listProjectJobs parameters: - name: Private-Token in: header value: $inputs.privateToken - name: id in: path value: $inputs.projectId - name: scope in: query value: - manual successCriteria: - condition: $statusCode == 200 outputs: manualJobId: $response.body#/0/id manualJobName: $response.body#/0/name - stepId: runJob description: Trigger the selected manual job. operationId: triggerManualJob parameters: - name: Private-Token in: header value: $inputs.privateToken - name: id in: path value: $inputs.projectId - name: job_id in: path value: $steps.listManualJobs.outputs.manualJobId successCriteria: - condition: $statusCode == 200 outputs: triggeredJobId: $steps.listManualJobs.outputs.manualJobId triggeredJobName: $steps.listManualJobs.outputs.manualJobName