You can configure the Shake feature for some ad platforms via code.
Currently, Adx, Baidu, Pangle (China), GDT, Kuaishou, Jingdong Ads, Qumeng, VIVO, Octopus, and Beizi have launched info feed Shake features.
| Ad Platform | Requires Platform Permission | Taku SDK Version Requirement | Taku SDK Rendering Needed | Taku Dashboard Config | Remarks |
|---|---|---|---|---|---|
| Adx | Yes | Taku SDK v6.2.85 and above supported | No | None | Contact Taku Operations to enable |
| Baidu | Feature is open by default, media needs to call SDK corresponding component | Taku SDK v6.2.60 and above supported | Yes | None | Refer to code setup below for integration |
| Kuaishou | Yes | Taku Android SDK v6.2.65 and above supported | No | Yes | View |
| Pangle (China) | Open by default. Can be enabled when creating Native info feed. | None | No | None | View |
| GDT | Yes | None | No | None | Contact GDT to obtain |
| Jingdong Ads | Feature is open by default, media needs to call SDK corresponding component | None | Yes | None | Refer to code setup below for integration |
| Qumeng | Feature is open by default, media needs to call SDK corresponding component | None | Yes | None | Refer to code setup below for integration |
| VIVO | Feature is open by default, media needs to call SDK corresponding component | None | Yes | None | Refer to code setup below for integration |
| Octopus | Yes | Taku SDK v6.5.36 and above supported | No | None | Contact Octopus to obtain |
| Beizi | Yes | Taku SDK v6.5.36 and above supported | No | None | Contact Beizi to obtain |
(1) You need to apply to the ad platform for the info feed self-rendering Shake feature permission and obtain a third-party ad placement ID with this feature.
(2) Your app needs to add Shake interaction for info feed ads. When using third-party ad placements that support Shake, the info feed ad must display the "Shake" interaction. Otherwise, if the user shakes their phone without seeing the "Shake" related prompt, it will trigger the ad platform click and redirect, which does not comply with regulatory requirements. Shake interaction can refer to the Pangle (China) example:

(3) If the Shake interaction display area can trigger an ad click, the suggested text configuration is Tap or Shake to navigate to the details page or third-party app.
(4) Add a new traffic group in the Taku dashboard (using the app version rule), and add the third-party ad placement ID that supports the Shake feature for the app version that has already implemented the info feed "Shake" interaction.
(5) For Shake sensitivity configuration, please contact the ad platform AM for adjustments.
(1) When using the Kuaishou info feed self-rendering Shake feature, you need to enable the Shake switch when adding a Kuaishou info feed Ad Source.

(2) If your account does not have this switch, please contact Taku to enable it.
/**
* Render the Shake component. If the ad does not support the Shake capability, null is returned. Supported platforms: Baidu, Jingdong Ads, Qumeng, VIVO.
* @param context Context
* @param adMaterial Ad creative
* @param shakeViewContainer Component container
*/
private static void renderShakeView(Context context, ATNativeMaterial adMaterial, FrameLayout shakeViewContainer) {
int shakeViewWidth = dip2px(context, 100); // Component width, not less than 80dp
int shakeViewHeight = dip2px(context, 100); // Component height, not less than 80dp
View shakeView = adMaterial.getShakeView(shakeViewWidth, shakeViewHeight, new ATShakeViewListener() {
@Override
public void onDismiss() {
shakeViewContainer.setVisibility(View.GONE);
}
});
if (shakeView != null) {
if (shakeView.getParent() instanceof ViewGroup) {
((ViewGroup) shakeView.getParent()).removeView(shakeView);
}
shakeViewContainer.setVisibility(View.VISIBLE);
FrameLayout.LayoutParams shakeViewLayoutParams = new FrameLayout.LayoutParams(shakeViewWidth, shakeViewHeight);
shakeViewLayoutParams.gravity = Gravity.CENTER;
shakeViewContainer.addView(shakeView, shakeViewLayoutParams);
}
}
Yes, you can add the view returned by getShakeView to the layout and then set its opacity to 0.
Currently, no sensitivity is exposed, and the sensitivity cannot be controlled via API. It can only be configured and adjusted by our operations team.
Note: Pangle (China), GDT, and Kuaishou platforms do not require additional code to set up the Shake View. Adx renders the Shake View by default, but developers can also control the position of the Shake View using the code above.