Skip to content

Flatten faqs #48

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 7 commits into from
Aug 13, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 17 additions & 1 deletion _data/sidenav/default.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,20 @@ sections:
section:
- path: "/connections/warehouses"
title: Overview
- path: "/connections/warehouses/choose-warehouse"
title: Choosing a Warehouse
- path: "/connections/warehouses/add-warehouse-users"
title: Add users to a Warehouse
- path: "/connections/warehouses/redshift-faq"
title: "Redshift Best Practices"
- path: "/connections/warehouses/redshift-tuning"
title: "Improving Redshift performance"
- path: "/connections/warehouses/warehouse-errors"
title: "Warehouse Error codes"
- path: "/connections/warehouses/faq"
title: Warehouses FAQs
- path: "/connections/warehouses/catalog"
title: Warehouses catalog
title: Warehouses Catalog
- section_title: Guides
section:
- path: "/guides"
Expand Down Expand Up @@ -72,6 +84,10 @@ sections:
title: How do we implement an e-commerce tracking plan?
- path: "/guides/best-practices/measure-marketing-roi"
title: How do I measure the ROI of my Marketing Campaigns?
- path: "/guides/best-practices/measure-marketing-roi2"
title: "Use Warehouses to measure marketing ROI"
- path: "/guides/best-practices/forecast-with-sql"
title: Forecasting with SQL and Warehouses
- path: "/guides/best-practices/preparing-for-gdpr"
title: Preparing for the GDPR
- path: "/guides/best-practices/test-connections"
Expand Down
4 changes: 2 additions & 2 deletions connections/destinations/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -845,8 +845,8 @@ For detailed information about each destination, select one from the list to lea

### Analyzing with SQL

[How do I forecast LTV with SQL and Excel for e-commerce businesses?](/docs/guides/warehouses/how-to-forecast-ltv-with-sql-and-excel)
[How do I forecast LTV with SQL and Excel for e-commerce businesses?](/docs/guides/data-driven/forecase-with-sql)

[How do I measure the ROI of my Marketing Campaigns?](/docs/guides/warehouses/how-to-measure-roi-of-marketing-campaigns)
[How do I measure the ROI of my Marketing Campaigns?](../../guides/warehouses/measure-marketing-roi)

For additional information, check out our [Guides](/docs/guides/) section.
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
---
title: "How to setup custom domains in Segment"
title: Set up a custom domain proxy in Segment
---

Custom Domains allow you to proxy Analytics.js and proxy all tracking event requests through your domain.
Custom Domains allow you to proxy Analytics.js and proxy all tracking event requests through your domain.

## Getting Started

Expand All @@ -12,15 +12,15 @@ In order to get started using custom domains, you will need:
2. A CDN you're using to serve assets from
3. Access to the CDN settings

This guide will go through how to setup a custom domain in Cloudfront. The same principles can be applied to virtually any modern CDN that supports proxying.
This guide will go through how to setup a custom domain in Cloudfront. The same principles can be applied to virtually any modern CDN that supports proxying.

You will need to setup two key pieces, regardless of the CDN provider you're using:
You will need to setup two key pieces, regardless of the CDN provider you're using:
1. Proxy to Segment CDN (cdn.segment.com)
2. Proxy to Segment tracking API (api.segment.io)

## Setup

Follow the directions listed for Cloudfront or use your own CDN setup. Once you have completed those steps and have verified that your proxy is working for both cdn.segment.com and api.segment.io, please contact us with the following templated email:
Follow the directions listed for Cloudfront or use your own CDN setup. Once you have completed those steps and have verified that your proxy is working for both cdn.segment.com and api.segment.io, email us with the following template email:

```
Hi,
Expand All @@ -31,25 +31,25 @@ This is {person} from {company}. I would like to request a proxy be added for th
* Source {link to source in Segment} with source ID {source id} should point to {api host}
```

Please double check the source link, the Source ID and the api host to ensure they are correct. A member of our Success team will respond and setup the proxy for you.
Please double check the source link, the Source ID and the api host to ensure they are correct. A member of our Success team will respond and setup the proxy for you.

## Cloudfront

### CDN Proxy

You will need to first login to AWS and navigate to CloudFront.
You will need to first login to AWS and navigate to CloudFront.

![](../images/create_cloudfront_distribution.png)
![](images/create_cloudfront_distribution.png)

Click "Create Distribution"

Here, you will need to select a delivery method for your content. Select the "Get Started" button in the "Web" section.
Here, you will need to select a delivery method for your content. Select the "Get Started" button in the "Web" section.

![](../images/cloudfront_distribution_web.png)
![](images/cloudfront_distribution_web.png)

Now we'll need to configure our distribution settings. Under origin settings, you will need to update the following values:
Now we'll need to configure our distribution settings. Under origin settings, you will need to update the following values:

![](../images/cloudfront_distribution_settings.png)
![](images/cloudfront_distribution_settings.png)

<table>
<tr>
Expand Down Expand Up @@ -79,7 +79,7 @@ Now we'll need to configure our distribution settings. Under origin settings, yo
</tr>
</table>

Next, you'll want to configure the Default Cache Behavior Settings.
Next, you'll want to configure the Default Cache Behavior Settings.

<table>
<tr>
Expand Down Expand Up @@ -109,12 +109,12 @@ Next, you'll want to configure the Default Cache Behavior Settings.
</tr>
</table>

Click "Create Distribution" at the bottom of the page. This distribution will show as "In Progress" until the distribution is deployed.
Click "Create Distribution" at the bottom of the page. This distribution will show as "In Progress" until the distribution is deployed.

We'll need the "Domain Name" for the next step so keep this browser window open.
We'll need the "Domain Name" for the next step so keep this browser window open.

**Add CNAME Record to DNS**
Next, we'll need to add a CNAME record to your DNS settings. Go to your domain registrar and add a new record to your DNS of type "CNAME".
Next, we'll need to add a CNAME record to your DNS settings. Go to your domain registrar and add a new record to your DNS of type "CNAME".

<table>
<tr>
Expand All @@ -131,11 +131,11 @@ Next, we'll need to add a CNAME record to your DNS settings. Go to your domain r
</tr>
</table>

Save your record. Depending on the TTL you have set, it may take some time to take effect. Try curling your domain to ensure it's proxying correctly.
Save your record. Depending on the TTL you have set, it may take some time to take effect. Try curling your domain to ensure it's proxying correctly.

### Tracking API Proxy

Next, we're going to setup a proxy for the tracking API so that all calls will be proxied through your domain. We're going to setup a Cloudfront distribution that's very similar to the previous step with a few minor changes:
Next, we're going to setup a proxy for the tracking API so that all calls will be proxied through your domain. We're going to setup a Cloudfront distribution that's very similar to the previous step with a few minor changes:

<table>
<tr>
Expand Down Expand Up @@ -168,4 +168,4 @@ Next, we'll need to add a CNAME record to your DNS settings. Go to your domain r
</tr>
</table>

Save your record. Depending on the TTL you have set, it may take some time to take effect. Try curling your domain to ensure it's proxying correctly.
Save your record. Depending on the TTL you have set, it may take some time to take effect. Try curling your domain to ensure it's proxying correctly.
Original file line number Diff line number Diff line change
Expand Up @@ -93,18 +93,18 @@ If you want to get a quick estimate for the number of additional clicks you’d
Here’s how it works…

1. Use a URL shortener like bit.ly to link to a landing page, with a custom parameter like `?ttg=2` .

2. Add the shortened link to your ad.

3. Measure total clicks from the bit.ly stats page.


![](../images/asset_vMpEZBVz.png)

1. In your warehouse, count the number of pages with that unique url parameter from step 1 (make sure you’re looking at the same timeframe).


```

```sql
select received_at, url
from <site>.pages
where url like '%/warehouses%'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,21 +4,21 @@ title: "Can I see an example of a tracking plan?"

Here at Segment we have made our own tracking plans available for download to help get you started planning out and documenting your own tracking plan.

**Basic Tracking Plan**
### Basic Tracking Plan

This is a simplified version of our tracking plan to help get you started. We strongly recommend starting with a plan like this before digging into more complicated tracking.

[View in Google Sheets](https://docs.google.com/spreadsheets/d/111LLWxdf_zQE5a_AajKeB8WpCgFaWKEo-sGMc95HYq0/edit?usp=sharing&__hstc=222691652.f2c5ed50a3a9703ac3be5283918044ad.1436399176206.1437082421955.1437085712408.17&__hssc=222691652.23.1437085712408&__hsfp=2203243415)

**Full Tracking Plan**
### Full Tracking Plan

This plan is the actual plan we use to organize all of our own Segment tracking. Some of the event properties have been trimmed to keep things clean, but everything is here.

[View in Google Sheets](https://docs.google.com/spreadsheets/d/1CCx7VU1ioHdWsRmMjywOKhoioh_ObR_V6Cp2RZmbA1Y/edit?usp=sharing&__hstc=222691652.f2c5ed50a3a9703ac3be5283918044ad.1436399176206.1437082421955.1437085712408.17&__hssc=222691652.23.1437085712408&__hsfp=2203243415)

**Segment Tracking Outline**
## Segment Tracking Outline

**User Tracking**
### User Tracking

CORE LIFECYCLE

Expand All @@ -36,7 +36,7 @@ SIGNED UP

With signups we want to be able to differentiate paid signups, organic signups, and invitation signups. We’ll use automatically recorded utm parameters to analyze paid, and then a type to differentiate organic and invitation signups (and in the future maybe referral program stuff, etc.)

```
```js
analytics.track('Signed Up',{
    userLogin:'reinpk',
    type:'invite',
Expand All @@ -49,7 +49,7 @@ CREATED SOURCE

With source creation we want to be able to differentiate sources created for a workspace vs. for a user account.

```
```js
analytics.track('Created Source',{
    ownerId:'aef6d5f6e',
    sourceId:'b6c6281',
Expand All @@ -63,7 +63,7 @@ SENT SOURCE DATA

The tricky thing with this event is that it’s unique per source, but everything else is tracked per user. So we’ll want to record a “Sent Source Data” event: once a day, for each user, for every source they’re connected with that had data sent. So a user might be an owner/collaborator on 3 sources that sent data today, in which case we’ll send 3 “Sent Source Data” events, one for each of those sources. We still want to differentiate workspace stuff from user account stuff.

```
```js
analytics.track(userId,'Sent Source Data',{// source
    sourceId:'bce5fad577',
    sourceSlug:'rein.pk',
Expand All @@ -90,7 +90,7 @@ ENABLED DESTINATION

Here we’re interested in differentiating workspace/user account as usual, but also what their current plan tier is vs. destination tier.

```
```js
analytics.track('Enabled destination',{
    ownerId:'aef6d5f6e',
    ownerTier:4,
Expand All @@ -102,7 +102,7 @@ STARTED SUBSCRIPTION

With subscriptions again we want to be able to differentiate between subscriptions for a workspace vs. for a user account.

```
```js
analytics.track('Started Subscription',{
    ownerId:'aef6d5f6e',
    ownerLogin:'segment',
Expand All @@ -117,7 +117,7 @@ UPGRADED SUBSCRIPTION

Again differentiating workspace/user account is the critical piece.

```
```js
analytics.track('Upgraded Subscription',{
    ownerId:'aef6d5f6e',
    ownerLogin:'segment',
Expand All @@ -132,7 +132,7 @@ DOWNGRADED SUBSCRIPTION

Again differentiating workspace/user account is the critical piece.

```
```js
analytics.track('Downgraded Subscription',{
    ownerId:'aef6d5f6e',
    ownerLogin:'segment',
Expand All @@ -143,7 +143,7 @@ analytics.track('Downgraded Subscription',{
    planId:'developer-$0-1-month'});
```

Other Events
### Other Events

There are other events that are also interesting for non-core-funnel analysis:

Expand All @@ -155,7 +155,7 @@ There are other events that are also interesting for non-core-funnel analysis:

CREATED ORGANIZATION

```
```js
analytics.track('Created an Organization',{
    organizationId:'fdbe51276dc',
    organizationLogin:'segment',
Expand All @@ -168,7 +168,7 @@ INVITED USER

This event can happen in multiple places, so we need some differentiation between workspace creation and workspace settings, source settings or future referral flows.

```
```js
analytics.track('Invited User',{
    inviteeEmail:'raphael@segment.com',
    inviteType:'organization',// source, organization, referral
Expand All @@ -183,7 +183,7 @@ VIEWED DESTINATION

Here we’re interested in differentiating workspace/user account as usual, but also what their current plan tier is vs. destination tier.

```
```js
analytics.track('Viewed Destination',{
    ownerId:'aef6d5f6e',
    ownerTier:4,
Expand All @@ -196,7 +196,7 @@ DISABLED DESTINATION

Here we’re interested in differentiating workspace/user account as usual, but also what their current plan tier is vs. destination tier.

```
```js
analytics.track('Disabled Destination',{
    ownerId:'aef6d5f6e',
    ownerTier:4,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,36 +6,36 @@ If you have more than one person working with your Segment Warehouse, you might

### 1\. Creating a user with the [CREATE USER](http://docs.aws.amazon.com/redshift/latest/dg/r_CREATE_USER.html) command

![](../images/asset_h5NYu2A6.png)
![](images/asset_h5NYu2A6.png)

The code above in \[\] is optional, you don't need to group your users or give their credentials an expiration date, the code works without it. However, if you do choose to use those parameters, `<abstime>` should be formatted as '2015-09-13' which translates to September 13th, 2015.

For instance, you can create a user named `stephencolbert` as

![](../images/asset_tCuF9cKv.png)
![](images/asset_tCuF9cKv.png)

This creates a user, you can run the following to get a list of users in your database.

![](../images/asset_mqIokcxg.png)
![](images/asset_mqIokcxg.png)

Now that we've confirmed that the user has been created, they already have access to the public schema that contains systems-level information about the cluster but we need to give them access to the specific schemas that they'll be working in.

### 2. [GRANT USAGE](http://docs.aws.amazon.com/redshift/latest/dg/r_GRANT.html) on the schema to the user we just created

![](../images/asset_A9wjfpH7.png)
![](images/asset_A9wjfpH7.png)

The above SQL command grants the user USAGE priveleges on a schema. Let's assume you want to grant `stephencolbert` access to your development schema, it would look like below

![](../images/asset_lBjUYlwq.png)
![](images/asset_lBjUYlwq.png)

Our new user now has usage rights on the `development` schema, now we need to grant the type of SQL commands they'll be able to run against the cluster. For the purposes of this example, we're going to give the user read only privileges.

### 3. [GRANT SELECT](http://docs.aws.amazon.com/redshift/latest/dg/r_GRANT.html) privileges so the user can query the tables

![](../images/asset_g1XTzzbo.png)
![](images/asset_g1XTzzbo.png)

The above SQL command grants the user SELECT rights on all tables in the chosen schema. For our `stephencolbert`user and the `development` schema, it would look like below.

![](../images/asset_0NVxn6T3.png)
![](images/asset_0NVxn6T3.png)

Doing these three steps will result in a new user that can query all the tables in a given schema. If you want to give access to more than one schema then you can simply repeat steps 2 and 3 for each additional schema. If you have any questions or if you're running into any issues getting this set up, [contact us](/contact).
Loading