ให้สิทธิ์คำขอ
จัดทุกอย่างให้เป็นระเบียบอยู่เสมอด้วยคอลเล็กชัน
บันทึกและจัดหมวดหมู่เนื้อหาตามค่ากำหนดของคุณ
เมื่อแอปขอข้อมูลส่วนตัว คำขอจะต้องได้รับสิทธิ์จากการตรวจสอบสิทธิ์
ผู้ใช้ที่มีสิทธิ์เข้าถึงข้อมูลดังกล่าว
ทุกคำขอที่แอปส่งไปยัง Bid Manager API จะต้องมีโทเค็นการให้สิทธิ์ โทเค็น
ระบุแอปของคุณให้ Google ทราบด้วย
เกี่ยวกับโปรโตคอลการให้สิทธิ์
แอปของคุณต้องใช้ OAuth 2.0 เพื่อให้สิทธิ์คำขอ
ระบบไม่รองรับโปรโตคอลการให้สิทธิ์อื่นๆ หากแอปของคุณใช้ Google Sign-In ระบบจะจัดการการให้สิทธิ์ในบางแง่มุมสำหรับ
ให้ทำงานแทนคุณ
การให้สิทธิ์คำขอด้วย OAuth 2.0
คำขอทั้งหมดที่ส่งไปยัง Bid Manager API จะต้องได้รับอนุญาตจากผู้ใช้ที่ตรวจสอบสิทธิ์แล้ว
รายละเอียดของกระบวนการให้สิทธิ์ หรือ "ขั้นตอน" สำหรับ OAuth 2.0 จะแตกต่างกันไป
เกี่ยวกับประเภทแอปที่คุณกำลังเขียน กระบวนการทั่วไปต่อไปนี้มีผลกับแอปทุกประเภท
- เมื่อสร้างแอป คุณจะลงทะเบียนแอปโดยใช้คอนโซล Google API จากนั้น Google จะให้ข้อมูลที่คุณต้องการ
เช่น รหัสไคลเอ็นต์และรหัสลับไคลเอ็นต์
- ส่งการยืนยัน OAuth
ตรวจสอบแอปของคุณเพื่อเข้าถึงขอบเขต Bid Manager API
- เปิดใช้งาน Bid Manager API ในคอนโซล Google API (หาก API ไม่อยู่ในรายการ
คอนโซล API แล้วข้ามขั้นตอนนี้)
- เมื่อแอปต้องการเข้าถึงข้อมูลผู้ใช้ แอปจะขอขอบเขตที่เจาะจงเกี่ยวกับ
สิทธิ์การเข้าถึง
- Google จะแสดงหน้าจอขอความยินยอมแก่ผู้ใช้ เพื่อขอให้ผู้ใช้ให้สิทธิ์แอปของคุณ
เข้าถึงข้อมูลบางอย่างได้
- หากผู้ใช้อนุมัติ Google จะให้โทเค็นเพื่อการเข้าถึงที่มีอายุชั่วคราวแก่แอปของคุณ
- แอปของคุณขอข้อมูลผู้ใช้โดยแนบโทเค็นเพื่อการเข้าถึงไปกับคำขอ
- หาก Google ตัดสินว่าคำขอและโทเค็นของคุณถูกต้อง ระบบจะแสดงข้อมูลที่ขอ
บางกระบวนการจะมีขั้นตอนเพิ่มเติม เช่น การใช้โทเค็นการรีเฟรชเพื่อขอสิทธิ์การเข้าถึงใหม่
โทเค็น ดูข้อมูลอย่างละเอียดเกี่ยวกับกระบวนการสำหรับแอปประเภทต่างๆ ได้ที่เอกสารประกอบเกี่ยวกับ OAuth 2.0 ของ Google
ขอบเขต OAuth
ข้อมูลขอบเขต OAuth 2.0 สำหรับ Bid Manager API มีดังนี้
ขอบเขต |
ความหมาย |
https://www.googleapis.com/auth/doubleclickbidmanager |
สิทธิ์การอ่าน/เขียน |
ในการขอสิทธิ์เข้าถึงโดยใช้ OAuth 2.0 แอปของคุณต้องมีข้อมูลขอบเขต รวมถึง
ที่ Google จัดหาให้เมื่อคุณลงทะเบียนแอป (เช่น รหัสไคลเอ็นต์และ
รหัสลับไคลเอ็นต์)
เนื้อหาของหน้าเว็บนี้ได้รับอนุญาตภายใต้ใบอนุญาตที่ต้องระบุที่มาของครีเอทีฟคอมมอนส์ 4.0 และตัวอย่างโค้ดได้รับอนุญาตภายใต้ใบอนุญาต Apache 2.0 เว้นแต่จะระบุไว้เป็นอย่างอื่น โปรดดูรายละเอียดที่นโยบายเว็บไซต์ Google Developers Java เป็นเครื่องหมายการค้าจดทะเบียนของ Oracle และ/หรือบริษัทในเครือ
อัปเดตล่าสุด 2025-08-31 UTC
[null,null,["อัปเดตล่าสุด 2025-08-31 UTC"],[[["\u003cp\u003eApplications need authorization from an authenticated user to access private data through the Bid Manager API.\u003c/p\u003e\n"],["\u003cp\u003eThe Bid Manager API exclusively supports OAuth 2.0 for authorization and requires apps to pass an OAuth verification review.\u003c/p\u003e\n"],["\u003cp\u003eApps must be registered using the Google API Console, undergo an OAuth verification review, and request specific scopes for data access.\u003c/p\u003e\n"],["\u003cp\u003eUpon user consent, Google provides a short-lived access token which the app uses to make authorized requests for user data.\u003c/p\u003e\n"]]],["Apps requesting private data through the Bid Manager API must be authorized by an authenticated user via OAuth 2.0. The process involves registering the app with Google, submitting an OAuth verification request, and activating the API. The app then requests a specific access scope, prompting a user consent screen. Upon approval, Google issues a short-lived access token. This token is included in data requests, allowing Google to validate the request and return data. The available scope is for read/write access.\n"],null,["# Authorize Requests\n\nWhen your app requests private data, the request must be authorized by an authenticated\nuser who has access to that data.\n| **Note:** If your app accesses the Bid Manager API, it must pass the [OAuth verification review](//support.google.com/cloud/answer/7454865#verification). If you see **unverified app** on the screen when testing your app, you must submit a verification request to remove it. Learn more about [unverified apps](//support.google.com/cloud/answer/7454865) or get answers to [frequently asked questions about app\n| verification](//support.google.com/cloud/answer/9110914).\n\nEvery request your app sends to the Bid Manager API must include an authorization token. The token\nalso identifies your app to Google.\n\nAbout authorization protocols\n-----------------------------\n\nYour app must use [OAuth 2.0](/identity/protocols/OAuth2) to authorize requests.\nNo other authorization protocols are supported. If your app uses [Google Sign-In](/identity#google-sign-in), some aspects of authorization are handled for\nyou.\n\nAuthorizing requests with OAuth 2.0\n-----------------------------------\n\nAll requests to the Bid Manager API must be authorized by an authenticated user.\n\nThe details of the authorization process, or \"flow,\" for OAuth 2.0 vary somewhat depending\non what kind of app you're writing. The following general process applies to all app types:\n\n1. When you create your app, you register it using the [Google API Console](https://console.cloud.google.com/). Google then provides information you'll need later, such as a client ID and a client secret.\n2. Submit an [OAuth verification\n review](//support.google.com/cloud/answer/7454865#verification) request for your app in order to access the Bid Manager API scope.\n3. Activate the Bid Manager API in the Google API Console. (If the API isn't listed in the API Console, then skip this step.)\n4. When your app needs access to user data, it asks Google for a particular **scope** of access.\n5. Google displays a **consent screen** to the user, asking them to authorize your app for access to some of their data.\n6. If the user approves, then Google gives your app a short-lived **access token**.\n7. Your app requests user data, attaching the access token to the request.\n8. If Google determines that your request and the token are valid, it returns the requested data.\n\nSome flows include additional steps, such as using **refresh tokens** to acquire new access\ntokens. For detailed information about flows for various types of apps, see Google's [OAuth 2.0 documentation](/identity/protocols/OAuth2).\n\nOAuth scope\n-----------\n\nHere's the OAuth 2.0 scope information for the Bid Manager API:\n\n| Scope | Meaning |\n|---------------------------------------------------------|--------------------|\n| `https://www.googleapis.com/auth/doubleclickbidmanager` | Read/write access. |\n\nTo request access using OAuth 2.0, your app needs the scope information, as well as\ninformation that Google supplies when you register your app (such as the client ID and the\nclient secret)."]]