Class Contentstack

java.lang.Object
com.contentstack.sdk.Contentstack

public class Contentstack extends Object
The Content Delivery API is used to retrieve content from your Contentstack account and deliver it to your web or mobile properties. If you are looking for APIs to manage content, you should use the Content Management API

Our APIs serve content via a powerful and robust content delivery network (CDN). Multiple datacenters around the world store a cached copy of your content. When a page request is made, the content is delivered to the user from the nearest server. This greatly accelerates content delivery and reduces latency.

  • Method Details

    • stack

      public static Stack stack(String stackApiKey, String deliveryToken, String environment) throws IllegalAccessException
      A stack is a space that stores the content of a project (a web or mobile property). Within a stack, you can create content structures, content entries, users, etc. related to the project.
      Authenticates the stack api key of your stack.
      Find Your Stack Credentials from Contentstack .
      Parameters:
      stackApiKey - The API Key is a unique key assigned to each stack.
      deliveryToken - The Delivery Token is a read-only credential that you can create for different environments of your stack
      environment - the environment for the stack
      Returns:
      the stack
      Throws:
      IllegalAccessException - the illegal access exception

      Example

                                      {
                                          @Code
                                          Stack stack = contentstack.Stack("apiKey", "deliveryToken", "environment");
                                      }
      
                                      
    • stack

      public static Stack stack(String stackApiKey, String deliveryToken, String environment, Config config) throws IllegalAccessException
      A stack is a space that stores the content of a project (a web or mobile property). Within a stack, you can create content structures, content entries, users, etc. related to the project.
      Parameters:
      stackApiKey - The API Key is a unique key assigned to each stack.
      deliveryToken - The Delivery Token is a read-only credential that you can create for different environments of your stack
      environment - the environment for the stack
      config - the config
      Returns:
      the stack
      Throws:
      IllegalAccessException - the illegal access exception Example

      { @Code Stack stack = contentstack.Stack("apiKey", "deliveryToken", "environment"); }