public class Contentstack extends Object
| Modifier and Type | Method and Description |
|---|---|
static Stack |
stack(String stackApiKey,
String accessToken,
String environment)
Authenticates the stack api key of your stack.
|
static Stack |
stack(String stackApiKey,
String accessToken,
String environment,
Config config)
Authenticates the stack api key of your stack.
|
public static Stack stack(String stackApiKey, String accessToken, String environment) throws Exception
stackApiKey - application api Key of your application on Contentstack.accessToken - access tokenenvironment - environment nameStack instance.Exception - //'blt5d4sample2633b' is a dummy Stack API key //'blt6d0240b5sample254090d' is dummy access token. Stack stack = Contentstack.stack(context, "blt5d4sample2633b", "blt6d0240b5sample254090d", "stag");
public static Stack stack(String stackApiKey, String accessToken, String environment, Config config) throws Exception
stackApiKey - application api Key of your application on Contentstack.accessToken - access tokenenvironment - environment nameconfig - Config instance to set environment and other configuration details.Stack instance.Exception - //'blt5d4sample2633b' is a dummy Stack API key //'blt6d0240b5sample254090d' is dummy access token. Stack stack = Contentstack.stack(context, "blt5d4sample2633b", "blt6d0240b5sample254090d", "stag");
Copyright © 2019 Contentstack. All rights reserved.