{"record":{"id":"3f3056de9904b3be","repo":"Seldaek/monolog","slug":"the-curl-extension-is-needed-to-use-the-slackwebho","errorCode":null,"errorMessage":"The curl extension is needed to use the SlackWebhookHandler","messagePattern":"The curl extension is needed to use the SlackWebhookHandler","errorType":"exception","errorClass":"MissingExtensionException","httpStatus":null,"severity":"error","filePath":"src/Monolog/Handler/SlackWebhookHandler.php","lineNumber":65,"sourceCode":"     * @param bool        $includeContextAndExtra Whether the attachment should include context and extra data\n     * @param string[]    $excludeFields          Dot separated list of fields to exclude from slack message. E.g. ['context.field1', 'extra.field2']\n     *\n     * @throws MissingExtensionException If the curl extension is missing\n     */\n    public function __construct(\n        string $webhookUrl,\n        ?string $channel = null,\n        ?string $username = null,\n        bool $useAttachment = true,\n        ?string $iconEmoji = null,\n        bool $useShortAttachment = false,\n        bool $includeContextAndExtra = false,\n        $level = Level::Critical,\n        bool $bubble = true,\n        array $excludeFields = []\n    ) {\n        if (!\\extension_loaded('curl')) {\n            throw new MissingExtensionException('The curl extension is needed to use the SlackWebhookHandler');\n        }\n\n        parent::__construct($level, $bubble);\n\n        $this->webhookUrl = $webhookUrl;\n\n        $this->slackRecord = new SlackRecord(\n            $channel,\n            $username,\n            $useAttachment,\n            $iconEmoji,\n            $useShortAttachment,\n            $includeContextAndExtra,\n            $excludeFields\n        );\n    }\n\n    public function getSlackRecord(): SlackRecord","sourceCodeStart":47,"sourceCodeEnd":83,"githubUrl":"https://github.com/Seldaek/monolog/blob/57eb1028342134e701e77c617565d51b6e5a2a53/src/Monolog/Handler/SlackWebhookHandler.php#L47-L83","documentation":"Error \"The curl extension is needed to use the SlackWebhookHandler\" thrown in Seldaek/monolog.","triggerScenarios":"Thrown at src/Monolog/Handler/SlackWebhookHandler.php:65 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":[],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"57eb1028342134e701e77c617565d51b6e5a2a53","analyzedAt":"2026-08-17T02:36:30.259Z","schemaVersion":2},"datasetVersion":"2026-08-17T04:17:16.089Z"}