Skip to main content
Version: 8.5.x

Configure the Native iOS SDK

The BFG SDK config file, bfg_config.json, provides the basic settings that will be used during the launch of your game. In addition, it enables optional features within your game and configures settings that are specific to the BFG SDK.

The config file, bfg_config.json must be located somewhere in the application bundle.

warning

The config file, bfg_config.json is required for the BFG SDK to function. If the BFG SDK cannot find the file, then your game will crash on startup.

JSON Structure

The config file, bfg_config.json is a JSON file broken down into sections based on their configuration area:

Section NameRequired / OptionalDescription
coreRequiredSettings that identify, set up and configure the game
raveRequiredSettings that configure identity and authentication using Rave
tacklebox_marketingOptionalSettings used to integrate our TackleBox marketing platform

NOTE: Please use this for backwards compatibility only. Newer apps should use Leanplum and/or brainCloud for Marketing functionality.
user_authenticationOptionalSettings for optional features related to user authentication
appsflyerOptionalSettings for AppsFlyer install attribution
gdprOptionalSettings for testing GDPR and other policies
zendeskOptionalSettings to configure the Zendesk help center
debuggingOptionalSettings that enable various SDK debug features

Required Sections

These sections must be included in the config file of every game using the BFG SDK, otherwise, it will crash upon initialization.

Core

The Core section contains settings that are integral to your game, such as the app name and the platforms the game will be distributed on. The values will differ based on platform (Android vs iOS):

"core": {
"app_name": "...",
"app_store": "..."
},
Value NameRequired / OptionalDescription
app_nameRequiredThe English human readable name for your game, such as "Gummy Drop!" or "Fairway Solitaire". The app_name is used for reporting in Big Fish data analytics and user acquisition. Confirm with your Big Fish producer what to use for your app name.

NOTE: In order to identify your game consistently, all non-alphanumeric characters must be removed from the app name. This means that you must remove all non-alphanumeric characters from the name in your game code.
app_store_idRequiredThe identifier given to your game in Apple's App Store Connect portal. Confirm your app_store_id with your Big Fish producer.
custom_events_enabledOptionalA Boolean flag that enables/disables custom event reporting. This value defaults to true if not specified. Check with your Big Fish producer before setting this value to false.
hbiiOSA identifier that stands for Hashed Bundle Identifier. This value is used as an anti-fraud measure. The BFG SDK checks to verify the bundle ID is correct when the purchase service is initialized and will also verify the bundle ID and product ID found in receipts.

If your game does not enable In-App Purchasing, this value is optional and defaults to nil if not specified.

NOTE: The hbi value is required for In-App Purchasing. If your app supports In-App Purchasing, ensure that this value is specified in your config file. Confirm your hbi with your Big Fish producer.
Rave

The Rave section is passed directly to the Rave SDK as part of the BFG SDK initialization. It has several different configuration values, but the ApplicationID is the only one that is required. Confirm your ApplicationID with your Big Fish producer.

"rave": {
"RaveSettings.General.ApplicationID": "..."
},

A full list of Rave configuration values is available on Rave’s documentation: Available Settings

Optional Settings

The following sections are optional, and you only need to include them if you are using their features in your game.

User Authentication

This section controls how various parts of the BFG SDK behave when a user logs in to your game.

"user_authentication": {
"welcome_toast_enabled": false,
"rave_adk_enabled": false
},
Value NameOptional / RequiredDescription
welcome_toast_enabledOptionalA Boolean indicating if the BFG SDK should display a welcome back notification UI to a returning user. If not specified, defaults to false.
rave_adk_enabledOptionalA Boolean indicating if your game will use Rave's App Data Keys feature. If not specified, defaults to false.
AppsFlyer

This section controls AppsFlyer attribution. For more information, see Ad Attribution and Analytics.

"appsflyer": {
"is_enabled": false
},
Value NameOptional / RequiredDescription
is_enabledOptionalA boolean indicating whether AppsFlyer has been properly configured for your game. If not specified, defaults to false.
att_timeoutOptionalAn integer that sets the amount of time (in seconds) before AppsFlyer begins sending network calls, allowing for an ATT selection.
GDPR

The BFG SDK contains a sample GDPR policy that can be used in the case where there is no GDPR policy set up yet on the Big Fish servers. This section allows developers to validate their GDPR integration with third-party targeted advertising.

"gdpr": {
"use_sample_policies": false
},
Value NameOptional / RequiredDescription
use_sample_policiesOptionalA boolean that controls whether or not the Consent Manager uses the sample policy in debug builds instead of the real policies from the server. If not specified, defaults to false.
Zendesk

This section controls the Zendesk integration. For more information, see Customer Service Platform.

"zendesk": {
"is_enabled": false,
"zendesk_url": "https://bigfishgames.zendesk.com/hc/",
"zendesk_app_identifier": "384b2170a8d96d8d1e93bab81e9415a2b59a7aa107185f8b"
},
Value NameOptional / RequiredDescription
is_enabledOptionalA boolean indicating whether Zendesk has been configured in your game. This setting controls whether or not the BFG SDK will show the support page if the bfgManager.showSupport() method is called. If not specified, defaults to false.
zendesk_urlOptionalA string value that allows you to specify a unique URL for your Zendesk support page. This value will be provided by your Big Fish producer. The default value directs the user to a generic Big Fish Zendesk url (https://bigfishgames.zendesk.com).

NOTE:The zendesk_url must include the full URL with https, but do not include any of the path following the domain.
zendesk_app_identifierOptionalA string value that uniquely identifies your game in Zendesk. This value will be provided by your Big Fish producer. If not specified, defaults to a generic Big Fish Zendesk app identifier (384b2170a8d96d8d1e93bab81e9415a2b59a7aa107185f8b).
Debugging

This section prints information about the parsing of the bfg_config.json file to Xcode's console window. This can help you understand if typos or other values are not being used or set properly.

info

The log_json_report value will not work with the release versions of the frameworks, only the debug versions.

"debugging": {
"log_json_report": false
},
Value NameOptional / RequiredDescription
log_json_reportOptionalA boolean value that, when set to true, will print to Xcode's console window a report of what values were parsed in the bfg_config.json file. If not specified, defaults to false.
Tacklebox Marketing

Add this section when using any of the discontinued Tacklebox marketing features.

warning

Big Fish Games has discontinued support of Tacklebox tools and services at the end of 2021. As an alternative to Tacklebox, we recommend using top-shelf solutions like brainCloud and Leanplum for any live ops and messaging needs.

"tacklebox_marketing": {
"game_service_identifier": "..."
},
Value NameOptional / RequiredDescription
game_service_identifierRequiredA string that is a unique game-specific value. This value will be provided by your Big Fish producer.

Sample Config

Here is a sample bfg_config.json file for an Android app. Depending on your game's platform, features, and requirements, your config file may look different. Do not reuse the various IDs listed here for your own game.

{
"debugging": {
"log_json_report" : true
},
"tacklebox_marketing": {
"game_service_identifier": "uikitexample"
},
"core": {
"app_name": "BFGUIKitExample",
"app_store_id": "577295518",
"custom_events_enabled": true,
"hbi": "e7338febd01d7911fdb2156ba4bfbe1d1922d4a9"
},
"user_authentication": {
"welcome_toast_enabled": false,
"rave_adk_enabled": false
},
"appsflyer": {
"is_enabled": true
},
"gdpr": {
"use_sample_policies" : false
},
"zendesk": {
"is_enabled": true,
"zendesk_url": "https://bigfishgames.zendesk.com",
"zendesk_app_identifier": "384b2170a8d96d8d1e93bab81e9415a2b59a7aa107185f8b",
},
"rave": {
"RaveSettings.General.ApplicationID": "64b93a17c8a34486a4c2598945935c98",
"RaveSettings.Facebook.ReadPermissions" : "public_profile,email,user_friends",
"RaveSettings.Facebook.LimitedLoginTracking" : false
}
}