diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml new file mode 100644 index 0000000..4ee627a --- /dev/null +++ b/.github/workflows/main.yml @@ -0,0 +1,16 @@ +name: Scheduled GET Request + +on: + schedule: + # This cron expression runs the workflow every 5 minutes + - cron: '*/5 * * * *' + workflow_dispatch: # Allows manual trigger of the workflow +jobs: + get-api-request: + runs-on: ubuntu-latest + steps: + # Step to make the GET request + - name: Make GET API Request and Log Response + run: | + response=$(curl -s -X GET https://igts-back.onrender.com/api/blog/getallblogs/0) + echo "Response: $response"