Comment on page
To get you started, we have created a sample app. By deploying this sample app, you will learn to use every aspect of the DroneDeploy SDK.
The app you will be deploying will enable the following flow:
- 1.A user creates an export
- 2.When the export completes, an export complete Trigger will go off
- 3.The Trigger will call out to your DroneDeploy Function
- 4.The DroneDeploy Function will call to your IFTTT webhook endpoint
- 3.We use the serverless platform for deployment. You will need to install this globally$ npm install -g serverless
- 4.Navigate to the IFTTT example$ cd app-examples/IFTTT
- 5.Install the dependencies. This will install the dronedeploy-cli, which is a development tool to make App Development much easier.$ npm install
- 1.Navigate to the settings page and add the
IFTTT/appdirectory to the App Zone
- 2.Go to the App Market Installed Apps tab to see your new app listed. Go and change the name from
IFTTTand copy the App ID.
- 3.Press the "Deploy For Mobile Testing" button to checkpoint your app and to make the app available on mobile.
- 4.Copy the App ID into your
serverless.ymlfile in the
- 5.Now you are ready to deploy the app with the following command$ serverless deployNote that this will do the following:
- 1.Deploy the defined
- 2.Deploy the Export Complete Function Trigger
- 3.Deploy the
webhook-tableDatastore tableThe deployment should look something like this:
- 6.If everything went according to plan, you should now have a Datastore table, a DroneDeploy Function, and a Trigger definition!
- 2.Go to the IFTTT webhooks service page and activate it by pressing
Connect, then generate a new webhook endpoint by going into the
documentationpage. Enter in
dronedeployas the event name and copy the webhook endpoint.
- 3.The URL should look something like thishttps://maker.ifttt.com/trigger/dronedeploy/with/key/calBarcsa1DcqmSN9_D1acb
- 4.Copy and paste your URL into your App UI and press save. This will save this URL by passing the URL string to the
ifttt-webhookfunction, which will then save the URL to the defined
webhook-tableDatastore table. Try refreshing the page and opening the app - you will notice that your URL is still there and now persisted in your Datastore!
- 5.Create an Applet on IFTTT using your new IFTTT webhook service as the trigger. Don't forget to select the Webhook at the service and set the event to dronedeploy. In this GIF, we are showing an Applet that emails you when a trigger fires. You can find more documentation about how to build an IFTTT Applet here.