Skip to content

Commit

Permalink
Merge pull request #263 from AdTechMedia/stage
Browse files Browse the repository at this point in the history
Stage to master 2017-07-10
  • Loading branch information
mgoria authored Jul 10, 2017
2 parents fd7c6c1 + 11f1a0d commit e0bb078
Show file tree
Hide file tree
Showing 97 changed files with 1,714 additions and 1,339 deletions.
49 changes: 47 additions & 2 deletions component/ads-blocking-losses/readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,14 @@ After delpoy, you will get the endpoints to the API:
GET - https://xxx.execute-api.us-east-1.amazonaws.com/prod/niches
...

To get niches list supported, call your `https://xxx.execute-api.us-east-1.amazonaws.com/prod/niches` endpoint, response body will be in *json* format.
To get niches list supported, call your `https://xxx.execute-api.us-east-1.amazonaws.com/prod/niches` endpoint, response body will be in *json* format:

{
"niches": [
"default",
...
]
}

To calculate losses, call your `https://xxx.execute-api.us-east-1.amazonaws.com/prod/calculator` endpoint with query parameters:

Expand All @@ -36,4 +43,42 @@ To calculate losses, call your `https://xxx.execute-api.us-east-1.amazonaws.com/
- **page_views** - website page views per month
- **ads_sections** - ads sections on website
- **email** - *optional*, send a report to the email
- **full_name** - *optional*, included in the report
- **full_name** - *optional*, included in the report
- **id** - *optional*, you can update user request info with the id (late user email assign & send)

Response example:

{
"losses": "8.28",
"id": "5371838316943"
}

#### Mailchimp setup

To send email reports through Mailchimp service you must:

1. Set parameter *mailer.service* to 'mailchimp' value.
2. Create a new Mailchimp List, with those **merge fields**:
- FULL_NAME
- WEBSITE
- LOSSES
- PAGE_VIEWS
- AD_SLOTS
- INDUSTRY
3. Get the List ID from list Settings -> List name and defaults and put in config.yml (mailchimp.list).
4. Create new Mailchimp Template with the content block:


> Hi *|FULL_NAME|*,
>
> So you are losing *|LOSSES|* $ every month due to ad blocks?
> This is how we come up with this sum:
> “Nr of PV/month” * Rate = “Blocked page views”
> “Blocked page views” * “Ads Sections on page” = “Total ad Impressions”
> “Total ad Impressions” * “CTR” = “Ad Clicks”
> “Ad Clicks” * “Avg CPC” = “Ad Revenue losses”
>
> Learn how Ad Tech Media can help you to increase your revenue, schedule a demo and claim your earnings back.

5. Get the Template ID from URL, like `https://xx.admin.mailchimp.com/templates/edit?id=304021` - 304021, and put it in config.yml
3 changes: 2 additions & 1 deletion component/ads-blocking-losses/requirements.txt
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
pyaml
validators
validators
mailchimp3
1 change: 1 addition & 0 deletions component/ads-blocking-losses/serverless.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ provider:
name: aws
runtime: python2.7
stage: prod
memorySize: 256
versionFunctions: false
environment:
DYNAMODB_TABLE: ${self:service}-${opt:stage, self:provider.stage}
Expand Down
2 changes: 1 addition & 1 deletion src/adtechmedia-website/frontend/css/challenges.min.css

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions src/adtechmedia-website/frontend/css/challenges.min.css.map

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion src/adtechmedia-website/frontend/css/home.min.css

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions src/adtechmedia-website/frontend/css/home.min.css.map

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion src/adtechmedia-website/frontend/css/main.min.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion src/adtechmedia-website/frontend/css/main.min.css.map

Large diffs are not rendered by default.

Loading

0 comments on commit e0bb078

Please sign in to comment.