GitHub

The GitHub component is an application component that allows users to do anything available on GitHub. It can carry out the following tasks:

#Release Stage

Alpha

#Configuration

The component definition and tasks are defined in the definition.json and tasks.json files respectively.

#Setup

In order to communicate with GitHub, the following connection details need to be provided. You may specify them directly in a pipeline recipe as key-value pairs within the component's setup block, or you can create a Connection from the Integration Settings page and reference the whole setup as setup: ${connection.<my-connection-id>}.

FieldField IDTypeNote
Token (required)tokenstringFill in your GitHub access token for advanced usages. For more information about how to create tokens, please refer to the github settings.

#Supported Tasks

#List Pull Requests

Get the list of all pull requests in a repository. Detailed information about each commit in a PR is omitted, please use the Get Commit task or the Get Pull Request task to get the details of a commit.

InputIDTypeDescription
Task ID (required)taskstringTASK_LIST_PULL_REQUESTS
Owner (required)ownerstringOwner of the repository.
Repository (required)repositorystringRepository name.
StatestatestringState of the PRs, including open, closed, all. Default is open.
Enum values
  • open
  • closed
  • all
SortsortstringSort the PRs by created, updated, popularity, or long-running. Default is created.
Enum values
  • created
  • updated
  • popularity
  • long-running
DirectiondirectionstringDirection of the sort, including asc or desc. Default is desc.
Enum values
  • asc
  • desc
PagepageintegerPage number of the results to fetch. Default is 1.
Per Pageper-pageintegerNumber of results to fetch per page. Default is 30.
OutputIDTypeDescription
Pull Requestspull-requestsarray[object]An array of PRs.
Output Objects in List Pull Requests

Pull Requests

FieldField IDTypeNote
PR basebasestringBase commit of the PR (in SHA value).
PR bodybodystringBody of the PR.
Number of PR commentscomments-numintegerNumber of comments on the PR.
CommitscommitsarrayCommits in the PR.
Number of PR commitscommits-numintegerNumber of commits in the PR.
PR diff urldiff-urlstringURL to the diff of the PR.
PR headheadstringHead commit of the PR (in SHA value).
PR ididintegerID of the PR.
PR numbernumberintegerNumber of the PR.
Number of PR review commentsreview-comments-numintegerNumber of review comments in the PR.
PR statestatestringState of the PR.
PR TitletitlestringTitle of the PR.

Commits

FieldField IDTypeNote
FilesfilesarrayFiles in the commit.
Commit messagemessagestringMessage of the commit.
Commit SHAshastringSHA of the commit.
Commit statsstatsobjectStats of changes.

Commit Stats

FieldField IDTypeNote
AdditionsadditionsintegerNumber of additions in the commit.
Total changeschangesintegerTotal number of changes in the commit.
DeletionsdeletionsintegerNumber of deletions in the commit.

Files

FieldField IDTypeNote
AdditionsadditionsintegerNumber of additions in the commit.
Total changeschangesintegerTotal number of changes in the commit.
DeletionsdeletionsintegerNumber of deletions in the commit.
File namefilenamestringName of the file.
PatchpatchstringPatch of the file.

#Get Pull Request

Get a pull request from a repository, given the PR number. This will default to the latest PR if no PR number is provided.

InputIDTypeDescription
Task ID (required)taskstringTASK_GET_PULL_REQUEST
Owner (required)ownerstringOwner of the repository.
Repository (required)repositorystringRepository name.
PR Numberpr-numberintegerNumber of the PR. 0 for the latest PR.
OutputIDTypeDescription
PR ID (optional)idintegerID of the PR.
PR Number (optional)numberintegerNumber of the PR.
PR State (optional)statestringState of the PR.
PR Title (optional)titlestringTitle of the PR.
PR Body (optional)bodystringBody of the PR.
PR Diff URL (optional)diff-urlstringURL to the diff of the PR.
PR Head (optional)headstringHead commit of the PR (in SHA value).
PR Base (optional)basestringBase commit of the PR (in SHA value).
Number of PR Comments (optional)comments-numintegerNumber of comments on the PR.
Number of PR Commits (optional)commits-numintegerNumber of commits in the PR.
Number of PR Review Comments (optional)review-comments-numintegerNumber of review comments in the PR.
Commits (optional)commitsarray[object]Commits in the PR.
Output Objects in Get Pull Request

Commits

FieldField IDTypeNote
FilesfilesarrayFiles in the commit.
Commit messagemessagestringMessage of the commit.
Commit SHAshastringSHA of the commit.
Commit statsstatsobjectStats of changes.

Commit Stats

FieldField IDTypeNote
AdditionsadditionsintegerNumber of additions in the commit.
Total changeschangesintegerTotal number of changes in the commit.
DeletionsdeletionsintegerNumber of deletions in the commit.

Files

FieldField IDTypeNote
AdditionsadditionsintegerNumber of additions in the commit.
Total changeschangesintegerTotal number of changes in the commit.
DeletionsdeletionsintegerNumber of deletions in the commit.
File namefilenamestringName of the file.
PatchpatchstringPatch of the file.

#Get Commit

Get a commit from a repository, given the commit SHA

InputIDTypeDescription
Task ID (required)taskstringTASK_GET_COMMIT
Owner (required)ownerstringOwner of the repository.
Repository (required)repositorystringRepository name.
Commit SHA (required)shastringSHA of the commit.
OutputIDTypeDescription
Commit SHA (optional)shastringSHA of the commit.
Commit Message (optional)messagestringMessage of the commit.
Commit Stats (optional)statsobjectStats of changes.
Files (optional)filesarray[object]Files in the commit.
Output Objects in Get Commit

Commit Stats

FieldField IDTypeNote
AdditionsadditionsintegerNumber of additions in the commit.
Total changeschangesintegerTotal number of changes in the commit.
DeletionsdeletionsintegerNumber of deletions in the commit.

Files

FieldField IDTypeNote
AdditionsadditionsintegerNumber of additions in the commit.
Total changeschangesintegerTotal number of changes in the commit.
DeletionsdeletionsintegerNumber of deletions in the commit.
File namefilenamestringName of the file.
PatchpatchstringPatch of the file.

#List Review Comments

Get the review comments in a pull request. The comments can be on a specific line or on the PR as a whole.

InputIDTypeDescription
Task ID (required)taskstringTASK_LIST_REVIEW_COMMENTS
Owner (required)ownerstringOwner of the repository.
Repository (required)repositorystringRepository name.
PR Numberpr-numberintegerNumber of the PR. Default is 0, which retrieves all comments on all PRs in the repository.
SortsortstringSort the comments by created, updated. Default is created.
Enum values
  • created
  • updated
DirectiondirectionstringDirection of the sort, including asc or desc. Default is desc.
Enum values
  • asc
  • desc
SincesincestringDate (in YYYY-MM-DD format) from which comments will start to be fetched. The date will be in the UTC timezone.
PagepageintegerPage number of the results to fetch. Default is 1.
Per Pageper-pageintegerNumber of results to fetch per page. Default is 30.
OutputIDTypeDescription
Commentscommentsarray[object]An array of comments.
Output Objects in List Review Comments

Comments

FieldField IDTypeNote
Comment bodybodystringBody of the comment.
Commit SHAcommit-idstringSHA of the commit on which you want to comment.
Comment created atcreated-atstringTime the comment was created.
Comment ididintegerID of the comment.
In Reply Toin-reply-to-idintegerID of the comment this comment is in reply to.
Comment end linelineintegerThe line of the blob in the pull request diff that the comment applies to. For a multi-line comment, the last line of the range that your comment applies to.
Comment pathpathstringPath of the file the comment is on.
Comment end sidesidestringSide of the end line, can be one of: LEFT, RIGHT, side. LEFT is the left side of the diff (deletion), RIGHT is the right side of the diff (addition), and side is the comment on the PR as a whole. Default is side.
Comment start linestart-lineintegerThe first line in the pull request diff that your multi-line comment applies to. Only multi-line comment needs to fill this field.
Comment start sidestart-sidestringSide of the start line, can be one of: LEFT, RIGHT, side. LEFT is the left side of the diff (deletion), RIGHT is the right side of the diff (addition), and side is the comment on the PR as a whole. Default is side.
Comment typesubject-typestringSubject type of the comment, can be one of: line, file. Default is line.
Comment updated atupdated-atstringTime the comment was updated.
UseruserobjectUser who created the comment.

User

FieldField IDTypeNote
User ididintegerID of the user.
User URLurlstringURL of the user.

#Create Review Comment

Create a review comment in a pull request. The comment can be a general comment or a review comment. The comment can be on a specific line or on the PR as a whole.

InputIDTypeDescription
Task ID (required)taskstringTASK_CREATE_REVIEW_COMMENT
Owner (required)ownerstringOwner of the repository.
Repository (required)repositorystringRepository name.
PR Number (required)pr-numberintegerNumber of the PR.
Comment (required)commentobjectThe comment to be added.
Input Objects in Create Review Comment

Comment

The comment to be added.

FieldField IDTypeNote
Comment bodybodystringBody of the comment.
Commit SHAcommit-idstringSHA of the commit on which you want to comment.
Comment end linelineintegerThe line of the blob in the pull request diff that the comment applies to. For a multi-line comment, the last line of the range that your comment applies to.
Comment pathpathstringPath of the file the comment is on.
Comment end sidesidestringSide of the end line, can be one of: LEFT, RIGHT, side. LEFT is the left side of the diff (deletion), RIGHT is the right side of the diff (addition), and side is the comment on the PR as a whole. Default is side.
Enum values
  • LEFT
  • RIGHT
  • side
Comment start linestart-lineintegerThe first line in the pull request diff that your multi-line comment applies to. Only multi-line comment needs to fill this field.
Comment start sidestart-sidestringSide of the start line, can be one of: LEFT, RIGHT, side. LEFT is the left side of the diff (deletion), RIGHT is the right side of the diff (addition), and side is the comment on the PR as a whole. Default is side.
Enum values
  • LEFT
  • RIGHT
  • side
Comment typesubject-typestringSubject type of the comment, can be one of: line, file. Default is line.
Enum values
  • line
  • file
OutputIDTypeDescription
Comment ID (optional)idintegerID of the comment.
In Reply To (optional)in-reply-to-idintegerID of the comment this comment is in reply to.
Commit SHA (optional)commit-idstringSHA of the commit on which you want to comment.
Comment Body (optional)bodystringBody of the comment.
Comment Path (optional)pathstringPath of the file the comment is on.
Comment End Line (optional)lineintegerThe line of the blob in the pull request diff that the comment applies to. For a multi-line comment, the last line of the range that your comment applies to.
Comment Start Line (optional)start-lineintegerThe first line in the pull request diff that your multi-line comment applies to. Only multi-line comment needs to fill this field.
Comment End Side (optional)sidestringSide of the end line, can be one of: LEFT, RIGHT, side. LEFT is the left side of the diff (deletion), RIGHT is the right side of the diff (addition), and side is the comment on the PR as a whole. Default is side.
Comment Start Side (optional)start-sidestringSide of the start line, can be one of: LEFT, RIGHT, side. LEFT is the left side of the diff (deletion), RIGHT is the right side of the diff (addition), and side is the comment on the PR as a whole. Default is side.
Comment Type (optional)subject-typestringSubject type of the comment, can be one of: line, file. Default is line.
Comment Created At (optional)created-atstringTime the comment was created.
Comment Updated At (optional)updated-atstringTime the comment was updated.
User (optional)userobjectUser who created the comment.
Output Objects in Create Review Comment

User

FieldField IDTypeNote
User ididintegerID of the user.
User URLurlstringURL of the user.

#List Issues

Get the list of all issues in a repository,This can be a pull request or a general issue, and you can tell by the is-pull-request field.

InputIDTypeDescription
Task ID (required)taskstringTASK_LIST_ISSUES
Owner (required)ownerstringOwner of the repository.
Repository (required)repositorystringRepository name.
StatestatestringState of the issues, can be one of: open, closed, all. Default is open.
Enum values
  • open
  • closed
  • all
SortsortstringSort the issues by created, updated, popularity, or long-running. Default is created.
Enum values
  • created
  • updated
  • popularity
  • long-running
DirectiondirectionstringDirection of the sort, can be one of: asc, desc. Default is desc.
Enum values
  • asc
  • desc
SincesincestringDate (in YYYY-MM-DD format) from which issues will start to be fetched. The date will be in the UTC timezone.
No Pull Requestno-pull-requestbooleanWhether to not include pull requests in the response. Since issue and pr use the same indexing system in GitHub, the API returns all relevant objects (issues and pr). Default is false.
PagepageintegerPage number of the results to fetch. Default is 1.
Per Pageper-pageintegerNumber of results to fetch per page. Default is 30.
OutputIDTypeDescription
Issuesissuesarray[object]An array of issues.
Output Objects in List Issues

Issues

FieldField IDTypeNote
AssigneeassigneestringAssignee of the issue.
AssigneesassigneesarrayAssignees of the issue.
Issue bodybodystringBody of the issue.
Is Pull Requestis-pull-requestbooleanWhether the issue is a pull request.
LabelslabelsarrayLabels of the issue.
Issue NumbernumberintegerNumber of the issue.
Issue statestatestringState of the issue.
Issue titletitlestringTitle of the issue.

#Get Issue

Get an issue. This can be a pull request or a general issue, and you can tell by the is-pull-request field.

InputIDTypeDescription
Task ID (required)taskstringTASK_GET_ISSUE
Owner (required)ownerstringOwner of the repository.
Repository (required)repositorystringRepository name.
Issue Number (required)issue-numberintegerNumber of the issue.
OutputIDTypeDescription
Issue Number (optional)numberintegerNumber of the issue.
Issue State (optional)statestringState of the issue.
Issue Title (optional)titlestringTitle of the issue.
Issue Body (optional)bodystringBody of the issue.
Assignee (optional)assigneestringAssignee of the issue.
Assignees (optional)assigneesarray[string]Assignees of the issue.
Labels (optional)labelsarray[string]Labels of the issue.
Is Pull Request (optional)is-pull-requestbooleanWhether the issue is a pull request.

#Create Issue

Create an issue.

InputIDTypeDescription
Task ID (required)taskstringTASK_CREATE_ISSUE
Owner (required)ownerstringOwner of the repository.
Repository (required)repositorystringRepository name.
Issue Title (required)titlestringTitle of the issue.
Issue Body (required)bodystringBody of the issue.
Assigneesassigneesarray[string]Assignees of the issue.
Labelslabelsarray[string]Labels of the issue.
OutputIDTypeDescription
Issue Number (optional)numberintegerNumber of the issue.
Issue State (optional)statestringState of the issue.
Issue Title (optional)titlestringTitle of the issue.
Issue Body (optional)bodystringBody of the issue.
Assignee (optional)assigneestringAssignee of the issue.
Assignees (optional)assigneesarray[string]Assignees of the issue.
Labels (optional)labelsarray[string]Labels of the issue.
Is Pull Request (optional)is-pull-requestbooleanWhether the issue is a pull request.

#Create Webhook

Create a webhook for a repository.

InputIDTypeDescription
Task ID (required)taskstringTASK_CREATE_WEBHOOK
Owner (required)ownerstringOwner of the repository.
Repository (required)repositorystringRepository name.
Webhook URL (required)hook-urlstringURL to send the payload to.
Events (required)eventsarray[string]Events to trigger the webhook. Please see the github document for more information.
ActiveactivebooleanWhether the webhook is active. Default is false.
Content Typecontent-typestringContent type of the webhook, can be one of: json, form. Default is json.
Enum values
  • json
  • form
Hook Secrethook-secretstringIf provided, the secret will be used as the key to generate the HMAC hex digest value for delivery signature headers. (see the document).
OutputIDTypeDescription
Webhook ID (optional)idintegerID of the webhook.
Webhook URL (optional)urlstringURL of the webhook.
Ping URL (optional)ping-urlstringURL to ping the webhook.
Test URL (optional)test-urlstringURL to test the webhook.
Config (optional)configobjectConfiguration of the webhook.
Output Objects in Create Webhook

Config

FieldField IDTypeNote
Content Typecontent-typestringContent type of the webhook.
Insecure SSLinsecure-sslstringWhether the webhook is insecure.
Webhook URLurlstringURL of the webhook.

#Supported Events

WARNING

Only repository owners can configure event. Make sure you have owner permissions for the repository you want to monitor.

#Star Created Event

A star created event from GitHub.

ConfigurationIDTypeDescription
RepositoryrepositorystringThe repository to watch for star events.
Event MessageIDTypeDescription
ActionactionstringThe action performed (always "created").
Starred Atstarred-atstringThe time the star was created. This is a timestamp in ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ. Will be null for the deleted action.
RepositoryrepositoryobjectA git repository.
SendersenderobjectUser who performed the action.
Event Message Objects

Repository

FieldField IDTypeNote
IDidintegerUnique identifier of the repository.
Node IDnode-idstringThe GraphQL identifier of the repository.
NamenamestringThe name of the repository.
Full Namefull-namestringThe full, globally unique, name of the repository.
PrivateprivatebooleanWhether the repository is private or public.
OwnerownerobjectThe owner of the repository.
HTML URLhtml-urlstringThe URL to view the repository on GitHub.com.
DescriptiondescriptionstringThe repository description.
ForkforkbooleanWhether the repository is a fork.
URLurlstringThe URL to get more information about the repository from the GitHub API.
Forks URLforks-urlstringThe API URL to list the forks of the repository.
Keys URLkeys-urlstringA template for the API URL to get information about deploy keys on the repository.
Collaborators URLcollaborators-urlstringA template for the API URL to get information about collaborators of the repository.
Teams URLteams-urlstringThe API URL to list the teams on the repository.
Hooks URLhooks-urlstringThe API URL to list the hooks on the repository.
Issue Events URLissue-events-urlstringA template for the API URL to get information about issue events on the repository.
Events URLevents-urlstringThe API URL to list the events of the repository.
Assignees URLassignees-urlstringA template for the API URL to list the available assignees for issues in the repository.
Branches URLbranches-urlstringA template for the API URL to get information about branches in the repository.
Tags URLtags-urlstringThe API URL to get information about tags on the repository.
Blobs URLblobs-urlstringA template for the API URL to create or retrieve a raw Git blob in the repository.
Git Tags URLgit-tags-urlstringA template for the API URL to get information about Git tags of the repository.
Git Refs URLgit-refs-urlstringA template for the API URL to get information about Git refs of the repository.
Trees URLtrees-urlstringA template for the API URL to create or retrieve a raw Git tree of the repository.
Statuses URLstatuses-urlstringA template for the API URL to get information about statuses of a commit.
Languages URLlanguages-urlstringThe API URL to get information about the languages of the repository.
Stargazers URLstargazers-urlstringThe API URL to list the stargazers on the repository.
Contributors URLcontributors-urlstringA template for the API URL to list the contributors to the repository.
Subscribers URLsubscribers-urlstringThe API URL to list the subscribers on the repository.
Subscription URLsubscription-urlstringThe API URL to subscribe to notifications for this repository.
Commits URLcommits-urlstringA template for the API URL to get information about commits on the repository.
Git Commits URLgit-commits-urlstringA template for the API URL to get information about Git commits of the repository.
Comments URLcomments-urlstringA template for the API URL to get information about comments on the repository.
Issue Comment URLissue-comment-urlstringA template for the API URL to get information about issue comments on the repository.
Contents URLcontents-urlstringA template for the API URL to get the contents of the repository.
Compare URLcompare-urlstringA template for the API URL to compare two commits or refs.
Merges URLmerges-urlstringThe API URL to merge branches in the repository.
Archive URLarchive-urlstringA template for the API URL to download the repository as an archive.
Downloads URLdownloads-urlstringThe API URL to list the downloads on the repository.
Issues URLissues-urlstringA template for the API URL to get information about issues on the repository.
Pulls URLpulls-urlstringA template for the API URL to get information about pull requests on the repository.
Milestones URLmilestones-urlstringA template for the API URL to get information about milestones of the repository.
Notifications URLnotifications-urlstringA template for the API URL to get information about notifications on the repository.
Labels URLlabels-urlstringA template for the API URL to get information about labels of the repository.
Releases URLreleases-urlstringA template for the API URL to get information about releases on the repository.
Deployments URLdeployments-urlstringThe API URL to list the deployments of the repository.
Created Atcreated-atstring/integerThe time the repository was created.
Updated Atupdated-atstringThe time the repository was last updated.
Pushed Atpushed-atstring/integer/nullThe time the repository was last pushed to.
Git URLgit-urlstringThe Git URL to the repository.
SSH URLssh-urlstringThe SSH URL to the repository.
Clone URLclone-urlstringThe URL to clone the repository.
SVN URLsvn-urlstringThe SVN URL to the repository.
HomepagehomepagestringThe homepage URL of the repository.
SizesizeintegerThe size of the repository.
Stargazers Countstargazers-countintegerThe number of stargazers.
Watchers Countwatchers-countintegerThe number of watchers.
LanguagelanguagestringThe primary language of the repository.
Has Issueshas-issuesbooleanWhether issues are enabled.
Has Projectshas-projectsbooleanWhether projects are enabled.
Has Downloadshas-downloadsbooleanWhether downloads are enabled.
Has Wikihas-wikibooleanWhether the wiki is enabled.
Has Pageshas-pagesbooleanWhether GitHub Pages is enabled.
Has Discussionshas-discussionsbooleanWhether discussions are enabled.
Forks Countforks-countintegerThe number of forks.
Mirror URLmirror-urlstringThe URL of the repository mirror.
ArchivedarchivedbooleanWhether the repository is archived.
DisableddisabledbooleanWhether the repository is disabled.
Open Issues Countopen-issues-countintegerThe number of open issues.
LicenselicenseobjectThe license information.
ForksforksintegerThe number of forks.
Open Issuesopen-issuesintegerThe number of open issues.
WatcherswatchersintegerThe number of watchers.
Default Branchdefault-branchstringThe default branch of the repository.
Is Templateis-templatebooleanWhether the repository is a template.
Web Commit Signoff Requiredweb-commit-signoff-requiredbooleanWhether commit signoff is required.
Topicstopicsarray[string]List of repository topics.
VisibilityvisibilitystringVisibility level of the repository.
Custom Propertiescustom-propertiesobjectCustom properties of the repository.

Repository Owner

FieldField IDTypeNote
LoginloginstringThe username of the owner.
IDidintegerUnique identifier of the owner.
Node IDnode-idstringThe GraphQL identifier of the owner.
NamenamestringThe name of the owner.
EmailemailstringThe email of the owner.
Avatar URLavatar-urlstringURL of the owner's avatar image.
Gravatar IDgravatar-idstringThe owner's Gravatar ID.
URLurlstringThe URL to the owner's GitHub profile.
HTML URLhtml-urlstringThe HTML URL to the owner's GitHub profile.
Followers URLfollowers-urlstringThe URL to list the owner's followers.
Following URLfollowing-urlstringThe URL to list who the owner follows.
Gists URLgists-urlstringThe URL to list the owner's gists.
Starred URLstarred-urlstringThe URL to list repositories the owner has starred.
Subscriptions URLsubscriptions-urlstringThe URL to list the owner's subscriptions.
Organizations URLorganizations-urlstringThe URL to list the owner's organizations.
Repos URLrepos-urlstringThe URL to list the owner's repositories.
Events URLevents-urlstringThe URL to list the owner's events.
Received Events URLreceived-events-urlstringThe URL to list events received by the owner.
TypetypestringType of account (Bot, User, or Organization).
Site Adminsite-adminbooleanWhether the owner is a GitHub admin.

Sender

FieldField IDTypeNote
LoginloginstringThe username of the sender.
IDidintegerUnique identifier of the sender.
Node IDnode-idstringThe GraphQL identifier of the sender.
Avatar URLavatar-urlstringURL of the sender's avatar image.
Gravatar IDgravatar-idstringThe sender's Gravatar ID.
URLurlstringThe URL to the sender's GitHub profile.
HTML URLhtml-urlstringThe HTML URL to the sender's GitHub profile.
Followers URLfollowers-urlstringThe URL to list the sender's followers.
Following URLfollowing-urlstringThe URL to list who the sender follows.
Gists URLgists-urlstringThe URL to list the sender's gists.
Starred URLstarred-urlstringThe URL to list repositories the sender has starred.
Subscriptions URLsubscriptions-urlstringThe URL to list the sender's subscriptions.
Organizations URLorganizations-urlstringThe URL to list the sender's organizations.
Repos URLrepos-urlstringThe URL to list the sender's repositories.
Events URLevents-urlstringThe URL to list the sender's events.
Received Events URLreceived-events-urlstringThe URL to list events received by the sender.
TypetypestringType of account (Bot, User, or Organization).
Site Adminsite-adminbooleanWhether the sender is a GitHub admin.

#Example Recipes

Summarise and pick the most important issues from this list

Recipe for the List GitHub Repo Issues pipeline.


version: v1beta
component:
anthropic-0:
type: anthropic
task: TASK_TEXT_GENERATION_CHAT
input:
max-new-tokens: 1000
model-name: claude-3-5-sonnet-latest
prompt: Summarise and pick the most important issues from this list ${github.output.issues}
system-message: You are a helpful assistant.
temperature: 0.7
top-k: 10
github:
type: github
task: TASK_LIST_ISSUES
input:
direction: desc
no-pull-request: false
owner: ${variable.repository-owner}
page: 1
per-page: 30
repository: ${variable.repository-name}
since: "2021-01-01T00:00:00Z"
sort: created
state: open
setup:
token: ${secret.github-demo}
variable:
repository-name:
title: Repository Name
description: Name of the repository i.e. instill-core
format: string
repository-owner:
title: Repository Owner
description: Name of the repository owner i.e. instill-ai
format: string
output:
result:
title: Result
value: ${anthropic-0.output.text}

Send a message to Slack when a repository is starred


# VDP Version
version: v1beta
on:
github-0:
type: github
event: EVENT_STAR_CREATED
config:
repository: instill-ai/instill-core
setup: ${connection.my-github-connection}
variable:
repository:
title: repository
format: string
listen:
- ${on.github-0.message.repository.full-name}
user:
title: user
format: string
listen:
- ${on.github-0.message.sender.login}
description:
title: user
format: string
listen:
- ${on.github-0.message.repository.description}
stargazers-count:
title: stargazers-count
format: number
listen:
- ${on.github-0.message.repository.stargazers-count}
output:
text:
value: ${variable.repository} ${variable.user}
component:
slack-0:
type: slack
input:
channel-name: test-slack
message: |
${variable.user} just starred ${variable.repository}!
*Repository Details:*
• Description: ${variable.description}
• Total Stars: ${variable.stargazers-count}
as-user: false
condition:
setup: ${connection.my-slack-connection}
task: TASK_WRITE_MESSAGE