Releases: Kameleoon/client-go
Releases · Kameleoon/client-go
GO SDK 3.3.0
Features
- Added
GetActiveFeatures
method. It retrieves information about the active feature flags that are available for a specific visitor code. This method replaces the deprecatedGetActiveFeatureListForVisitor
method.
Bug fixes
- The SDK no longer logs failed tracking requests to the Data API when the user agent is identified as a bot (i.e., when the status code is 403).
GO SDK 3.2.0
Features
- New targeting conditions are now available (some of them may require
GetRemoteVisitorData
pre-loaded data)- Browser Cookie
- Operating System
- IP Geolocation
- Kameleoon Segment
- Target Feature Flag
- Previous Page
- Number of Page Views
- Time since First Visit
- Time since Last Visit
- Number of Visits Today
- Total Number of Visits
- New or Returning Visitor
- Likelihood to convert
- New Kameleoon Data types were introduced:
Bug fixes
- Stability and performance improvements
GO SDK 3.1.0
Features
- Added support for additional Data API servers across the world for even faster network requests.
- Increased limit for requests to Data API: rate limits
- Added
GetVisitorWarehouseAudience
method to retrieve all data associated with a visitor's warehouse audiences and adds it to the visitor.
GO SDK 3.0.3
Bug fixes
- Stability and performance improvements
GO SDK 3.0.2
Bug fixes
- Stability and performance improvements
GO SDK 3.0.1
Bug fixes
- Stability and performance improvements
GO SDK 3.0.0
Breaking changes
- Increased the minimum required version of the Go language to 1.18.
- Renamed
Client
toKameleoonClient
- Removed
NewClient
function. Instead, useKameleoonClientFactory
- Removed
RunWhenReady
method. Instead, useWaitInit
- Changed
Config
:- Renamed
Config
toKameleoonClientConfig
- Changed the default request timeout to
10
seconds - Renamed the
Timeout
andtimeout
configuration fields toDefaultTimeout
anddefault_timeout
, respectively) - Renamed the
ConfigUpdateInterval
andconfig_update_interval
configuration fields toRefreshInterval
andrefresh_interval
, respectively.) LoadConfig
function andKameleoonClientConfig.Load
can now return an error.
- Renamed
- The
Cfg
field is no longer accessible. - Renamed
GetFeatureAllVariables
method toGetFeatureVariationVariables
(https://developers.kameleoon.com/feature-management-and-experimentation/web-sdks/go-sdk/#getfeaturevariationvariables) - Removed all methods and errors related to experiments:
- Methods:
TriggerExperiment
GetVariationAssociatedData
GetExperimentList
GetExperimentListForVisitor
- Error types:
ErrExperimentConfigNotFound
ErrNotTargeted
ErrNotAllocated
ErrSiteCodeDisabled
- Methods:
- Changed errors:
- Moved error types into
errs
package - Added
UnexpectedStatusCode
error, which can be thrown by the following methods: - Renamed the following errors:
ErrFeatureConfigNotFound
toFeatureNotFound
ErrFeatureVariableNotFound
toFeatureVariableNotFound
ErrVariationNotFound
toFeatureVariationNotFound
ErrCredentialsNotFound
toConfigCredentialsInvalid
ErrVisitorCodeNotValid
toVisitorCodeInvalid
- Moved error types into
- The new error
FeatureEnvironmentDisabled
may be returned by the following methods: - Changed
Data
types:Browser
:- Added constructor
NewBrowser
- Hid the
Type
andVersion
fields and replaced them with getter methods
- Added constructor
Conversion
:- Added constructors
NewConversion
andNewConversionWithRevenue
- Hid the
GoalId
,Revenue
, andNegative
fields and replaced them with getter methods
- Added constructors
CustomData
:- Changed the data type of the
ID
field toint
- Hid the
ID
field and replaced with a getter method - Renamed
GetValues
toValues
- Changed the data type of the
Device
:- Added constructor
NewDevice
- Hid the
Type
field and replaced with a getter method
- Added constructor
PageView
:- Added constructors
NewPageView
,NewPageViewWithTitle
- Hid the
URL
,Title
, andReferrers
fields and replaced with the getters - Changed
url
from optional to a required parameter
- Added constructors
UserAgent
:- Added constructor
NewUserAgent
- Hid
Value
field and replaced with the getter
- Added constructor
- Reworked cookies:
- Removed
SetVisitorCode
method - Removed
ObtainVisitorCode
method - Removed parameter
topLevelDomain
fromGetVisitorCode
. Instead, use thetop_level_domain
parameter in the configuration - Made
GetVisitorCode
return(string, error)
pair.
- Removed
- Removed methods that were deprecated in 2.x versions:
RetrieveDataFromRemoteSource
- Removed visitor data max size:
- Removed
visitor_data_max_size
configuration field - Removed
VisitorDataMaxSize
field fromConfig
- Removed
Features
- Added a
SetLegalConsent
method to determine the types of data Kameleoon includes in tracking requests. This helps you adhere to legal and regulatory requirements while responsibly managing visitor data. You can find more information in the Consent management policy. - Implemented
KameleoonClientFactory
(https://developers.kameleoon.com/feature-management-and-experimentation/web-sdks/go-sdk/#kameleoonclientfactory) to manageKameleoonClient
instances: - Added
WaitInit
method to wait until the initialization process is completed - Added new parameters for
KameleoonClientConfig
:SessionDuration
(session_duration
configuration field accordingly)TopLevelDomain
field toConfig
(top_level_domain
configuration field accordingly)
Bug fixes
- Stability and performance improvements
GO SDK 2.3.1
Features
- Added support for older versions of the Go language. You can now use version 1.12 or later (previously, the minimum version was 1.16).
GO SDK 2.3.0
Features
- Added
GetRemoteVisitorData
method to fetch a visitor's remote data (with an optional capability to add the fetched data to the visitor).
Bug fixes
- Stability and performance improvements
GO SDK 2.2.0
- Stability and performance improvements
internal
Migration to a new Data API (data.kameleoon.io)