Skip to content

☀️ A game changer in rule-based marketing. Run marketing campaigns based on real world events.

License

Apache-2.0 and 2 other licenses found

Licenses found

Apache-2.0
LICENSE
Unknown
license-config.json
Unknown
license-header.txt
Notifications You must be signed in to change notification settings

google/if-this-then-ad

Repository files navigation

If This Then Ad (IFTTA)

build GitHub tag (latest SemVer) GitHub last commit

If This Then Ad (IFFTA) YouTube Link: youtu.be/ugklLFbij-A.

IFTTA is a game changer in rule-based marketing. With our tool you can run marketing campaigns based on real world events. We already support the following data sources:

  • Weather (based on OpenWeatherMaps API). The Weather conditions that you already can use: temperature, wind speed, cloudiness, rain, snow, thunderstorm.
  • Pollen and Air Quality (Ambee API).

On the marketing activation side we support the following platforms:

Keywords: Weather Based Marketing, External Signal Based Marketing, Pollen Based Marketing, AirQuality Based Marketing, Rule-based Marketing.

The Problem that we solve

  • Advertisers want to show their ads as targeted as possible to reach the right audience at the right time
  • Managing ad campaigns in response to real-time events like weather, pollen data or air quality can be challenging to impossible (just imagine, manually switching hundreds of ad groups on a daily basis... it is really time consuming and an error-prone)

Our tool will do this for you automatically!

Is IFTTA for you?

Basically all advertisers can benefit from this solution and especially those that clearly see a correlation between the real world factors (e.g. weather) and sales (or other marketing KPIs).

Some examples to ignite the imagination (based on our experience):

  • Hot beverages can be advertised during the colder weather and cold beverages during the warm weather
  • An ice cream company can show ads when it’s hot
  • Insurance companies can show ads when there’s a storm or a flood
  • A hardware store might show ads for snow shovels when it snowed
  • Healthcare companies can advertise based on the pollen index and/or the air quality

Benefits you get

  • Ads will reach their audience at the right time under the right circumstances
  • Advertisers can automate their campaign management in response to real-time events
  • Personalized ads and WOW effect on the end user side (since the user will see the right ad at the right time)

Setup

Prerequisities

Basic Google Cloud knowledge and a Google Cloud project with enabled billing are required.

Step-by-step guide

With the following simple steps you can install IFTTA on your Google Cloud project. The installation below is partly automated, this means that you will need to do some manual steps at the beginning and at the end the installation script (the big blue button below) will do the rest.

  1. Create an OAuth Consent Screen

  2. Make it of type "External"

  3. Add all users you want to have access to the app

  4. Create an OAuth Client ID

  5. Set Application type to "Web application"

  6. Set the name to "if-this-then-ad"

  7. Take note of the Client ID and Client Secret presented to you

  8. Click the big blue button to deploy:

    Run on Google Cloud

  9. Choose the Google Cloud Project where you want to deploy the app

  10. Select the region where you want to deploy

  11. Enter your Client ID and Client Secret when prompted

  12. Ignore any other prompts, which will get auto-populated

  13. Make sure you add the Authorized JavaScript origin as well as the Authorized redirect URI presented to you at the end of the script to your OAuth Client

Reporting bugs / feature requests

We love to hear your feedback! Please create an issue directly on GitHub. Please be specific describing your question/bug/feature.

Development

Local dev setup

  1. Clone this repository
  2. Complete the step-by-step guide above
  3. Create a new GCP Service Account (or add another key for it, if it already exists)
  4. Download the .json credentials
  5. Rename server/.env.sample to server/.env
  6. Add all missing values to server/.env
  7. Go to server/
  8. To set up and start the server, run:
    • npm run build-local
    • npm run dev
  9. Go to client/
  10. To set up and start the client, run:
    • sudo npm i -g @angular/cli
    • npm i
    • ng serve --ssl
  11. The application is running at https://localhost:4200

Git: Pre commit

To do all the checks before the commit automatically please add the git/pre-commit to your .git/hooks/ directory. The easiest way would be to create a soft link: cd .git/hooks/; ln -sf ../../git/pre-commit.

To run all checks manually you can execute the following commands from the project root:

  • For server: cd server; npm run pre-commit.
  • For client: cd client; npm run pre-commit.

Do you like our tool?

You can start contributing by sending pull requests right now! Also you can give us a star on our GitHub page ;-)

Troubleshooting

Authorization Error (redirect_uri_mismatch)

This usually originates from not having the Authorized redirect URI set properly.

Here's how to fix it:

  1. Go to Cloud Credentials
  2. Select the right project
  3. Click on the if-this-then-ad OAuth 2.0 Client ID
  4. Add the redirect_uri presented to you in the error message to Authorized redirect URIs