diff --git a/config-example.php b/config-example.php index 66ed01e..431cef9 100644 --- a/config-example.php +++ b/config-example.php @@ -1,67 +1,67 @@ ClickUp bot # Copyright (C) 2023 Valerio Bozzolan, contributors # # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation, either version 3 of the License, or # (at your option) any later version. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program. If not, see . // ClickUp Team ID - you can find it from your home URL // Example: "123" if your home URL is "https://app.clickup.com/123/v/l/li/456456456456" define( 'CLICKUP_TEAM_ID', 123 ); -// URL exposing the "clickup-webhook" directory from this repository +// URL exposing the "webhook-clickup" directory from this repository // NOTE: this MUST be a valid and public URL so ClickUp can use that as webhook // NOTE: the checkorigin token is just a random token you should invent -define( 'CLICKUP_WEBHOOK_PUBLIC_ENDPOINT', 'https://example.com/clickup-phabricator-phorge-bot/clickup-webhook/?checkorigintoken=abcdefghilmpopqrstuvz123' ); +define( 'CLICKUP_WEBHOOK_PUBLIC_ENDPOINT', 'https://example.com/clickup-phabricator-phorge-bot/webhook-clickup/?checkorigintoken=abcdefghilmpopqrstuvz123' ); // obtained after registering the webhook using register-webhook.php define( 'CLICKUP_REGISTERED_WEBHOOK_ID', '123-123-123-123-123' ); // keep this in sync with the random token you invented in CLICKUP_WEBHOOK_PUBLIC_ENDPOINT define( 'CLICKUP_WEBHOOK_CHECKORIGINTOKEN', 'abcdefghilmpopqrstuvz123' ); // when true, CLICKUP_WEBHOOK_PUBLIC_ENDPOINT is compared to the one in CLICKUP_WEBHOOK_PUBLIC_ENDPOINT define( 'CLICKUP_VALIDATE_WEBHOOK', true ); // https://app.clickup.com/36232585/settings/apps define( 'CLICKUP_API_TOKEN', 'pk_123_ASD123' ); // ClickUp cache (connecting its stuff to Phabricator, avoid creating duplicate tasks, etc.) define( 'CLICKUP_CACHE_JSON_FILE', __DIR__ . '/data/cache.json' ); // ClickUp cache pretty print define( 'CLICKUP_CACHE_JSON_PRETTY', true ); // Phabricator home URL (to call API) // MUST end with a slash define( 'PHABRICATOR_URL', 'https://sviluppo.erinformatica.it/' ); // path to the Arcanist library of your Phabricator installation (to call APIs) define( 'PHABRICATOR_ARCANIST_PATH', '/var/www/phabricator/arcanist/support/init/init-script.php' ); // Phabricator Conduit API token // at the moment it's in use the one from the user er.clickup.bot in ER Phabricator // https://sviluppo.erinformatica.it/p/er.clickup.bot/ // To generate a new one: // https://sviluppo.erinformatica.it/conduit/token/edit/15/ define( 'PHABRICATOR_CONDUIT_API_TOKEN', 'api-asd123' ); // validate the exact webhook URL // if it does not match it does nothing // this is useful if you put some very weird and secret query strings here: // CLICKUP_WEBHOOK_PUBLIC_ENDPOINT define( 'CLICKUP_VALIDATE_WEBHOOK', true ); // homepage of the project // just to know where you can send bugs define( 'REPOSITORY_URL', 'https://gitpull.it/source/clickup-phabricator-bot/' ); diff --git a/public/clickup-webhook/index.php b/public/webhook-clickup/index.php similarity index 100% rename from public/clickup-webhook/index.php rename to public/webhook-clickup/index.php