Firebase 将于 5 月 14 日重返 Google I/O 大会!
立即报名。
สร้างแคมเปญ
จัดทุกอย่างให้เป็นระเบียบอยู่เสมอด้วยคอลเล็กชัน
บันทึกและจัดหมวดหมู่เนื้อหาตามค่ากำหนดของคุณ
ก่อนเริ่มต้น
ตรวจสอบว่าคุณได้ทําตามขั้นตอนในเริ่มต้นใช้งานเพื่อตรวจสอบว่าคุณมีแอปที่เปิดใช้ Firebase และได้เพิ่ม Firebase In-App Messaging
SDK เวอร์ชันล่าสุดแล้ว
สร้างแคมเปญใหม่
ตั้งค่าแคมเปญใหม่ในFirebaseคอนโซล
หน้าการรับส่งข้อความ
- หากเป็นผู้ใช้ครั้งแรก ให้คลิกสร้างแคมเปญแรก
- หากไม่มี ให้คลิกแคมเปญใหม่
ขั้นตอนที่ 1: สไตล์และเนื้อหา
ในคอนโซล ให้ใช้Firebase In-App Messagingเทมเพลตข้อความเพื่อรวมฟีเจอร์ต่างๆ
เพื่อตอบสนองวัตถุประสงค์ที่แตกต่างกันด้วยข้อความในแอป
สำรวจกรณีการใช้งานเพื่อดู
ตัวอย่างการจัดรูปแบบเทมเพลตข้อความ
ประเภทเทมเพลตข้อความ |
ฟีเจอร์ |
รายละเอียดฟีเจอร์ |
การ์ด |
โมดัล |
เฉพาะรูปภาพ |
แบนเนอร์ |
lens |
lens |
lens |
lens |
รูปภาพ |
ระบุ URL รูปภาพแบบ HTTPS คุณใช้
Firebase Hosting เพื่อโฮสต์รูปภาพได้ |
lens |
lens |
lens |
lens |
การดำเนินการ |
ใช้เว็บลิงก์หรือ Deep Link เพื่อส่งผู้ใช้ไปยังหน้าเว็บภายนอก
หรือหน้าเว็บที่เฉพาะเจาะจงในแอป คุณใช้ลิงก์แบบไดนามิกของ Firebase เพื่อสร้างและจัดการ Deep Link ได้ เทมเพลตโมดอล
และรูปภาพเท่านั้นมีปุ่ม X ซึ่งช่วยให้ผู้ใช้
ปิดข้อความได้ |
lens |
lens |
|
lens |
สีข้อความ/พื้นหลัง |
ปรับแต่งภาพของข้อความโดยป้อนรหัสสีแบบเลขฐานสิบหกหรือใช้
การไล่ระดับสีเพื่อค้นหาสีที่เฉพาะเจาะจงซึ่งตรงกับแบรนด์ของคุณ |
lens |
lens |
|
lens |
ชื่อ/เนื้อหาของข้อความ |
ดึงดูดความสนใจของผู้ใช้ด้วยส่วนหัวที่เกี่ยวข้องและคำอธิบายที่กระชับ
Firebase จะแปลและปรับขนาดข้อความโดยอัตโนมัติเพื่อให้เหมาะกับผู้ใช้ |
lens |
lens |
|
|
ปุ่มหลัก |
การดำเนินการเริ่มต้นของปุ่มจะตั้งค่าเป็นการปิดข้อความ ระบุ
URL เพื่อเปลี่ยนเส้นทางผู้ใช้เป็นการดำเนินการ |
lens |
|
|
|
ปุ่มรอง |
การดำเนินการเริ่มต้นของปุ่มจะตั้งค่าเป็นการปิดข้อความ ระบุ
URL เพื่อเปลี่ยนเส้นทางผู้ใช้เป็นการดำเนินการ |
ในหน้าต่างเขียนแคมเปญของFirebaseคอนโซล ให้ปรับแต่ง
ข้อความตามที่คุณต้องการด้วยฟีเจอร์ที่มีให้ในแต่ละเทมเพลต
ทางด้านขวาของหน้าต่างสร้างแคมเปญ ให้ดูตัวอย่างข้อความในแนวนอนหรือแนวตั้งสำหรับอุปกรณ์โทรศัพท์หรือแท็บเล็ต
ตัวอย่างในคอนโซลแสดงให้เห็นถึงแนวคิดทั่วไปของวิธีที่ข้อความจะปรากฏบนอุปกรณ์เคลื่อนที่ การแสดงผลข้อความตามจริงจะแตกต่างกันไปขึ้นอยู่กับอุปกรณ์
ทดสอบกับอุปกรณ์จริงเพื่อดูการแสดงผลที่แน่นอน
หากต้องการ ให้กำหนดข้อมูลเมตาที่กำหนดเองสำหรับแคมเปญ ข้อมูลเมตานี้จะพร้อมใช้งาน
ในฝั่งไคลเอ็นต์โดยใช้การเรียกกลับของ SDK เมื่อแคมเปญแสดงต่อผู้ใช้
เช่น คุณอาจต้องการติดแท็กแคมเปญด้วยรหัสโปรโมชันที่ใช้ในไคลเอ็นต์ได้
ขั้นตอนที่ 2: กำหนดเป้าหมายผู้ใช้
ป้อนชื่อแคมเปญ
ชื่อนี้ใช้สำหรับการรายงานแคมเปญและไม่ใช่ส่วนหนึ่งของข้อความที่แสดง
(ไม่บังคับ) ระบุคำอธิบายแคมเปญ
คำอธิบายนี้ใช้สำหรับการรายงานแคมเปญและไม่ใช่ส่วนหนึ่งของข้อความที่แสดง
คลิกเมนูแบบเลื่อนลงเลือกแอป แล้วระบุแอปที่ต้องการเชื่อมโยงกับแคมเปญนี้
(ไม่บังคับ) คลิกปุ่ม and เพื่อจำกัดผู้ใช้เป้าหมายให้แคบลง
ใช้เมนูแบบเลื่อนลงเลือกเพื่อเลือกข้อกำหนดเพิ่มเติม
ดูเปอร์เซ็นต์ของผู้ที่มีโอกาสเป็นผู้ใช้ที่มีสิทธิ์ในแคมเปญนี้
ตัวเลขนี้เป็นค่าประมาณที่อิงตามผู้ใช้ที่ใช้งานอยู่ซึ่งติดต่อบริการในช่วง 7 วันที่ผ่านมา
ผู้ใช้ที่มีสิทธิ์จะเห็นข้อความนี้หากเงื่อนไขทริกเกอร์เกิดขึ้นเท่านั้น
(ไม่บังคับ) หากแอปกำหนดเป้าหมายผู้ใช้ในหลายภาษา ระบบจะแจ้งให้คุณแปลแคมเปญเป็นภาษาเหล่านั้น
ใช้กล่องโต้ตอบเพื่อ
เพิ่มคำแปลของคุณเองหรือใช้ Google แปลภาษาเพื่อแปลแคมเปญ
เป็นภาษาท้องถิ่นได้อย่างง่ายดาย
ขั้นตอนที่ 3: ตั้งเวลาส่งข้อความ
อธิบายวันที่และเวลาเริ่มต้นของแคมเปญ
แคมเปญจะเริ่มได้เมื่อคุณเผยแพร่แคมเปญหรือกำหนดเวลา
เริ่มต้นไว้
อธิบายวันที่และเวลาสิ้นสุดของแคมเปญ
แคมเปญสามารถทำงานได้เรื่อยๆ หรือมีจุดสิ้นสุดที่กำหนดไว้
คลิกเหตุการณ์ + เพื่อเพิ่มเหตุการณ์ทริกเกอร์อย่างน้อย 1 รายการ
- คุณสามารถป้อนเหตุการณ์เริ่มต้นหรือ
เหตุการณ์ที่บันทึกผ่าน Firebase Analytics
เพื่อทริกเกอร์ข้อความในแอป เหตุการณ์เหล่านี้อาจเป็นการกระทำของผู้ใช้
เหตุการณ์ของระบบ หรือข้อผิดพลาด
- ระบบจะทริกเกอร์ข้อความในแอปเมื่อมีเหตุการณ์เกิดขึ้น
ระบุขีดจำกัดความถี่ต่ออุปกรณ์ ขีดจำกัดนี้ช่วยให้คุณ
ควบคุมความถี่ที่ผู้ใช้จะเห็นข้อความของคุณได้
- โดยค่าเริ่มต้น ระบบจะไม่แสดงแคมเปญหลังจากที่ผู้ใช้เห็น (นั่นคือได้รับการแสดงผล) แคมเปญดังกล่าว 1 ครั้ง
- หรือจะกำหนดความถี่ของข้อความเป็นวันก็ได้
ขั้นตอนที่ 4: เหตุการณ์ Conversion (ไม่บังคับ)
Firebase จะติดตามจำนวนการแสดงผลที่ทำให้เกิดเหตุการณ์ Conversion ที่เสร็จสมบูรณ์
ในหน้าต่างสร้างแคมเปญ ให้ใช้เมนูแบบเลื่อนลงเลือกเหตุการณ์ Conversion
เพื่อเลือกจากตัวเลือกต่อไปนี้
หลังจากเผยแพร่แคมเปญแล้ว ให้ไปที่หน้าการรับส่งข้อความ
แล้วคลิกชื่อแคมเปญเพื่อดูข้อมูลที่เกี่ยวข้องกับ
ประวัติ Conversion ของแคมเปญ
การเผยแพร่แคมเปญ
หลังจากแก้ไขแคมเปญแล้ว คุณสามารถคลิกบันทึกเป็นฉบับร่างเพื่อกลับมาแก้ไขแคมเปญในสถานะฉบับร่างได้
หรือคลิกเผยแพร่เพื่อแสดงข้อความต่อผู้ใช้เป้าหมายในวันที่กำหนด คุณแก้ไขแคมเปญได้หลังจากเผยแพร่แล้ว
เมื่อหยุดแคมเปญที่เผยแพร่แล้ว คุณจะเผยแพร่แคมเปญดังกล่าวไม่ได้อีก
อย่างไรก็ตาม คุณสามารถหยุดหรือแก้ไขแคมเปญที่ทำงานอยู่ได้ทุกเมื่อ นอกจากนี้ คุณยังทำซ้ำแคมเปญที่มีอยู่เพื่อสร้างรูปแบบที่แตกต่างกันเล็กน้อยและหลีกเลี่ยงการสร้างแคมเปญใหม่ทั้งหมดได้ด้วย
รับข้อมูลเชิงลึกจาก AI สำหรับแคมเปญการรับส่งข้อความด้วย Gemini ใน Firebase
Gemini ใน Firebase
ให้สรุปแคมเปญการรับส่งข้อความ ข้อมูลเชิงลึก
และคำแนะนำในการปรับปรุงประสิทธิภาพของแคมเปญ Firebase Cloud Messaging และ In-App Messaging
การวิเคราะห์ข้อมูลแคมเปญ
Gemini ใน Firebase ช่วยให้คุณเข้าใจการเข้าถึงและผลลัพธ์ของแคมเปญ
และแนะนำกลยุทธ์เพื่อปรับปรุงการมีส่วนร่วมและการเติบโตของผู้ใช้
เข้าถึงข้อมูลเชิงลึกจาก AI สําหรับแคมเปญการรับส่งข้อความ
หากต้องการใช้ข้อมูลเชิงลึกจาก AI ของแคมเปญการรับส่งข้อความ โปรดตรวจสอบว่าโปรเจ็กต์มีสิ่งต่อไปนี้
เปิดใช้ Gemini ใน Firebase สำหรับโปรเจ็กต์ของคุณแล้ว ดูข้อมูลเพิ่มเติมได้ที่
ตั้งค่า Gemini ใน Firebase
Firebase Cloud Messaging หรือ In-App Messaging เปิดใช้ในโปรเจ็กต์ Firebase
มีแคมเปญอย่างน้อย 1 รายการและปรากฏในคอนโซล Firebase
หลังจากตรวจสอบว่ามีคุณสมบัติตรงตามข้อกำหนดเหล่านี้แล้ว ให้ทำดังนี้
เปิด Messaging ในคอนโซล Firebase เพื่อเข้าถึงข้อมูลแคมเปญ
หลังจากโหลดข้อมูลแคมเปญแล้ว ให้คลิกสร้างข้อมูลเชิงลึกจาก AI
ข้อมูลสรุปและการวิเคราะห์แคมเปญการรับส่งข้อความจะปรากฏขึ้น
ราคา
ดูข้อมูลเพิ่มเติมได้ที่การกำหนดราคาFirebaseของ Gemini
เนื้อหาของหน้าเว็บนี้ได้รับอนุญาตภายใต้ใบอนุญาตที่ต้องระบุที่มาของครีเอทีฟคอมมอนส์ 4.0 และตัวอย่างโค้ดได้รับอนุญาตภายใต้ใบอนุญาต Apache 2.0 เว้นแต่จะระบุไว้เป็นอย่างอื่น โปรดดูรายละเอียดที่นโยบายเว็บไซต์ Google Developers Java เป็นเครื่องหมายการค้าจดทะเบียนของ Oracle และ/หรือบริษัทในเครือ
อัปเดตล่าสุด 2025-08-17 UTC
[null,null,["อัปเดตล่าสุด 2025-08-17 UTC"],[],[],null,["\u003cbr /\u003e\n\nBefore you begin\n\nMake sure you complete the steps in [Get\nStarted](/docs/in-app-messaging/get-started) to\nensure you have an app with Firebase enabled and have added the latest Firebase In-App Messaging\nSDK.\n\nCreate a new campaign\n\nSet up your new campaign in the Firebase console's\n[Messaging page](https://console.firebase.google.com/project/_/messaging).\n\n- If you are a first time user, click **Create your first campaign**.\n- If not, click **New campaign**.\n\nStep 1: Style and content\n\nIn the console, use Firebase In-App Messaging message templates to incorporate different\nfeatures to serve different purposes with your in-app messages.\n\n[Explore use cases](/docs/in-app-messaging/explore-use-cases) to see\nexamples for stylizing the messages templates.\n\n\n| Message Template Type |||| Feature | Feature Description |\n| Feature | Feature Description |\n|---------|---------------------|------------|--------|-----------------------|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| Card | Modal | Image only | Banner |\n| lens | lens | lens | lens | Image | Provide an HTTPS Image URL. You can use [Firebase Hosting](/docs/hosting) to host your images. |\n| lens | lens | lens | lens | Action | Use weblinks or deep links to send your users to external pages or specific pages in your app. You can use [Firebase Dynamic Links](/docs/dynamic-links) to create and manage deep links. Templates **Modal** and **Image only** include an X button, allowing users to dismiss the message. |\n| lens | lens | | lens | Text/background color | Customize the message visuals by entering the Hex Color Code or using the color gradient to find the specific hue that matches your brand. |\n| lens | lens | | lens | Message title/body | Catch your user's attention with a relevant header and a concise description. Firebase automatically translates and scales your text to accommodate your users. |\n| lens | lens | | | Primary button | The default button action is set to dismiss the message. Provide a URL to redirect users as the action. |\n| lens | | | | Secondary button | The default button action is set to dismiss the message. Provide a URL to redirect users as the action. |\n\n\u003cbr /\u003e\n\n1. In Firebase console's **Compose campaign** window, customize your\n message to your liking with the features available to each template.\n\n2. On the right-hand side of the **Compose campaign** window, preview your message\n in landscape or portrait orientation for a phone or tablet device.\n\n The in-console preview provides a general idea of how your message appears\n on a mobile device. Actual message rendering varies depending on the device.\n [Test with a real device to see the exact rendering](/docs/in-app-messaging/get-started#send_a_test_message).\n3. If desired, define custom metadata for your campaign. This metadata will be available\n on the client side using SDK callbacks when a campaign is displayed to a user.\n For example, you might want to tag the campaign with a promo code that\n you can use on the client.\n\nStep 2: Target your users\n\n1. Enter a name for your campaign.\n\n This name is used for campaign reporting and is not part of the visible\n message.\n2. (Optional) Provide a campaign description.\n\n This description is used for campaign reporting and is not part of the visible\n message.\n3. Click on the **Select app** dropdown and identify which\n app you want to associate with this campaign.\n\n4. (Optional) Click the **and** button to further narrow down your\n target users.\n\n Use the **Select** dropdown to choose additional specifications.\n5. View the percentage of potential users that are eligible for this\n campaign.\n\n This number is estimated based on active users who contacted the service\n in the last 7 days. Eligible users only see this message if a trigger\n condition occurs.\n6. (Optional) If your app targets users in multiple languages, you will be\n prompted to localize the campaign in those languages. Use the dialog to\n either add your own translations or use Google Translate to localize the\n campaign easily.\n\nStep 3: Scheduling your message\n\n1. Describe a start date and time for your campaign.\n\n Your campaign can start when you publish the campaign or have a scheduled\n start.\n2. Describe an end date and time for your campaign.\n\n Your campaign can run indefinitely or have a scheduled endpoint.\n3. Click Event + to add at least one trigger event.\n\n - You can enter default events or [events logged through Firebase Analytics](/docs/analytics/android/events) to trigger your in-app message. These events can be user actions, system events, or errors.\n - Your in-app message is triggered when any of your events occur.\n4. Specify your per-device frequency limit. The limit allows you to\n control how often your users see your message.\n\n - By default, a campaign is not shown after it has been viewed by (that is, impressed on) the user once.\n - Or, you can set the frequency of messages in days.\n\nStep 4: Conversion events (optional)\n\nFirebase tracks the number of impressions that result in a completed conversion\nevent.\n\n1. In the **Compose campaign** window, use the **Select conversion event**\n dropdown to choose from:\n\n - The default conversion events.\n - Any [events you enabled as conversions](https://support.google.com/firebase/answer/6317522#enable).\n2. After you publish the campaign, go to the\n [Messaging page](https://console.firebase.google.com/project/_/messaging)\n and click on the campaign's name to see data related to the\n campaign's conversion history.\n\nPublishing your campaign\n\nAfter modifying your campaign, you can click **Save as draft** for the option to\nreturn and edit the campaign in draft status.\n\nOr, you can click **Publish** to release your message to targeted users on the\nscheduled date. You can edit your campaign after it has been published.\n\nOnce you stop a published campaign, you will not be able to publish it again.\nHowever, you may stop or edit a running campaign at any time. You can also\nduplicate an existing one to make slight variations and avoid creating a\ncompletely new campaigns.\n\nGet AI insights for messaging campaigns with Gemini in Firebase\n\nGemini in Firebase\nprovides messaging campaign summarization, insights,\nand guidance to improve your Firebase Cloud Messaging and In-App Messaging\ncampaign performance. By analyzing campaign data,\nGemini in Firebase can help you understand your campaigns' reach and impact\nand suggests strategies to improve user engagement and growth.\n\nAccess AI insights for messaging campaigns\n\nTo use messaging campaign AI insights, make sure that your project has the\nfollowing:\n\n- Gemini in Firebase is enabled for your project. Learn more at\n [Set up Gemini in Firebase](/docs/gemini-in-firebase/set-up-gemini).\n\n- Firebase Cloud Messaging or In-App Messaging is enabled in your Firebase\n project.\n\n- At least one campaign exists and appears in the Firebase console.\n\nAfter ensuring these requirements are met:\n\n1. Open [**Messaging**](//console.firebase.google.com/project/_/messaging) in the\n Firebase console to access campaign data.\n\n2. After your campaign data loads, click **Generate AI insights**.\n\n A summary and analysis of your messaging campaigns appears.\n\nPricing\n\nSee\n[Gemini in Firebase pricing](/docs/gemini-in-firebase#pricing) for more\ninformation."]]