This verified source can be used to load data on issues or pull requests from any GitHub repository onto a destination of your choice using GitHub API.
To obtain the API token, follow these steps:
Click on your profile picture located in the top right corner.
Choose “Settings”.
Select “Developer settings” from the left panel.
Under “Personal access tokens”, click on “Generate a personal access token (preferably under Tokens (classic))“.
Check the following scopes to grant permissions to the token:
public_repo
: Limits access to public repositories.read:repo_hook
: Grants read and ping access to hooks in public or private repositories.read:org
: Read-only access to organization membership, organization projects, and team membership.read:user
: Grants access to read a user’s profile data.read:project
: Grants read-only access to user and organization projects.read:discussion
: Allows read access for team discussions.Click on “Generate token”.
Copy the token and remember to save it for future use.
The config
section in a YAML file includes the following properties:
Connector name: GitHub
Access_token: Access token
Type: Reactions/repo_events
Owner: Owner
Repo: Repository Name
Items_per_page: Items per page
Max_items: Maximum number of items
Repo_events:
version: 1
encrypt_credentials: false
plugins:
extractors:
- name: Github
connectorname: Github
config:
access_token: <ACCESS TOKEN>
properties:
type: <REPO EVENTS>
owner: <OWNER>
Reactions:
version: 1
encrypt_credentials: false
plugins:
extractors:
- name: Github
connectorname: Github
config:
access_token: <ACCESS TOKEN>
properties:
type: <REACTIONS>
owner: <OWNER>
repo: <REPO NAME>
items_per_page: <ITEMS PER PAGE>
max_items: <MAX NO OF ITEMS>
max_items_age_seconds: <MAX ITEM AGE SECONDS>