ผสานรวม Zucks กับสื่อกลาง
จัดทุกอย่างให้เป็นระเบียบอยู่เสมอด้วยคอลเล็กชัน
บันทึกและจัดหมวดหมู่เนื้อหาตามค่ากำหนดของคุณ
คู่มือนี้มีไว้สําหรับผู้เผยแพร่โฆษณาที่สนใจใช้สื่อกลางโฆษณาในอุปกรณ์เคลื่อนที่ของ Google กับ Zucks ซึ่งจะอธิบายการตั้งค่าอะแดปเตอร์สื่อกลางให้ทํางานร่วมกับแอป Android ปัจจุบันและการกำหนดค่าการตั้งค่าเพิ่มเติม
ข้อกำหนดเบื้องต้น
ข้อมูลเบื้องต้นที่เป็นประโยชน์
บทความต่อไปนี้ในศูนย์ช่วยเหลือให้ข้อมูลเบื้องต้นเกี่ยวกับการสื่อกลาง
เพิ่ม Zucks ลงในโปรเจ็กต์
ระบุอะแดปเตอร์เครือข่ายและ SDK
ดาวน์โหลด SDK และอะแดปเตอร์ Zucks จากลิงก์ก่อนหน้า
ใน Android Studio ให้ใส่ไฟล์อะแดปเตอร์และ SDK ในlibs
โฟลเดอร์ของโปรเจ็กต์ ตรวจสอบว่าไฟล์ Gradle ระดับแอปมีข้อมูลต่อไปนี้
Kotlin
dependencies {
implementation(fileTree(mapOf("dir" to "libs", "include" to listOf("*.aar", "*.jar"))))
// ...
}
Groovy
dependencies {
implementation fileTree(dir: 'libs', include: ['*.aar', '*.jar'])
// ...
}
แก้ไขไฟล์ AndroidManifest.xml
ตามวิธีการในเอกสารประกอบของ Zucks
แอปของคุณไม่จําเป็นต้องเรียกใช้ Zucks โดยตรง เนื่องจาก SDK โฆษณาในอุปกรณ์เคลื่อนที่ของ Google จะเรียกใช้อะแดปเตอร์ Zucks เพื่อดึงข้อมูลโฆษณาในนามของคุณ คุณสามารถระบุพารามิเตอร์คำขอเพิ่มเติมได้หากจำเป็น
ส่วนที่เหลือของหน้านี้จะอธิบายวิธีให้ข้อมูลเพิ่มเติมแก่คุณ Zuckerberg
เริ่มต้นออบเจ็กต์โฆษณาด้วยอินสแตนซ์กิจกรรม
ในคอนสตรคเตอร์สําหรับออบเจ็กต์โฆษณาใหม่ (เช่น AdView
) คุณจะต้องส่งออบเจ็กต์ประเภท Context
ระบบจะส่ง Context
นี้ไปยังเครือข่ายโฆษณาอื่นๆ เมื่อใช้สื่อกลาง เครือข่ายโฆษณาบางเครือข่ายต้องใช้ Context
ที่เข้มงวดมากขึ้นซึ่งมีประเภทเป็น Activity
และอาจแสดงโฆษณาไม่ได้หากไม่มีอินสแตนซ์ Activity
ดังนั้น เราขอแนะนําให้ส่งอินสแตนซ์ Activity
เมื่อเริ่มต้นวัตถุโฆษณา เพื่อให้ได้รับประสบการณ์การใช้งานที่สอดคล้องกับเครือข่ายโฆษณาสื่อกลาง
เนื้อหาของหน้าเว็บนี้ได้รับอนุญาตภายใต้ใบอนุญาตที่ต้องระบุที่มาของครีเอทีฟคอมมอนส์ 4.0 และตัวอย่างโค้ดได้รับอนุญาตภายใต้ใบอนุญาต Apache 2.0 เว้นแต่จะระบุไว้เป็นอย่างอื่น โปรดดูรายละเอียดที่นโยบายเว็บไซต์ Google Developers Java เป็นเครื่องหมายการค้าจดทะเบียนของ Oracle และ/หรือบริษัทในเครือ
อัปเดตล่าสุด 2025-02-08 UTC
[[["เข้าใจง่าย","easyToUnderstand","thumb-up"],["แก้ปัญหาของฉันได้","solvedMyProblem","thumb-up"],["อื่นๆ","otherUp","thumb-up"]],[["ไม่มีข้อมูลที่ฉันต้องการ","missingTheInformationINeed","thumb-down"],["ซับซ้อนเกินไป/มีหลายขั้นตอนมากเกินไป","tooComplicatedTooManySteps","thumb-down"],["ล้าสมัย","outOfDate","thumb-down"],["ปัญหาเกี่ยวกับการแปล","translationIssue","thumb-down"],["ตัวอย่าง/ปัญหาเกี่ยวกับโค้ด","samplesCodeIssue","thumb-down"],["อื่นๆ","otherDown","thumb-down"]],["อัปเดตล่าสุด 2025-02-08 UTC"],[[["The Mediation Test Suite allows you to test whether your mediation setup is configured correctly before going live to ensure ad requests and revenue are flowing as expected."],["By integrating the Mediation Test Suite into your app, you gain access to detailed, real-time insights into the ad mediation waterfall to troubleshoot setup problems quickly."],["The suite offers comprehensive functionalities such as manual ad requests for testing specific scenarios, a visual ad request waterfall, and adapter status reports to monitor adapter configuration."],["It enables you to manage and organize multiple ad units and ad sources within the test suite, including line item details and other properties for each ad source."],["This ensures a seamless and optimized ad mediation experience, leading to higher fill rates, increased ad revenue, and improved app performance."]]],["Publishers using Google Mobile Ads mediation with Zucks should integrate the Zucks SDK and adapter into their Android app via Android Studio's `libs` folder and update their app-level Gradle file. They must also configure the `AndroidManifest.xml` according to Zucks' documentation. An `Activity` instance should be passed when initializing ad objects for mediated ad networks. The Google Mobile Ads SDK handles fetching ads via the Zucks adapter, without direct calls from the app.\n"]]