🔑 百度 AI Access Token

💡 跨域解决方案说明

本 Demo 使用 Edge Function 作为代理,

解决前端直接请求百度 API 的跨域问题。

/api/token
百度 OAuth API
client_credentials

✅跨域请求成功!

📁 项目结构

edgeone-cors-demo/
├── index.html                    # 前端页面
└── edge-functions/
    └── api/
        └── token.js               # Edge Function 代理