From 27997f3a5506ff9e0c0b85f59b5e222b3c7142ca Mon Sep 17 00:00:00 2001 From: sangeet-joy_xero Date: Mon, 23 Sep 2024 12:15:22 +0530 Subject: [PATCH] testing response --- .github/workflows/pr.yml | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/.github/workflows/pr.yml b/.github/workflows/pr.yml index 6428b9af1..ad9659b2f 100644 --- a/.github/workflows/pr.yml +++ b/.github/workflows/pr.yml @@ -55,12 +55,15 @@ jobs: - name: Calling All SDK workflows run: | - curl -X POST \ + response = $(curl -X POST \ -H 'Authorization: Bearer ${{ steps.get_access_token.outputs.result }}' \ -H "Accept: application/vnd.github.everest-preview+json" \ -H "X-GitHub-Api-Version: 2022-11-28" \ https://api.github.com/repos/xero-internal/xeroapi-sdk-codegen/actions/workflows/pr.yml/dispatches \ -d '{"ref":"PETOSS-536-enabling-workflow-dispatch","inputs":{"branch_name": "${{github.head_ref}}"}}' + -w "%{http_code}") + + echo "response: $response" # - name: Get workflow run ID # id: get-run-id @@ -90,3 +93,7 @@ jobs: | jq -r '.workflow_runs[0]') echo "workflow run: $workflow_run" + + run_id=(echo $workflow_run | jq -r '.id') + + echo "workflow run ID: $run_id"