Almost EVERYONE who tried headless systems said they saw benefits. Download the state of CMS now!

Storyblok now on AWS Marketplace: Read more

O’Reilly Report: Decoupled Applications and Composable Web Architectures - Download Now

Empower your teams & get a 582% ROI: See Storyblok's CMS in action

Skip to main content

How to define a specific region when using the Content Delivery API

  • FAQ
  • How to define a specific region when using the Content Delivery API

Section titled Adding a region parameter to an API request Adding a region parameter to an API request

In order to use the correct region that matches the region of your space, you have to use a different base URL.

The base URL for spaces created in the EU is:

        
      https://api.storyblok.com/v2

    

The base URL for spaces created in the US is:

        
      https://api-us.storyblok.com/v2
    

The base URL for spaces created in the Australia region is:

        
      https://api-ap.storyblok.com/v2
    

The base URL for spaces created in the Canada region is:

        
      https://api-ca.storyblok.com/v2
    

The base URL for spaces created in China is:

        
      https://app.storyblokchina.cn
    

Section titled Adding a region parameter when using an SDK Adding a region parameter when using an SDK

Section titled Setting the correct region Setting the correct region

Depending on whether your space was created in the EU, the US, Australia, Canada, or China, you may need to set the region parameter of the API accordingly:

  • eu (default): For spaces created in the EU
  • us: For spaces created in the US
  • ap: For spaces created in Australia
  • ca: For spaces created in Canada
  • cn: For spaces created in China

Here's an example for a space created in the US:

        
      apiOptions: {
  region: "us",
},
    
WARN:

Note: For spaces created in any region other than the EU, the region parameter must be specified.

HINT:

Since all the Storyblok SDKs use storyblok-js-client, you can use apiOptions to pass down any option such as region to the JS Client.

IMPORTANT:

Please note that our Ruby Client currently doesn’t support accessing spaces located in China.

IMPORTANT:

Please note that our PHP Client currently doesn’t support accessing spaces located in China.

IMPORTANT:

Please note that our Python Client currently doesn’t support accessing spaces located in the United States or China.

Section titled Defining Regions for Assets Defining Regions for Assets

It's essential to understand how asset domains vary based on the chosen location for your space.

The asset domain, or base URL, depends on the region of your Storyblok space:

The URL for assets in the US is:

        
      https://a-us.storyblok.com
    

The URL for assets in the EU is:

        
      https://a.storyblok.com
    

The URL for assets in the Australia region is:

        
      https://a-ap.storyblok.com
    

The URL for assets in the Canada region is:

        
      https://a-ca.storyblok.com
    

The URL for assets in China is:

        
      https://a.storyblokchina.cn