Method: accounts.adUnits.list
จัดทุกอย่างให้เป็นระเบียบอยู่เสมอด้วยคอลเล็กชัน
บันทึกและจัดหมวดหมู่เนื้อหาตามค่ากำหนดของคุณ
แสดงรายการหน่วยโฆษณาภายใต้บัญชี AdMob ที่ระบุ
คำขอ HTTP
GET https://admob.googleapis.com/v1beta/{parent=accounts/*}/adUnits
URL ใช้ไวยากรณ์การแปลง gRPC
พารามิเตอร์เส้นทาง
พารามิเตอร์ |
parent |
string
ต้องระบุ ชื่อทรัพยากรของบัญชีที่จะแสดงหน่วยโฆษณา ตัวอย่างเช่น accounts/pub-9876543210987654
|
พารามิเตอร์การค้นหา
พารามิเตอร์ |
pageSize |
integer
จำนวนหน่วยโฆษณาสูงสุดที่จะแสดง หากไม่ระบุหรือ 0 ระบบจะแสดงผลหน่วยโฆษณาไม่เกิน 10,000 หน่วย ค่าสูงสุดคือ 20,000 ค่าที่มากกว่า 20,000 จะถูกเปลี่ยนเป็น 20,000
|
pageToken |
string
ค่าที่แสดงผลโดย ListAdUnitsResponse ที่แล้ว ระบุว่านี่เป็นการเรียกที่ต่อเนื่องมาจากการเรียก adUnits.list ก่อนหน้านี้ และระบบควรจะแสดงหน้าถัดไปของข้อมูล
|
เนื้อหาของคำขอ
เนื้อหาของคำขอต้องว่างเปล่า
เนื้อหาการตอบกลับ
การตอบกลับคำขอรายการหน่วยโฆษณา
หากทำสำเร็จ เนื้อหาการตอบกลับจะมีข้อมูลซึ่งมีโครงสร้างดังต่อไปนี้
การแสดง JSON |
{
"adUnits": [
{
object (AdUnit )
}
],
"nextPageToken": string
} |
ช่อง |
adUnits[] |
object (AdUnit )
หน่วยโฆษณาที่ได้สำหรับบัญชีที่ขอ
|
nextPageToken |
string
หากไม่ว่างเปล่า แสดงว่าอาจมีหน่วยโฆษณาเพิ่มเติมสำหรับคำขอดังกล่าว ค่านี้ควรส่งผ่านไปใน ListAdUnitsRequest ใหม่
|
ขอบเขตการให้สิทธิ์
ต้องใช้ขอบเขต OAuth รายการใดรายการหนึ่งต่อไปนี้
https://www.googleapis.com/auth/admob.monetization
https://www.googleapis.com/auth/admob.readonly
สำหรับข้อมูลเพิ่มเติม โปรดดูที่ภาพรวมของ OAuth 2.0
เนื้อหาของหน้าเว็บนี้ได้รับอนุญาตภายใต้ใบอนุญาตที่ต้องระบุที่มาของครีเอทีฟคอมมอนส์ 4.0 และตัวอย่างโค้ดได้รับอนุญาตภายใต้ใบอนุญาต Apache 2.0 เว้นแต่จะระบุไว้เป็นอย่างอื่น โปรดดูรายละเอียดที่นโยบายเว็บไซต์ Google Developers Java เป็นเครื่องหมายการค้าจดทะเบียนของ Oracle และ/หรือบริษัทในเครือ
อัปเดตล่าสุด 2024-08-29 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"]],["อัปเดตล่าสุด 2024-08-29 UTC"],[[["This page explains how to list ad units associated with a specific AdMob account using the `adUnits.list` method."],["The method requires the `parent` path parameter to specify the AdMob account and accepts optional `pageSize` and `pageToken` query parameters for pagination."],["Successful responses provide a list of `AdUnits` and a `nextPageToken` for retrieving additional pages if available."],["Authorization is required using either `https://www.googleapis.com/auth/admob.monetization` or `https://www.googleapis.com/auth/admob.readonly` OAuth scopes."]]],["This document details how to list ad units associated with a specific AdMob account. The process involves sending a `GET` request to `https://admob.googleapis.com/v1beta/{parent=accounts/*}/adUnits`, where `parent` is the account's resource name. Optional query parameters, `pageSize` (up to 20,000) and `pageToken` (for pagination), can be included. The request body must be empty. The response includes an array of `adUnits` and a `nextPageToken` for further results. Authorization requires specific OAuth scopes.\n"]]