Payment to Slack and Notion

automation · by zorilla · came with Zorilla

Turns each new Stripe payment into a Slack message and a Notion row. Needs keys named stripe_key, slack_key and notion_key.

New Stripe paymentFires when a payment goes thr…Post to Slack#salesAdd a Notion pagenotion.createPage

3 steps, drawn from the file

What this can do

Read out of the file, not written by the author.

contacts api.notion.comcontacts api.stripe.comcontacts slack.com

Uses your saved keys named notion_keyslack_keystripe_key. It binds to your own keys of those names. No key travels in the file.

3 steps, started by New Stripe payment.

Contents
{
  "name": "Payment to Slack and Notion",
  "nodes": [
    {
      "id": "paid",
      "type": "stripe.newCharge",
      "params": {
        "credential": "stripe_key",
        "every": 5,
        "unit": "minutes"
      },
      "position": {
        "x": 40,
        "y": 170
      }
    },
    {
      "id": "slack",
      "type": "slack.post",
      "params": {
        "credential": "slack_key",
        "channel": "#sales",
        "text": "${{ ($json.amount / 100).toFixed(2) }} from {{ $json.billing_details.email }}"
      },
      "position": {
        "x": 300,
        "y": 170
      }
    },
    {
      "id": "notion",
      "type": "notion.createPage",
      "params": {
        "credential": "notion_key",
        "databaseId": "put-your-database-id-here",
        "properties": "{\"Name\":{\"title\":[{\"text\":{\"content\":\"{{ $json.id }}\"}}]}}"
      },
      "position": {
        "x": 300,
        "y": 320
      }
    }
  ],
  "edges": [
    {
      "from": "paid",
      "fromPort": "main",
      "to": "slack",
      "toPort": "main"
    },
    {
      "from": "paid",
      "fromPort": "main",
      "to": "notion",
      "toPort": "main"
    }
  ]
}
Back

Download it, then in Zorilla press add one from a file. You get a screen listing what it contacts and which keys it asks for before anything is saved.