cal/packages/app-store/zapier
Leo Giovanetti 1010e2894a
Bringing back sendgrid app to review (#5501)
* Sendgrid app and code simplification

* Applying app-store-cli + impl

* Fixing types

* Adding features to readme

* Fixing unit tests

* A few last tweaks regarding UX and env vars

* Applying feedback

* Using calcom icons

* Renaming and applying feedback

* Testing user/type page fix

* Standarizing Sendgrid client usage

* Removing types

* Reverting CloseCom changes

* Stop relying on sendgrid client pkg

* Fixing button and more reverting closecom changes

* Revert "Stop relying on sendgrid client pkg"

This reverts commit dd61851572.

* Revert "Removing types"

This reverts commit 1ec5ed8de2.

* Is this it?

* Standardizing apis

* Fixing path

* Fixing throwing errors the standard way

* Stop relying on getInstalledAppPath

* Removing seemingly troubling code

* Returning error and avoiding any outer reference

* Revert "Returning error and avoiding any outer reference"

This reverts commit 7d32e30154.

* Revert "Removing seemingly troubling code"

This reverts commit eaae772abc.

* Revert "Stop relying on getInstalledAppPath"

This reverts commit bcc70fc337.

* Revert "Fixing throwing errors the standard way"

This reverts commit bb1bb410fa.

* Revert "Fixing path"

This reverts commit a7bd83c4fb.

* Revert "Standardizing apis"

This reverts commit 0258a18229.

* Revert "Is this it?"

This reverts commit 70b3f7b98e.

* Converting APIs to legacy style

* Missing reverted CloseCom test mock

* Needed for the renaming

* Reverting Closecom and yarn unneeded changes

* Ununsed type

* Testing rearranging exports

* Update apps/web/components/apps/OmniInstallAppButton.tsx

Co-authored-by: Omar López <zomars@me.com>

* Standardizing APIs

* Fixing wrong toast message on app page

Co-authored-by: Peer Richelsen <peeroke@gmail.com>
Co-authored-by: Omar López <zomars@me.com>
2022-11-17 21:38:34 +00:00
..
api Fix Zapier sample data and payload (#5241) 2022-10-28 09:09:15 +00:00
components Change Zap automation UI issues (#5355) 2022-11-06 16:09:10 +00:00
lib Add try-catch and validation to run triggers on reschedule (#5252) 2022-10-28 09:36:30 +00:00
pages/setup Bringing back sendgrid app to review (#5501) 2022-11-17 21:38:34 +00:00
static Add links to Zapier templates in installed apps (#4982) 2022-10-15 08:05:37 +00:00
_metadata.ts Add links to Zapier templates in installed apps (#4982) 2022-10-15 08:05:37 +00:00
index.ts Feat/zapier app (#2623) 2022-05-03 23:16:59 +00:00
package.json Add links to Zapier templates in installed apps (#4982) 2022-10-15 08:05:37 +00:00
README.md Zapier Trigger: After Meeting ends (#3827) 2022-08-15 20:18:41 +00:00
README.mdx Removed old v1 app components in web. (#5286) 2022-10-31 10:42:01 +00:00

Setting up Zapier Integration

If you run it on localhost, check out the additional information below.

  1. Create Zapier Account
  2. If not redirected to developer account, go to: Zapier Developer Account
  3. Click Start a Zapier Integration
  4. Create Integration
    • Name: Cal.com
    • Description: Cal.com is a scheduling infrastructure for absolutely everyone.
    • Intended Audience: Private
    • Role: choose whatever is appropriate
    • Category: Calendar

Authentication

  1. Go to Authentication, choose Api key and click save
  2. Click Add Fields
    • Key: apiKey
    • Check the box is this field required?
  3. Configure a Test
    • Test: GET <baseUrl>/api/integrations/zapier/listBookings
    • URL Params
      • apiKey: {{bundle.authData.apiKey}}
  4. Test your authentication —> First you have to install Zapier in the Cal.com App Store and generate an API key, use this API key to test your authentication (only zapier Api key works)

Triggers

Booking created, Booking rescheduled, Booking cancelled, Meeting ended

Booking created

  1. Settings
    • Key: booking_created
    • Name: Booking created
    • Noun: Booking
    • Description: Triggers when a new booking is created
  2. API Configuration (apiKey is set automatically, leave it like it is):
    • Trigger Type: REST Hook
    • Subscribe: POST <baseUrl>/api/integrations/zapier/addSubscription
      • Request Body
        • subscriberUrl: {{bundle.targetUrl}}
        • triggerEvent: BOOKING_CREATED
    • Unsubscribe: DELETE <baseUrl>/api/integrations/zapier/deleteSubscription
      • URL Params (in addition to apiKey)
        • id: {{bundle.subscribeData.id}}
    • PerformList: GET <baseUrl>/api/integrations/zapier/listBookings
  3. Test your API request

Create the other triggers (booking rescheduled, booking cancelled and meeting ended) exactly like this one, just use the appropriate naming (e.g. booking_rescheduled instead of booking_created)

The invite link can be found under under Manage → Sharing.

Localhost

Localhost urls can not be used as the base URL for api endpoints

Possible solution: using https://ngrok.com/

  1. Create Account
  2. Download gnork and start a tunnel to your running localhost
    • Use forwarding url as your baseUrl for the URL endpoints