maknz / slack

A simple PHP package for sending messages to Slack, with a focus on ease of use and elegant syntax.
BSD 2-Clause "Simplified" License
1.17k stars 204 forks source link

Are there markdown custom message to laravel 5.1 in this library? #88

Open arturcesarmelo opened 7 years ago

arturcesarmelo commented 7 years ago

I would like to use something like this.


return (new SlackMessage())
        ->from("New user request on " . config("app.name"))
        ->content(":bangbang: An user has requested a new feedback on " . config("app.name"))
        ->attachment(function ($attachment) use ($notifiable) {
            $attachment->title("Feedback ID: {$notifiable->uuid}")
                ->content("**You can moderate this feedback right away**")
                ->markdown(["title", "text"])
                ->fields([
                    "Request from" => "{$notifiable->user->name} (ID: {$notifiable->user->uuid})",
                    "Request topic" => "{$notifiable->topic->name}",
                ]);
        });