Skip to content

Commit

Permalink
fix: add client_id field to pkce auth example.
Browse files Browse the repository at this point in the history
  • Loading branch information
ErichKramer committed Oct 1, 2024
1 parent 5c1be56 commit 6db6de3
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions examples/authenticate/pkce/pkce.go
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ import (
"fmt"
spotifyauth "github.com/zmb3/spotify/v2/auth"
"log"
"os"
"net/http"

"golang.org/x/oauth2"
Expand Down Expand Up @@ -45,6 +46,7 @@ func main() {
url := auth.AuthURL(state,
oauth2.SetAuthURLParam("code_challenge_method", "S256"),
oauth2.SetAuthURLParam("code_challenge", codeChallenge),
oauth2.SetAuthURLParam("client_id", os.Getenv("CLIENT_ID")),
)
fmt.Println("Please log in to Spotify by visiting the following page in your browser:", url)

Expand Down

0 comments on commit 6db6de3

Please sign in to comment.