Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

前端取得月曆資料的 API 改用 GET method #9

Open
amliu opened this issue Oct 10, 2018 · 2 comments
Open

前端取得月曆資料的 API 改用 GET method #9

amliu opened this issue Oct 10, 2018 · 2 comments

Comments

@amliu
Copy link

amliu commented Oct 10, 2018

目前前端抓取首頁月曆資料是使用 POST method ,應該只需要使用 GET

@SuJiaKuan
Copy link
Member

關於取得月曆資料的API: /events/query,不論是用GET或是POST都可以達成,只是在下參數時會有差別:

  • GET要將參數放在URL的query string
  • POST要將參數放在body

當初設計會使用POST是考量會用到https,因此傳輸過程中body裡面的內容會受到加密,減少一些資訊曝光的可能。不過如果在我們狀況是不用考慮到這個部份,改成GET也是無妨的。

@dreamcwli
Copy link
Collaborator

URL 的 query parameter 在走 HTTPS 的時候是會受到 SSL/TLS 保護的,
如果只是這個考量修改為 GET method 不會有差異。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants