Send ThriveCart data to a Slack channel

by Dave | thrivecart

ThriveCart slack, I’m going show you how to send over information from ThriveCart to your Slack channel. And to do that we need to set up a slack web hook and channel will also need to create a web hooks script on your server. And then we’ll set up aThriveCart web hook and finally test. So let’s go ahead and dive right in.

So first thing to do is you’re going to have to log into your slack account from here to set up a web hook. So let’s look for slack Incoming webhook. I’m going to go here, doesn’t matter how you get there, as long as you’re logged in. So I’m going to go ahead and click on incoming webhook integration that’s what I want to do. I’m already logged in and right now saying, Where do you want to post this to, and I haven’t created any channel. So I’m going to go ahead and create a channel right here calledThriveCart and I’m going to go ahead and do that could make it private, but I’m just gonna leave it as is.

And then we want to go ahead and add incoming web hook. So the important part is simply this right here, we want to copy this web hook URL and save it for what we’re going to do next. So next thing to do is create a script on your server and you can copy this and make modifications, I’m going to put in a subdirectory called API and it’s going to be a file called index.php, I want to paste in that URL I just copied into here and then I want to provide a secret key. This is kind of a safety feature, I don’t want any people anyone trying to visit this URL and posting information.

I’m just going to put something random like that for now, I want to allow test transactions, you probably want to put this to no and I also want to put it debug so error logs information, not a requirement but if there’s any issues, it’s useful, I’m actually going to turn off but I definitely want to do this set to Yes, for now. So next thing to do is going toThriveCart and set up a web hook.

So I need to know my secret key, I need to know that directory or the location and I’ll show you what’s next. So go into yourThriveCart account, you’re going to go to settings, API and web hooks, web hook and notifications and you want to add another web hook or create the first one I’m going to call it slack and I want to go visit the URL just to make sure it doesn’t right there.

So there and I also want to append my secret key secret equals go back to the script I want to copy that secret key now back to the browser. Now nothing should show up there, so let’s go back toThriveCart and paste that link in there and I’m going to go ahead and click on save this web hook let’s go take a look at slack so there’s myThriveCart channel I’m going to go ahead and make a test purchase and I should have some information show up here shortly.

So let’s go get a product and it’s going to be in test mode so we’re gonna go ahead and make a test purchase and they just heard the data from slack and there we go. We’ve got a new message it shows what happened on all the details of the customer the amount of money they spent everything so that’s how you can connect ThriveCart with.