title: Flask JWT extend validity of token on each request
body: <h1>Scenario</h1>
  
  <p>A logged in user will have a token expiry of 24 hours. Within that period, all request with <code>@jwt_required</code> decorator will have the <em>current</em> access token's expiry extended by another 24 hours. There is a maximum validity of 168(24 * 7) hours. </p>
  
  <p>It is possible to use access_token and refresh_token.</p>
  
  <pre><code>ret = {
          'access_token': create_access_token(identity=username, fresh=True),
          'refresh_token': create_refresh_token(identity=username)
      }
  </code></pre>
  
  <p>But that means every API call from my applicatino will be two requests:
  1. Actual HTTP Request
  2. Refresh the auth token</p>
  
  <pre><code>@app.route('/refresh', methods=['POST'])
  @jwt_refresh_token_required
  def refresh():
      current_user = get_jwt_identity()
      ret = {
          'access_token': create_access_token(identity=current_user)
      }
      return jsonify(ret), 200
  </code></pre>
  
  <p>Is there a way to implicitly extend an auth token?</p>