Select only one of three options below.
- Get a WWO Local Weather REST API key from https://developer.worldweatheronline.com/api/
- Replace <ENTER_WWO_API_KEY_HERE> with your WWO API key on line 20 of
functions/index.js
- Select Deploy.
git clone https://github.com/dialogflow/fulfillment-weather-nodejs.git
- Create a Dialogflow Agent.
- In Dialogflow console > Settings ⚙ > Restore from Zip with
weather-agent.zip
in this Github repo.A. - Under Fulfillment > Enable Inline Editor.
- In the Inline editor > copy the contents of
functions/index.js
intoindex.js
. - Get a WWO Local Weather REST API key from https://developer.worldweatheronline.com/api/
- Replace <ENTER_WWO_API_KEY_HERE> with your WWO API key on line 20 of
functions/index.js
- Change the name of the function in
functions/index.js
fromdialogflowFulfillmentLibAdvancedSample
todialogflowFirebaseFulfillment
- Select Deploy.
- In Dialogflow Console > Settings ⚙ > select Google Cloud link in Project ID section. From Google Cloud Platform > menu ☰ > Enable Billing.
A.Note: Restore from Zip will overwrite any existing agent.
git clone https://github.com/dialogflow/fulfillment-weather-nodejs.git
- Create a Dialogflow Agent
- In Dialogflow console under Settings ⚙ > Restore from Zip using the
weather-agent.zip
in this Github repoA. - Get a WWO Local Weather REST API key from https://developer.worldweatheronline.com/api/
- Replace <ENTER_WWO_API_KEY_HERE> with your WWO API key on line 20 of
functions/index.js
cd
to thefunctions
directory- Run
npm install
- Install the Firebase CLI with
npm install -g firebase-tools
- Login to your Google account with
firebase login
- Add your project to the sample with
firebase use [project ID]
- In Dialogflow console under Settings ⚙ > General tab > copy Project ID.
- Run
firebase deploy --only functions:dialogflowFulfillmentLibAdvancedSample
- When successfully deployed, visit the Project Console link > Functions > Dashboard
- Copy the link under the events column. For example:
https://us-central1-<PROJECTID>.cloudfunctions.net/<FUNCTIONNAME>
- Back in Dialogflow Console > Fulfullment > Enable Webhook.
- Paste the URL from the Firebase Console’s events column into the URL field > Save.
- In Dialogflow Console > Settings ⚙ > select Google Cloud link in Project ID section. From Google Cloud Platform > menu ☰ > Enable Billing.
Name | Language |
---|---|
Fulfillment Webhook JSON | JSON |
Dialogflow Console Template | Node.js |
Bike Shop-Google Calendar API | Node.js |
WWO Weather API | Node.js |
Alexa Importer | Node.js |
Temperature Trivia | Node.js |
Human-Agent | Node.js |
Google Translation API | Python |
WWO Weather API | Python |
- Questions? Try StackOverflow.
- Find a bug? Report it on GitHub.
- Dialogflow Documentation.
- For more info on Cloud Functions for Firebase Inline Editor.
- For more info about billing.
Please read and follow the steps in the CONTRIBUTING.md.
See LICENSE.md.
Your use of this sample is subject to, and by using or downloading the sample files you agree to comply with, the Google APIs Terms of Service.