Migrate to Netlify Today

Netlify announces the next evolution of Gatsby Cloud. Learn more

ContactSign Up
Community Plugin
View plugin on GitHub

@alexjorgef/gatsby-source-github

Source playlists from GitHub into Gatsby (based on DSchau/gatsby-source-github).

Install

npm install @alexjorgef/gatsby-source-github

How to use

Add the plugin to your gatsby-config file:

gatsby-config.js
module.exports = {
  plugins: [
    {
      resolve: `@alexjorgef/gatsby-source-github`,
      options: {}
    }
  ]
}

Plugin Options

accessToken (required)

The GitHub API access token used for authentication.

Field type: string

{
  resolve: `@alexjorgef/gatsby-source-github`,
  options: {
    accessToken: `ghp_xxxxxxxxxxxxxxxxxxxxx`,
  },
}

queries (required)

List of search queries to execute against the GitHub API.

Field type: string[]

{
  resolve: `@alexjorgef/gatsby-source-github`,
  options: {
    queries: [
      `{
        repository(owner: "torvalds", name: "linux") {
          name
          url
        }
      }`,
      `{
        repository(owner: "gatsbyjs", name: "gatsby") {
          name
          url
          stargazerCount
        }
      }`,
    ]
  },
}

apiUrl (optional)

The GitHub API URL to use.

Field type: string

{
  resolve: `@alexjorgef/gatsby-source-github`,
  options: {
    apiUrl: `https://api.github.com/graphql`,
  },
}
© 2026 Gatsby, Inc.