Skip to content

Commit 9ea7230

Browse files
committed
first pass
1 parent 46e4b73 commit 9ea7230

File tree

1 file changed

+10
-4
lines changed
  • src/connections/sources/catalog/libraries/server/http-api

1 file changed

+10
-4
lines changed

src/connections/sources/catalog/libraries/server/http-api/index.md

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,9 @@ title: HTTP API Source
33
redirect_from: '/connections/sources/catalog/libraries/server/http/'
44
id: iUM16Md8P2
55
---
6-
The Segment HTTP Tracking API lets you record analytics data from any website or application. The requests hit Segment servers, Segment routes your data to any destination you want.
6+
The Segment HTTP Tracking API lets you record analytics data from any website or application. The requests hit Segment servers then Segment routes your data to any destination you want.
77

8-
Segment has native [sources](/docs/connections/sources/) for most use cases (like JavaScript and iOS) that are all built for high-performance and are open-source. But sometimes you may want to send to the HTTP API directly—that's what this reference is for.
8+
Segment has native [sources](/docs/connections/sources/) for most use cases (like JavaScript and iOS) that are open-source and built for high-performance. But for unsupported use cases, [blocked event forwarding](/docs/protocols/enforce/forward-blocked-events/) or when you're using [Segment-Managed Custom Domain](/docs/connections/sources/custom-domain/), you may want to send data to Segment's HTTP API directly.
99

1010
> info "HTTP API sources in EU workspaces should use the `events.eu1.segmentapis.com` endpoint"
1111
> If you are located in the EU and use the `https://api.segment.io/v1/` endpoint, you might not see any errors, but your events will not appear in the Segment app. For more information about regional support, see the [Source Regional support](/docs/guides/regional-segment/#source-regional-support) documentation.
@@ -16,6 +16,8 @@ Segment has native [sources](/docs/connections/sources/) for most use cases (lik
1616

1717
Choose between [writeKey authentication](#writeKey-authentication), [basic authentication](#basic-authentication) and [OAuth](#oauth) to authenticate requests.
1818

19+
When authenticating with the HTTP API, don't hard code the IP addresses used to invoke the API. You should refresh this IP address at least once a day or when you experience [5xx errors](#experiencing-5xx-errors).
20+
1921
#### writeKey authentication
2022
Authenticate to the Tracking API by sending your project's **Write Key** along with a request.
2123
The authentication writeKey should be sent as part of the body of the request. This will be encrypted over https.
@@ -284,7 +286,7 @@ Find more details about Group including the **Group payload** in the [Segment Sp
284286

285287
## Alias
286288

287-
`Alias is how you associate one identity with another. This is an advanced method, but it is required to manage user identities successfully in *some* of Segment's destinations.
289+
Alias is how you associate one identity with another. This is an advanced method, but it is required to manage user identities successfully in *some* of Segment's destinations.
288290

289291
In [Mixpanel](/docs/connections/destinations/catalog/mixpanel/#alias) it's used to associate an anonymous user with an identified user once they sign up. For [Kissmetrics](/docs/connections/destinations/catalog/kissmetrics/#alias), if your user switches IDs, you can use 'alias' to rename the 'userId'.
290292

@@ -481,4 +483,8 @@ Segment welcomes feedback on API responses and error messages. [Reach out to sup
481483

482484
1. Double check that you've set up the library correctly.
483485

484-
2. Make sure that you're calling a Segment API method after the library is successfully installed—[Identify](#identify), [Track](#track), and so on.
486+
2. Make sure that you're calling a Segment API method after the library is successfully installed: [Identify](#identify), [Track](#track), and so on.
487+
488+
### Experiencing `5xx` errors
489+
490+
If you're experiencing `5xx` errors, refresh the IP address you use to invoke Segment's HTTP API.

0 commit comments

Comments
 (0)