Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

When will support for new Personal Access Tokens instead of API Keys begin? #61

Open
briemarie opened this issue Nov 30, 2016 · 5 comments · May be fixed by #103
Open

When will support for new Personal Access Tokens instead of API Keys begin? #61

briemarie opened this issue Nov 30, 2016 · 5 comments · May be fixed by #103

Comments

@briemarie
Copy link

According to the Intercom docs, API Keys are deprecated and will be fully replaced with a Personal Access Token in January 2017. I was expecting NewClient to support this change already ie.
ic := intercom.NewClient("appID", "apiKey") would be ic := intercom.NewClient("pat")

When can we expect the package to update to support this change?

@josler
Copy link
Contributor

josler commented Dec 9, 2016

Hi @briemarie - this should work right now by passing the PAT where you would normally pass the appID, and send an empty string where the API key would normally be.

@timhudson
Copy link

The API documentation for Personal Access Tokens is explicit about using the Bearer authorization type. It looks like the solution mentioned above works since the Basic authorization type is overloaded to accept a PAT where username usually goes.

@josler I can't find any documentation for the overloading. Is that a stable API feature I can depend on?

@kant01ne
Copy link

Hey @timhudson
The API documentation recommend to use bearer tokens but basic auth should work too so you can safely use @josler's solution above.

@choran
Copy link
Member

choran commented Aug 21, 2017

Just to note that we did update the README here to clarify how to use access tokens to authorize access
ic := intercom.NewClient("access_token", "")
But we will create bearer access for this once we get a chance so will leave it open for now

@zwass
Copy link

zwass commented Apr 12, 2018

This also needs to be updated in the GoDoc (https://godoc.org/gopkg.in/intercom/intercom-go.v2#NewClient). It just misled me and resulted in a fair bit of time debugging.

@mmartinic mmartinic added dev and removed dev labels Jul 5, 2018
@keloe keloe added dev and removed dev labels Jul 5, 2018
@choran choran added the go label Sep 13, 2018
@alecha alecha linked a pull request Oct 22, 2018 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

8 participants