Skip to content

Instantly share code, notes, and snippets.

- name: Custom Team Check
uses: actions/github-script@v7
with:
github-token: ${{ secrets.MY_PAT }}
script: |
const { data: membership } = await github.rest.teams.getMembershipForUserInOrg({
org: 'your-org-name',
team_slug: 'your-team-slug',
username: context.actor,
});