MET-5092: Prepare publisher facing API for Unity plugin - #97
Merged
Conversation
…ment has started. Taking steps towards the new API design. - `Metica.Unity` is no more. - `Metica.SDK` now depends on `Metica.ADS` - `Metica.ADS` does NOT depend on `Metica.SDK` anymore. - `MeticaSdk` now initializes `MeticaAds` too. - `MaxSdk` still needs app-level initialization (aka up to the user).
…egistering) services at initialization phase.
…icaSdk static field)
{
// TODO: currently we force trial user group
_tcs.SetResult(
new MeticaInitializationResult(MeticaAdsAssignmentStatus.Normal)
);
/*
- Move `ILog` to `Metica.Core` - Substitute all calls to `UnityEngine.Debug.Log` (in `Metica.ADS` classes) with `MeticaAds.Log.LogDebug` (yes... not the nicest call)
# Conflicts: # Assets/Plugins/Android/mainTemplate.gradle # Assets/StreamingAssets/Metica/sdkInfo.json Merge branch 'develop' into tomi-unity_bridge # Conflicts: # Editor/MeticaAdsDependencies.xml # Runtime/ADS/Metica.ADS.asmdef # Runtime/ADS/MeticaAds.cs # Runtime/ADS/Platform/Android/AndroidDelegate.cs # Runtime/ADS/Platform/Android/BannerCallbackProxy.cs # Runtime/ADS/Platform/Android/InitializeCallbackProxy.cs # Runtime/ADS/Platform/Android/LoadCallbackProxy.cs # Runtime/ADS/Platform/UnityPlayer/UnityPlayerDelegate.cs # Runtime/SDK/MeticaSdk.cs # Runtime/SDK/SdkConfig.cs # package.json
{
MeticaAds.Log.LogDebug(() => $"{TAG} SetHasUserConsent called with: {hasUserConsent}");
_unityBridgeAndroidClass.CallStatic("setHasUserConsent", hasUserConsent);
}
public void SetDoNotSell(bool doNotSell)
antonurankar-moloco
marked this pull request as ready for review
October 17, 2025 10:54
AKajt
reviewed
Oct 20, 2025
AKajt
approved these changes
Oct 20, 2025
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Streamlines the Metica SDK initialization flow by separating core configuration from mediation setup, while adding GDPR/CCPA privacy controls for better compliance.
What's Changed
🔄 Initialization API Redesign
MeticaConfigurationinto focusedMeticaInitConfig(core SDK params) andMeticaMediationInfo(ad network config)MeticaAdsAssignmentStatusenum with clearerMeticaUserGroupmodelMeticaInitializationResulttoMeticaInitResponsewith directSmartFloorsaccess🔒 Privacy Compliance
SetHasUserConsent(bool)for GDPR consent managementSetDoNotSell(bool)for CCPA compliance🧹 Code Quality
userGroup→UserGroup,isSuccess→IsSuccess)Version,CustomKeys, configurableBaseEndpoint)Breaking Changes⚠️
Before:
After: