laf/docs/guide/function/call-function-in-http.md
nightwhite 75ba39a3f6
doc: optimize cloud function documents and database documents (#1076)
* doc: optimize cloud function documents and database documents

* doc: fix eq link

* doc: change database policy position

* doc: small adjustment

* doc: optimize automatic compilation

* doc: optimize homepage copy and top buttons

* doc: add ignore docs Address
2023-04-25 12:14:19 +08:00

379 B

HTTP 调用

云函数每个云函数都提供了 API 地址,理论上我们可以在任何能发起 http 请求的地方调用云函数。

function-url

下面是用前端使用 axios 请求云函数的简单示例。

const { data } = await axios({
  url: "<FunctionURL>",
  method: "get",
});

console.log(data);