Get And Update Settings File
Once the SDK is launched properly, there might be scenarios later on when you need to fetch the latest settings-file and use that instead of the stale one to sync SDK and Wingify application. You can do this by calling Get Settings File API and passing the fetched settings-file to the Launch API to re-instantiate the Wingify SDK. Or, you can simply use the Get and Update Settings File API, available on the Wingify Client Instance that is already available.
Description
Get And Update Settings File API will fetch the latest settings-file from the Wingify server and update the Wingify Client Instance to use that. Every Wingify SDK API used after this API will work according to the latest settings-file fetched.
The method accepts three parameters:
- accountId - account-id associated with your Wingify account.
- sdkKey - generated inside the respective Project under the FullStack Testing.
Parameter Definitions
| Paramter | Type | Description |
|---|---|---|
| accountId Required | Number | Your Wingify application's account-id. |
| sdkKey Required | String | Unique environment-key provided to you inside the Projects section in Wingify application.. |
| isViaWebhook Optional | Boolean | Wingify SDKs require this to handle webhook generated settings-file requests differently.
|
Returns
Returns the fetched settings-file. If somehow the latest settings-file could not be fetched then the last fetched settings-file would be returned.
| Value | Type | Description |
|---|---|---|
| Settings File | Object | String | The settings representing the current state of the running Wingify FullStack campaigns. |
Usage
Also, please refer to this section to know how to use this API.
SDK SupportThis is available from v1.10 onwards.
Updated about 1 month ago