在测试步骤中,我无法从我的站点到 zapier 应用程序中找到有关可接受的响应内容或代码状态的信息。
我在这个网站的 Laravel 和 Zapier 应用程序上有我的网站。在我的 Zapier 应用程序中,我有一个操作:“创建新项目”。我根据示例进行了“创建” 。除测试步骤外,一切正常。我使用以下 zap 进行了测试:
- Trello ->“创建新卡”触发器。测试成功。
- 我的应用程序->“创建新项目”。测试失败,出现
We had trouble sending your test through. Could not handle special, non-standard characters. Please contact support
.
奇怪的是,项目创建成功。因此,我认为问题在于我的网站对 zapier 的响应:
// creates/project.js
// My perform function:
perform: (z, bundle) => {
const promise = z.request({
url: `${process.env.BASE_URL}/api/folder`,
method: 'POST',
body: JSON.stringify({
title: bundle.inputData.title,
}),
headers: {
'content-type': 'application/json',
}
});
return promise.then((response) => JSON.parse(response.content));
}
//ZapierController.php
public function addFolder(Request $request)
{
// Made record to DB, and other, after this returned same data which in request
return response()->json(['title' => $request['title']]);
}
预期结果 - “测试此步骤”测试成功。谁能帮我?