Configures the shared Encore instance for use throughout your app. This must be called once, typically in yourDocumentation Index
Fetch the complete documentation index at: https://docs.encorekit.com/llms.txt
Use this file to discover all available pages before exploring further.
Application.onCreate(), before using any other SDK methods.
Signature
Parameters
| Name | Type | Default | Description |
|---|---|---|---|
context | Context | — | Your application context |
apiKey | String | — | Your Live Key or Test Key from the Encore Dashboard settings |
logLevel | LogLevel | LogLevel.NONE | Logging verbosity level |
Log levels
Higher levels include all lower levels. For example,
INFO will also show warnings and errors.API keys
Encore supports two types of API keys:| Key Type | Format | Description |
|---|---|---|
| Live Key | pk_live_... | Production key with standard geo-filtering based on offers’ configured regions |
| Test Key | pk_test_... | Testing key that bypasses geo-filtering, allowing you to test the complete entitlement lifecycle from any location |
Use the test key (
pk_test_...) during development to test offers from any location without geo-filtering restrictions. This makes it easy to test the entire entitlement lifecycle end-to-end for a single user.