Skip to main content

Changelog

Changelog

If you have previously read the SDK guide for an earlier version (0.0.1), check this section for changes.


v0.2.0 (2026-06-24) — Current Version

New Features

  1. Unified Rewarded Slot API added: Rewarded video, banner, and share have been unified into a single slot model. Query the active slots to render them, and run any of them with a single showRewardedAd({ slotId }) call on user tap.

    // Query active slots
    const { slots } = await TudadaSDK.getRewardedAdSlotsAsync();

    // Run a slot (action: REWARD_VIDEO / BANNER / SHARE dispatched automatically)
    const res = await TudadaSDK.showRewardedAdAsync({ slotId: slots[0].slotId });
    if (res.isEnded) giveReward();
    • New: getRewardedAdSlots() / getRewardedAdSlot(slotId) (+ *Async)
    • showRewardedAd() accepts both slotId (slot) and adUnitId (video fallback)
    • See: Ad API → Unified Rewarded Slot
  2. Payment API added: An in-game product purchase API has been added. The game purchases using only a productId; the payment method, price, verification, and delivery are handled by the platform.

    const products = await TudadaSDK.payment.getProductsAsync();
    const txn = await TudadaSDK.payment.purchaseAsync('coin_100');
    if (txn.status === 'GRANTED') { /* delivery complete — finalize on the game server */ }
    • Split into callback versions (payment.getProducts() etc., return void) and Promise versions (getProductsAsync() etc.)
    • All four offer an *Async variant: getProductsAsync / getProductAsync / purchaseAsync / getTransactionAsync
    • Errors are branched by code (callback version via fail, *Async version via reject)
    • See: Payment API
  3. servicePlatform field added to SystemInfo and AppBaseInfo: Identifies which host service ('kakaotalk' / 'kakaopay' / 'house') the game is running in.

    const info = TudadaSDK.getSystemInfoSync();
    console.log(info.servicePlatform); // 'kakaotalk' | 'kakaopay' | 'house'

Deprecated

  • createRewardedVideoAd (legacy) — wx-compatible legacy instance API. Replaced by the unified showRewardedAd() / showRewardedAdAsync(); will be removed in a future version.
  • Banner Ad API (getAvailableBannerIds / getBanner / runBannerAction + *Async) — replaced by the Unified Rewarded Slot. Use getRewardedAdSlots() + showRewardedAd({ slotId }) (action=BANNER). Maintained for compatibility.
  • shareForReward / shareForRewardAsync — replaced by the Unified Rewarded Slot. Use showRewardedAd({ slotId }) (action=SHARE). Maintained for compatibility.

v0.1.6 (2026-05-12)

New Features

  1. Banner Ad API added (slot model): A new API has been added that lets the game receive banner images per slot, render them itself, and delegate actions to the platform on user tap.

    // 1) List active banner slot IDs
    TudadaSDK.getAvailableBannerIds({
    success: (res) => console.log('slots:', res.bannerIds),
    });

    // 2) Fetch banner data matched to a slot
    TudadaSDK.getBanner({
    bannerId: 'main_menu_top',
    success: (res) => {
    if (res.banner) renderBanner(res.banner.imageUrl);
    },
    });

    // 3) Delegate the action on user tap (reward is handled by the game)
    TudadaSDK.runBannerAction({ bannerId: 'main_menu_top' });
    • Callback / Promise pair: every function ships with an *Async() variant
    • bannerId doubles as the game-defined slot name
    • runBannerAction only signals success/fail — the game handles reward delivery itself
    • See: Ad API → Banner Ad
  2. TudadaSDK.gameAction action logging API added (Phase 1): Sends game lifecycle actions to the platform as fire-and-forget events.

    // Game start
    TudadaSDK.gameAction.start();

    // Game clear
    TudadaSDK.gameAction.complete({ payload: { score: 1200, level: 5 } });

    // Game exit (with reason)
    TudadaSDK.gameAction.exit({ payload: { reason: 'USER_QUIT' } });
    • start(option?) / complete(option) / exit(option) — lifecycle action signals
    • The SDK also auto-emits a one-time game-loading-complete signal when initialization finishes
    • Calls are fire-and-forget; downstream routing is the platform's responsibility
    • See: GameAction API
  3. login() response now includes user info credential fields

    The login() success response now includes a signed user info credential that the game server can verify on its own using only a shared secret key — no server-to-server call required.

    TudadaSDK.login({
    success: (res) => {
    // Existing fields — unchanged
    console.log(res.code, res.userId);

    // Verify on game server
    sendToGameServer({
    payload: res.userInfoPayload,
    signature: res.userInfoSignature,
    });
    },
    });
    • userInfoPayload: URL-encoded query string (gameUserId, name, profileImageUrl, authDate, attribute)
    • userInfoSignature: HMAC signature over the payload
    • Existing response signature (code, userId, errMsg, errCode) is preserved — wx.login compatibility maintained
    • See: Auth API → User Info Credential
  4. getUserInfo() response reshaped to Tudada-fit (Breaking change)

    The wx-compatible 4 fields (encryptedData/iv/signature/rawData) are removed from getUserInfo(). It now returns the same credential as login() (userInfoPayload/userInfoSignature). The withCredentials option is also removed.

    // before (v0.1.5)
    TudadaSDK.getUserInfo({
    withCredentials: true,
    success: (res) => {
    sendToServer(res.encryptedData, res.iv); // mock-only — not actually verifiable
    },
    });

    // after (v0.1.6)
    TudadaSDK.getUserInfo({
    success: (res) => {
    console.log(res.userInfo.nickName);
    sendToGameServer({
    payload: res.userInfoPayload, // same value as login()
    signature: res.userInfoSignature,
    });
    },
    });
    • wx.getUserInfo is removed from the wx-compatibility surface — keep using TudadaSDK.getUserInfo
    • See: Auth API → getUserInfo

v0.1.5 (2026-03-30)

New Features

  1. shareForReward API added: A new API for granting rewards upon share completion has been added.

    TudadaSDK.shareForReward({
    url: 'https://example.com/share', // optional
    success: (res) => {
    if (res.rewarded) console.log('Share complete — reward granted');
    },
    fail: (err) => console.error('Share failed:', err.errMsg),
    });

    // Promise pattern
    const result = await TudadaSDK.shareForRewardAsync({ url: 'https://example.com/share' });
    if (result.rewarded) console.log('Reward granted');
    • shareForReward(): Callback pattern (success/fail/complete)
    • shareForRewardAsync(): Promise pattern
    • Share handling is automatically managed by the platform

v0.1.4 (2026-03-18)

New Features

  1. showRewardedAd API added: Handles everything from loading to displaying a rewarded ad in a single call.

    TudadaSDK.showRewardedAd({
    adUnitId: 'your-ad-unit-id',
    success: (res) => {
    if (res.isEnded) console.log('Watch complete — reward granted');
    },
    fail: (err) => console.error('Ad failed:', err.errMsg),
    });

    // Promise pattern
    const result = await TudadaSDK.showRewardedAdAsync({ adUnitId: 'your-ad-unit-id' });
    • showRewardedAd(): Callback pattern (success/fail/complete) — recommended
    • showRewardedAdAsync(): Promise pattern
    • The platform handles ad loading, display, retries, loading UI, and failure popups automatically
    • createRewardedVideoAd is maintained as legacy (@deprecated)
  2. CheckFeature API added: Allows you to check in advance whether a specific API is supported on the current platform.

    TudadaSDK.checkFeature({
    apiName: 'startAccelerometerSensor',
    success: (res) => console.log('Supported:', res.apiName),
    fail: (res) => console.log('Unsupported:', res.status),
    });

    // Promise pattern
    const result = await TudadaSDK.checkFeatureAsync('startAccelerometerSensor');
    • checkFeature(): Callback-based — success (supported) / fail (unsupported)
    • checkFeatureAsync(): Promise-based — both supported and unsupported resolve
    • Unsupported reasons: unknown_api | version_required | platform_unsupported | device_unsupported | permission_denied
  3. LaunchOptions API added: Allows you to retrieve query parameters and referrer information passed when the game launches.

    const options = TudadaSDK.getLaunchOptions();
    console.log('Query:', options.query);
    • getLaunchOptions(): Sync — returns pre-cached launch options
    • getLaunchOptionsAsync(): Async — fetches the latest launch options

Changes

  • wx object officially classified as legacy: API calls through the wx object have been officially classified as a legacy compatibility feature for porting existing WeChat games.
    • Only existing APIs registered up to v0.1.2 are exposed on the wx object.
    • New APIs added from v0.1.3 onwards (accelerometer, checkFeature, getLaunchOptions, etc.) are TudadaSDK-exclusive and cannot be used through the wx object.
    • After porting is complete, we recommend gradually transitioning to direct TudadaSDK calls.

v0.1.3 (2026-02-26)

New Features

  1. Accelerometer API added: Flat accelerometer sensor APIs have been added. This is a TudadaSDK-specific interface that is not compatible with the wx API (wx.startAccelerometer, etc.) — the API names and parameter structures differ. It cannot be used through the wx object and must be called directly from TudadaSDK.

    TudadaSDK.onAccelerometerChange((res) => {
    console.log(`X: ${res.x}, Y: ${res.y}, Z: ${res.z}`);
    });

    TudadaSDK.startAccelerometerSensor({
    sensitivity: 'normal',
    success: () => console.log('Sensing started'),
    });

    TudadaSDK.stopAccelerometerSensor();
    • startAccelerometerSensor(), stopAccelerometerSensor(), onAccelerometerChange(), offAccelerometerChange()
    • Independent interface different from wx API (e.g., startAccelerometerSensor vs wx.startAccelerometer)
    • Receives XYZ-axis acceleration data
    • Sensitivity-based control: 'sensitive' | 'normal' | 'insensitive'

v0.1.2 (2026-02-26)

New Features

  1. environment field added to SystemInfo and AppBaseInfo

    A field indicating the current access environment has been added.

    const info = TudadaSDK.getSystemInfoSync();
    console.log(info.environment); // 'prod' or 'dev'

    const appInfo = TudadaSDK.getAppBaseInfo();
    console.log(appInfo.environment); // 'prod' or 'dev'
    ValueDescription
    'prod'Production environment
    'dev'Development environment

    This can be used, for example, to switch resource CDN addresses based on the environment.

    const info = TudadaSDK.getSystemInfoSync();
    const cdnBase = info.environment === 'prod'
    ? 'https://cdn.example.com/prod'
    : 'https://cdn.example.com/dev';

v0.1.1 (2026-02-20)

  • Internal improvements applied (no game code changes required)

v0.1.0 (2026-02-06)

New Features

  1. userId field added to login() response

    TudadaSDK.login({
    success: (res) => {
    console.log(res.code); // existing
    console.log(res.userId); // newly added
    },
    });
  2. SystemInfo.wifiEnabled now returns the actual value

    Previously returned a fixed value, but now returns the actual Wi-Fi enabled status.

Breaking Changes (Migration Required)

  1. checkSession() success callback result type changed

    // 0.0.1 — success callback included login info
    TudadaSDK.checkSession({
    success: (res) => {
    // res contained code, userId, etc.
    },
    });

    // 0.1.0 onwards — success callback contains only general result
    TudadaSDK.checkSession({
    success: (res) => {
    // res contains only errMsg (GeneralCallbackResult)
    // Call login() separately if login info is needed
    },
    });

v0.0.2

New Features

  1. Audio API added: The createInnerAudioContext() method has been added.

    const audio = TudadaSDK.createInnerAudioContext();
    audio.src = './bgm.mp3';
    audio.loop = true;
    audio.play();
    • Audio playback/pause/stop/seek
    • Volume and playback speed control
    • Various event listeners (onPlay, onEnded, onError, etc.)

v0.0.1 (2026-02-02) — Initial Release

This is the initial release version. The following APIs are included:

  • Auth API (login, checkSession, getUserInfo)
  • Storage API (set/get/remove/clear + Sync versions)
  • TudadaStore API (cloud storage)
  • System API (getSystemInfo, getWindowInfo, getDeviceInfo, etc.)
  • UI API (getMenuButtonBoundingClientRect)
  • Device API (vibration, keyboard)
  • Clipboard API
  • Ad API (rewarded video ads)
  • Lifecycle API (onShow, onHide, exitMiniProgram, restartMiniProgram)