Skip to content

Navigation Menu

Sign in
Sign up

How To Generate an Bearer Token by API Key? #22

Unanswered
Stefan-WW asked this question in Q&A
Discussion options

Hello,

i couldn't find any informations how to get an Bearer Token. Can someone help me?
i have now an api key registered.

But how to get the Bearer Token?

As far as i know, there should be an oAuth endpoint

`curl -X POST "https://api.example.com/oauth/token" \

 -H "Content-Type: application/json" \
 -d '{"api_key": "YOUR_API_KEY"}'

`

But i couldn't find something like that in the op3 documentation.
The Download Button for the specification seems to be broken.
image

Can someone help me?

Kind Regards
Stefan

You must be logged in to vote

Replies: 2 comments

Comment options

It's easier than that, the bearer token is available in the second box when you first create a new api key. Think of the api key as the Account ID. I should probably rename it.

You can regen a new bearer token for an existing api key in the https://op3.dev/api/keys page. It's only displayed once for security purposes.

You must be logged in to vote
0 replies
Comment options

For some reason, I thought the api key was the token, and I didn't realize I had to "regen" once to get my first token.
@johnspurlock-skymethod Maybe if there isn't an existing token, you could label this button "Generate token" for the first time?

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet

AltStyle によって変換されたページ (->オリジナル) /