Skip to main content

How do I configure the Swrve SDK for EU data storage?

By default, Swrve stores customer resources and content in our US data center. Some customers may require that we store their data in our EU data center, therefore to accommodate these requirements, Swrve has separate .swrve.com endpoints for customers who require data separation (for example, eu-dashboard.swrve.com). This article explains how to update the SDK configuration to point to the EU URL endpoints. If you have any questions or need assistance configuring the SDK for EU data storage, please contact support@messagegears.com.


EU stack endpoints configuration

To make use of Swrve's EU stack, you must configure the Swrve SDK to point to the correct server addresses.

Update the code in the didFinishLaunchingWithOptions method of the App Delegate to the following:

#import "swrve.h"
- (BOOL) application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions {
SwrveConfig* config = [[SwrveConfig alloc] init];
config.Stack = SWRVE_STACK_EU;
[Swrve sharedInstanceWithAppID:<app_id> apiKey:@"<api_key>" config:config];
}

Using Swrve APIs

If an app is configured to use the EU stack, you must also update any API URL references as follows:

APINon-EU URLEU URL
Swrve Events API
Swrve Referrer API
Session Token
<app_id>.api.swrve.com<app_id>.eu-api.swrve.com
Swrve A/B Test API<app_id>.content.swrve.com<app_id>.eu-content.swrve.com
Swrve Push APIservice.swrve.comeu-service.swrve.com
Swrve Items API
Swrve Export API
dashboard.swrve.comeu-dashboard.swrve.com