original_string: public function requestAccessToken($code, $redirectUri, $expiresIn = null, $state = null)
      {
          $parameters = [
              'code' => $code,
              'grant_type' => 'authorization_code',
              'client_id' => $this->clientId,
              'redirect_uri' => $redirectUri,
          ];
  
          if ($expiresIn != null) {
              $parameters['expires_in'] = $expiresIn;
          }
  
          if ($state != null) {
              $parameters['state'] = $state;
          }
  
          return $this->tokenRequest('oauth2/token', $parameters);
      }
code: public function requestAccessToken($code, $redirectUri, $expiresIn = null, $state = null)
      {
          $parameters = [
              'code' => $code,
              'grant_type' => 'authorization_code',
              'client_id' => $this->clientId,
              'redirect_uri' => $redirectUri,
          ];
  
          if ($expiresIn != null) {
              $parameters['expires_in'] = $expiresIn;
          }
  
          if ($state != null) {
              $parameters['state'] = $state;
          }
  
          return $this->tokenRequest('oauth2/token', $parameters);
      }
code_tokens: public function requestAccessToken ( $ code , $ redirectUri , $ expiresIn = null , $ state = null ) { $ parameters = [ 'code' => $ code , 'grant_type' => 'authorization_code' , 'client_id' => $ this -> clientId , 'redirect_uri' => $ redirectUri , ] ; if ( $ expiresIn != null ) { $ parameters [ 'expires_in' ] = $ expiresIn ; } if ( $ state != null ) { $ parameters [ 'state' ] = $ state ; } return $ this -> tokenRequest ( 'oauth2/token' , $ parameters ) ; }
docstring: Request new Fitbit access token.
  
  @param string $code code from Fitbit
  @param string $redirectUri redirect uri used to get code
  @param int|null $expiresIn set length of token
  @param string|null $state This parameter will be added to the redirect URI exactly as your application specifies.
  @return ResponseInterface response from Fitbit API
docstring_tokens: Request new Fitbit access token .