Remote configuration for Windows apps
Remote Config enables you to change the behavior or appearance of the app by making changes to the server side values. To add the parameters and conditions in the Remote Config UI, refer to the User Guide.
Add the SDK to your app
- Before your begin, make sure that Apptics is integrated into your project by following the Integration Guide.
- Add AppticsRC.dll reference to your project.
Single value fetch
- Use the below snippet to fetch a single param value. If the key is empty or null, this will return default value passed as param.
Copiedstring result = await AppticsRC.RC.Instance.FetchValue("button_bg_color", "yellow", true);
- Use the below snippet to fetch value from the server. Use the fetch value online function with caution, since only 3 fetch calls are allowed per minute.
Copiedstring result = await AppticsRC.RC.Instance.FetchValueOnline("button_bg_color", "yellow", true);
Multiple value fetch
- Use the below snippet to fetch multiple param values. Dictionary of keys and default values can be passed as a param.
CopiedDictionary<string, string> keysValues = new Dictionary<string, string>();
keysValues.Add("font_size", "15");
keysValues.Add("overall_margin", "25");
keysValues.Add("button_bg_color", "Maroon");
Dictionary<string, string> updatedValues = await AppticsRC.RC.Instance.FetchValues(keysValues, true);
- Use the below snippet to fetch value from the server.
CopiedDictionary<string, string> updatedValues = await AppticsRC.RC.Instance.FetchValuesOnline(keysValues, true);
Custom condition criteria
Use the below method to set the custom condition criteria for the device.
CopiedAppticsRC.RC.Instance.SetCustomCriterias(string conditionKey, string criteria)