Use the GitHub API in Workflow
To make REST API calls into GitHub from a workflow, perform the following steps:
- In the Workflow Studio, open the new or existing flow to which you want to add the REST API call activity.
- In the Workflow Canvas, open the activity wheel.Figure 1. Search Activity Wheel
- Under the Developer category, click on the HTTP Request activity.The HTTP Request activity screen is displayed.Figure 2. HTTP Request
- In the Http request activity, click on the Authorization tab.
- In the Integration field, select the Github option from the list.
- In the Connection field, select the connection you created from the list.
- Enter the GitHub API you will be using.
In the above example, GET https://api.github.com/issues is used to retrieve all issues in the account.
- Click on the Testing tab to confirm that the connection is set up correctly to call the API.
The results appear in the Response area of the tab.
If there is any error, check the details of the error returned and verify that the application added in GitHub has the appropriate scope value to access the called API.
↑