Skip to content

Commit d72c2e0

Browse files
committed
add info to separate note
1 parent 4c5fd42 commit d72c2e0

File tree

1 file changed

+8
-9
lines changed
  • src/connections/sources/catalog/libraries/website/javascript

1 file changed

+8
-9
lines changed

src/connections/sources/catalog/libraries/website/javascript/custom-proxy.md

Lines changed: 8 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -23,13 +23,12 @@ This guide explains how to set up a custom domain in CloudFront. You can apply t
2323
You need to set up two important parts, regardless of the CDN provider you use:
2424

2525
- Proxy to Segment CDN (`cdn.segment.com`)
26-
- Proxy to Segment tracking API (`api.segment.io`). If you are using a [Regional Workspace](/docs/guides/regional-segment/#client-side-sources), please note that instead of using `api.segment.io` to proxy the Tracking API, you'll be using `events.eu1.segmentapis.com`
26+
- Proxy to Segment tracking API (`api.segment.io`)
2727

28-
29-
30-
> info " "
28+
> warning ""
3129
> If you are using a [Regional Workspace](/docs/guides/regional-segment/#client-side-sources), please note that instead of using `api.segment.io` to proxy the Tracking API, you'll be using `events.eu1.segmentapis.com`
32-
>
30+
31+
> info ""
3332
> Segment only has the ability to enable the proxy setting for the Web (Analytics.js) source. Details for mobile source proxies are in the [Analytics for iOS](/docs/connections/sources/catalog/libraries/mobile/ios/#proxy-https-calls) and [Analytics for Android](/docs/connections/sources/catalog/libraries/mobile/android/#proxying-http-calls) documentation. It is not currently possible to set up a proxy for server sources using the Segment UI.
3433
3534
## Set up
@@ -63,9 +62,9 @@ A Segment Customer Success team member will respond that they have enabled this
6362
## Custom CDN / API Proxy
6463

6564
### Snippet instructions
66-
If you're a snippet user, you need to modify the [analytics snippet](/docs/getting-started/02-simple-install/#step-1-copy-the-snippet) that's inside your `<head>`.
65+
If you're a snippet user, you need to modify the [analytics snippet](/docs/getting-started/02-simple-install/#step-1-copy-the-snippet) that's inside your `<head>`.
6766

68-
To proxy settings and destination requests that typically go to `http://cdn.segment.com`, replace:
67+
To proxy settings and destination requests that typically go to `http://cdn.segment.com`, replace:
6968
```diff
7069
- t.src="https://cdn.segment.com/analytics.js/v1/" + key + "/analytics.min.js"
7170
+ t.src="https://MY-CUSTOM-CDN-PROXY.com" + key + "/analytics.min.js"
@@ -89,7 +88,7 @@ const analytics = AnalyticsBrowser.load({
8988
// https://MY-CUSTOM-CDN-PROXY.com/v1/project/<writekey>/settings
9089
// GET https://cdn.segment.com/next-integrations/actions/...js ->
9190
// https://MY-CUSTOM-CDN-PROXY.com/next-integrations/actions/...js
92-
cdnURL: 'https://MY-CUSTOM-CDN-PROXY.com'
91+
cdnURL: 'https://MY-CUSTOM-CDN-PROXY.com'
9392
})
9493
```
9594

@@ -104,7 +103,7 @@ const analytics = AnalyticsBrowser.load(
104103
integrations: {
105104
'Segment.io': {
106105
// POST https://api.segment.io/v1/t -> https://MY-CUSTOM-API-PROXY.com/t
107-
apiHost: 'MY-CUSTOM-API-PROXY.com' // omit the protocol (http/https) e.g. "api.segment.io/v1" rather than "https://api.segment.io/v1"
106+
apiHost: 'MY-CUSTOM-API-PROXY.com' // omit the protocol (http/https) e.g. "api.segment.io/v1" rather than "https://api.segment.io/v1"
108107
}
109108
}
110109
}

0 commit comments

Comments
 (0)