我如何预先填写日历客人的电子邮件?

How can i prefill calendly guests email?

我使用initPopupWidget传递了预填充数据。

window?.Calendly.initPopupWidget({
  url: schedulePageUrl,
  prefill: {
    email: auth.email,
    firstName: "",
    lastName: "",
    name: "",
    guests: ["test1@gmail.com", "test2@gmail.com"],
  },
});

但是表格是空的,email填充成功。我还单击 Add Guests 按钮打开 来宾电子邮件 归档。

guests 预填充值应该是一串以逗号分隔的值。您可以将代码更新为以下内容以解决此问题:

window?.Calendly.initPopupWidget({
  url: schedulePageUrl,
  prefill: {
    email: auth.email,
    firstName: "",
    lastName: "",
    name: "",
    guests: ["test1@gmail.com", "test2@gmail.com"].join(','),
  },
});