[問題] get api一直回覆400 bad request
我目前在嘗試用第三方的API提供股票報價的資訊
有得到token跟網址,正常直接用瀏覽器get的時候,都能成功得到一個json格式的資料
但是不知道為什麼
改成用程式get,都會一直提示我400 bad request
我是用axios的get method,應該原理是跟瀏覽器差不多才對
不知道問題出在哪邊,想請各位指教
ps:我是自學的程式新手,可能有部分知識沒學全,所以問題可能比較基礎
https://iexcloud.io/
Sandbox token:
https://sandbox.iexapis.com/stable/stock/TSLA/quote?token=Tpk_1f7ac84b1178430ba2db2dc2427cced9
https://i.imgur.com/rijVIC1.png



--
※ 發信站: 批踢踢實業坊(ptt.cc), 來自: 203.77.42.109 (臺灣)
※ 文章網址: https://www.ptt.cc/bbs/Ajax/M.1606376266.A.24D.html
→
11/26 21:11,
4年前
, 1F
11/26 21:11, 1F
→
11/26 21:11,
4年前
, 2F
11/26 21:11, 2F
→
11/26 21:12,
4年前
, 3F
11/26 21:12, 3F
→
11/26 21:12,
4年前
, 4F
11/26 21:12, 4F
→
11/26 21:13,
4年前
, 5F
11/26 21:13, 5F
→
11/26 21:13,
4年前
, 6F
11/26 21:13, 6F
哇,太感謝了
原本以為沒差,沒想到改了之後還真的可以了
※ 編輯: jeffguoft (203.77.42.109 臺灣), 11/27/2020 00:41:21
Ajax 近期熱門文章
PTT數位生活區 即時熱門文章