INNER CODE UNIT · JavaScript
setupWebhookServer
alohe/quicky · index.js:497
async function setupWebhookServer() {
const config = readConfig();
const { webhookUrl } = await inquirer.prompt([
{
type: "input",
name: "webhookUrl",
message:
"Enter the URL where the webhook will be received (e.g., quicky.example.com):",
validate: (input) => {
if (input.trim() === "") return "URL is required.";
if (
(config.domains || []).some(
(d) => d.domain === input.trim(),
)
)
return "This domain is already in use. Please enter a different URL.";
return true;