ecency/hivesigner-sdk

Create access token using refresh token

Closed this issue · 4 comments

Need clarification on these two issues

  1. What is client_id here? is it hive username? I am getting a code if I use hivesigner or a hive username or hive.blog (https://hivesigner.com/oauth2/authorize?client_id=CLIENT_ID&redirect_uri=REDIRECT_URI&response_type=code&scope=offline,comment,vote,comment_option,custom_json)
  2. I got the access_token, refresh_token, expires_in and username. But how do I use that refresh_token to create a new access_token? There is no mention of this in the docs.

Hi,

  1. Yes
  2. Check here, there is way to generate access token with refresh token mentioned here: https://docs.hivesigner.com/h/guides/get-started/hivesigner-oauth2

token_expiration is 604800. I have checked the code it is hardcoded. is it in seconds?

@josephkhanssd yes, 7 days. Your application should handle expiry logic.

@feruzm Got it. Thanks