網誌文章封存
測試OpenAI API
要先有OpenAI的帳號,還要拿到API 密鑰。
下面是步驟
1. 進入OpenAI Platform的網頁
https://platform.openai.com/docs/overview
![](https://analyticsapps.wordpress.com/wp-content/uploads/2024/06/screen-shot-2024-06-23-at-8.08.46-pm.png?w=1024)
如果沒有帳號,先申請一個。
2. 然後建立一個專案
點左下角的 Create Project,我起的名字是 HelloWorld.
3. 進入 API的網頁,建立 密鑰 (API key)
點 Start Building
![](https://analyticsapps.wordpress.com/wp-content/uploads/2024/06/screen-shot-2024-06-23-at-8.11.40-pm.png?w=1024)
進入下一個網頁
點左下的 API Keys
![](https://analyticsapps.wordpress.com/wp-content/uploads/2024/06/screen-shot-2024-06-23-at-8.16.11-pm.png?w=1024)