필터 지우기
필터 지우기

Retrieving Oauth1.0a Access Token (Etrade API)

조회 수: 5 (최근 30일)
tane martin
tane martin 2020년 5월 13일
댓글: Andreas Raue 2024년 1월 29일
Does anyone have any experience with Oauth1.0a? Specifically I'm having difficulty with getting the Access Token when using Matlab to access Etrade's API. Everything runs smoothly up to that point, but when I make the call to their Get Access Token API it returns an error stating my Request Token is invalid or expired. Since I'm well within the 5-minute expiration time for the token, it has to be invalid for some reason, but I can't figure out why (since I'm doing exactly the same process as I did for Get Request Token, but with the addition of the Token Secret to the signature key, and the verifier in the Auth header.
In attached script, I'm stuck at line 83, in function "get_access_token1". The funcitons are all wrapped in a class EtradeOauth, that is constructed by EtradeOauth(CONSUMERKEY, CONSUMERSECRET). Most of it is built based on Andy Campbel'sl post about linking to Twitter's API which was really helpful, but unless I'm mistaken (and I easily could be), he never had to request or use an Access Token. Does anyone have any experience with Oauth 1.0a or Etrade's API? Any eagle eyes see what's wrong in my script?
  댓글 수: 1
Andreas Raue
Andreas Raue 2024년 1월 29일
I am curious, did you ever get the Etrade API to work properly in MATLAB? Any advice?

댓글을 달려면 로그인하십시오.

답변 (1개)

meng xiao
meng xiao 2021년 12월 5일
it seems you need to add following to ine 55, and it will work
params.oauth_token=pct_decode(params.oauth_token);

카테고리

Help CenterFile Exchange에서 Entering Commands에 대해 자세히 알아보기

제품


릴리스

R2018b

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by