نام مستعار مشترک
با مجموعهها، منظم بمانید
ذخیره و طبقهبندی محتوا براساس اولویتهای شما.
هنگام کار با Google Ads API، مکانهای متعددی وجود دارد که از آدرسهای ایمیل برای مدیریت تماس و دسترسی استفاده میشود که مهمترین آنها موارد زیر است:
- ایمیل تماس Google Ads API : این ایمیلی است که به عنوان مخاطب در مرکز API رابط کاربری Google Ads فهرست شده است.
- ایمیل حساب Google Cloud Console : این ایمیلی است که دسترسی سرپرست به حساب Google Cloud Console مورد استفاده برای برنامه OAuth 2.0 شما دارد.
- ایمیل(های) حساب مدیر Google Ads : اینها ایمیل هایی هستند که دارای مجوزهای سرپرست در حساب(های) مدیر Google Ads هستند که از طریق Google Ads API به آنها دسترسی دارید. هنگامی که یک توکن بهروزرسانی برای برنامه خود ایجاد میکنید، معمولاً برنامه Google Ads API خود را با یکی از این ایمیلها احراز هویت میکنید.
ما اکیداً توصیه میکنیم از نام مستعار تیم مشترک استفاده کنید تا وقتی اعضای تیم تغییر تیم میدهند یا شرکت را ترک میکنند، دسترسی به این حسابها را از دست ندهید. بقیه این راهنما در مورد هر یک از ایمیلهایی که قبلاً فهرست شدهاند و اینکه چگونه میتوانید آن را برای استفاده از نام مستعار تیم مشترک به جای آدرس ایمیل یک کاربر بهروزرسانی کنید، توضیح میدهد.
ایمیل تماس Google Ads API آدرس ایمیلی است که هنگام ثبت نام برای Google Ads API ارائه می کنید. شما باید از دسترسی به این نام مستعار اطمینان حاصل کنید و ایمیل های ارسال شده به این آدرس را به طور مرتب نظارت کنید. Google از این آدرس ایمیل برای تماس با تیم شما در طول بررسی های API، درخواست های ممیزی یا شرایط اضطراری تولید که نیاز به توجه فوری دارند، استفاده می کند. از نام مستعار تیم مشترک به عنوان ایمیل تماس استفاده کنید تا مطمئن شوید که کل تیم این اعلانها را دریافت میکند.
این مراحل را برای بهروزرسانی ایمیل تماس API دنبال کنید:
وارد حساب مدیر تبلیغات Google خود شوید.
روی Admin در سمت چپ پایین صفحه کلیک کنید.
در قسمت تنظیمات حساب مدیر ، روی مرکز API کلیک کنید.
در زیر جزئیات برنامهنویس ، به ایمیل تماس API توجه کنید. روی فلش رو به پایین کلیک کنید و ایمیل را ویرایش کنید. روی ذخیره کلیک کنید.
حساب Google Cloud Console
پروژه Google API Console حاوی اطلاعات کاربری OAuth برنامه شما است و دسترسی به API Google Ads را کنترل می کند. با قرار دادن نام مستعار مشترک به عنوان مالک حساب، دسترسی به این حساب را تضمین کنید.
برای بهروزرسانی مالک پروژه Google API Console این مراحل را دنبال کنید:
- وارد Google API Console شوید.
- پروژه خود را از منوی کشویی در گوشه سمت چپ بالای صفحه انتخاب کنید.
- از منوی سمت چپ به IAM و admin > IAM بروید.
- روی دکمه Grant Access کلیک کنید.
- آدرس ایمیل مشترک را در قسمت Add principals وارد کنید.
- نقش مالک را تعیین کنید.
- روی دکمه Save کلیک کنید. برای کسب اطلاعات بیشتر در مورد اعطای و لغو دسترسی به اسناد Cloud مراجعه کنید.
حساب مدیر Google Ads
یک روش متداول برای مدیریت حسابها با استفاده از Google Ads API این است که همه حسابهای خود را تحت یک حساب مدیر مشترک پیوند دهید، و با استفاده از بالاترین اعتبار حسابهای مدیر، با همه حسابها تماسهای API برقرار کنید. در این پیکربندی:
- توسعهدهنده با استفاده از اعتبار کاربری که به حساب مدیر Google Ads دسترسی دارد، یک نشانه بهروزرسانی صادر میکند.
- برنامهنویس هدر
login_customer_id
را بهعنوان شناسه مشتری حساب مدیر Google Ads و سرصفحه customer_id
را بهعنوان شناسه مشتری حسابی که تماسهای API با آن برقرار میشود، تنظیم میکند.
یکی از خطرات احتمالی این راهاندازی این است که اگر کاربر مجاز دسترسی به حساب مدیر Google Ads را از دست بدهد، رمز تازهسازی دیگر معتبر نیست و همه تماسهای API با شکست مواجه میشوند. برای جلوگیری از این سناریو، میتوانید از یک نام مستعار ایمیل مشترک برای مدیریت این حساب مدیر Google Ads با سطوح دسترسی مناسب دعوت کنید. از این نام مستعار ایمیل مشترک برای صدور نشانه رفرش برای برقراری تماس های API استفاده کنید.
جز در مواردی که غیر از این ذکر شده باشد،محتوای این صفحه تحت مجوز Creative Commons Attribution 4.0 License است. نمونه کدها نیز دارای مجوز Apache 2.0 License است. برای اطلاع از جزئیات، به خطمشیهای سایت Google Developers مراجعه کنید. جاوا علامت تجاری ثبتشده Oracle و/یا شرکتهای وابسته به آن است.
تاریخ آخرین بهروزرسانی 2025-08-29 بهوقت ساعت هماهنگ جهانی.
[null,null,["تاریخ آخرین بهروزرسانی 2025-08-29 بهوقت ساعت هماهنگ جهانی."],[[["\u003cp\u003eWhen working with the Google Ads API, ensure continuous access by using shared team aliases for contact, access management, and authentication purposes instead of individual user emails.\u003c/p\u003e\n"],["\u003cp\u003eThe Google Ads API contact email is used for crucial communications, update it to a shared alias to keep your team informed about API reviews, audit requests, and production emergencies.\u003c/p\u003e\n"],["\u003cp\u003eSafeguard your Google Cloud Console account by granting ownership to a shared team alias, ensuring access to your application's OAuth credentials and control over API access.\u003c/p\u003e\n"],["\u003cp\u003eFor managing multiple Google Ads accounts, link them under a manager account and grant access to a shared alias for refresh token generation and uninterrupted API functionality.\u003c/p\u003e\n"],["\u003cp\u003eRegularly monitor and update these email addresses and access levels to maintain seamless API operations and avoid disruptions caused by personnel changes.\u003c/p\u003e\n"]]],[],null,["# Shared aliases\n\nWhen working with the Google Ads API, there are multiple places where email addresses\nare used for contact and access management, the most important of which are the\nfollowing:\n\n- **Google Ads API contact email**: This is the email listed as the contact in the API Center of the Google Ads UI.\n- **Google Cloud Console account email**: This is the email that has administrator access to the Google Cloud Console account used for your OAuth 2.0 application.\n- **Google Ads manager account email(s)**: These are the emails that have administrator permissions on the manager Google Ads account(s) you access through the Google Ads API. When you generate a refresh token for your application, you usually authenticate your Google Ads API application with one of these emails.\n\nWe strongly recommend using shared team aliases so that you don't lose access to\nthese accounts when individual team members switch teams or leave the company.\nThe rest of this guide elaborates on each of the emails listed earlier and how\nyou can update it to use a shared team alias instead of an individual user's\nemail address.\n\nGoogle Ads API contact email\n----------------------------\n\nThe Google Ads API contact email is an email address you provide when signing up for\nthe Google Ads API. You should ensure access to this alias and monitor emails sent to\nthis address regularly. Google uses this email address to contact your team\nduring API reviews, audit requests, or production emergencies that require\nimmediate attention. Use a shared team alias as the contact email to ensure that\nthe whole team receives these notifications.\n\nFollow these steps to update the API contact email:\n\n1. Sign in to your Google Ads [Manager\n Account](//ads.google.com/home/tools/manager-accounts/).\n\n2. Click **Admin** at the bottom left of the screen.\n\n3. Under **Manager account settings** , click **API center**.\n\n4. Under **Developer details** , note the API contact email. Click the down arrow\n and edit the email. Click **Save**.\n\nGoogle Cloud Console account\n----------------------------\n\nThe **Google API Console** project contains your application's OAuth credentials\nand controls access to the Google Ads API. Ensure access to this account by making a\nshared alias the account owner.\n\nFollow these steps to update the Google API Console project's owner:\n\n- Sign in to [**Google API Console**](//console.developers.google.com).\n- Select your project from the drop-down menu on the top-left corner of the page.\n- Navigate to **IAM and admin \\\u003e IAM** from the left menu.\n- Click the **Grant Access** button.\n- Enter the shared email address under the **Add principals** section.\n- Assign the **Owner** role.\n- Click the **Save** button. Refer to the Cloud documentation to learn more about [granting and revoking access](//cloud.google.com/iam/docs/granting-changing-revoking-access#single-role).\n\nGoogle Ads manager account\n--------------------------\n\nA common method of managing accounts using the Google Ads API is to link all your\naccounts under a common manager account, and make API calls to all the accounts\nusing the top-most manager account's credentials. In this configuration:\n\n- The developer issues a refresh token using the credentials of a user who has access to the Google Ads manager account.\n- The developer sets the [`login_customer_id`](/google-ads/api/docs/get-started/select-account#user_access_login_customer_id_and_customer_id) header as the customer ID of the Google Ads manager account, and the `customer_id` header as the customer ID of the account to which API calls are made.\n\nOne potential risk of this setup is that if the authorized user loses access to\nthe Google Ads manager account, the refresh token is no longer valid and all API\ncalls fail. To avoid this scenario, you can invite a shared email alias to\nmanage this Google Ads manager account with the [appropriate access levels](//support.google.com/google-ads/answer/9978556).\nUse this shared email alias to issue the refresh token for making API calls."]]