אימות החיבור של החשבון ל-Merchant API
אם יש לכם חשבון מוכר קיים, תוכלו להשתמש בכלי הניתוחים של ה-API במסמכי העזרה כדי לוודא שהחשבון שלכם מוכן לשימוש עם Merchant API.
- כדי למצוא את שם המשאב של החשבון, צריך לשרשור את
accounts/
ואת merchantId
. אפשר למצוא את merchantId
בחלק העליון של Google Merchant Center.
- ב-API Explorer, בשיטה
accounts.products.list
:
- מזינים את שם המשאב של החשבון בשדה
parent
.
- בקטע Credentials בוחרים באפשרות Google OAuth 2.0 ובאפשרות API key.
- לוחצים על Execute.
- אם מתבקשים, נכנסים לחשבון Google המשויך לחשבון Google
חשבון Merchant Center.
אם חשבון המוכר מוגדר בצורה תקינה, הבקשה תתבצע בהצלחה ותוחזר קוד תגובה מסוג HTTP 200
. אם יצרתם חשבון חדש, השיטה accounts.products.list
לא תחזיר מוצרים.
לאחר מכן, משתמשים בספריית לקוח כדי לבקש גישה לחשבונות של מוכרים אחרים, או משתמשים בחשבון שירות כדי לאשר גישה ל-API בחשבון שלכם.
אלא אם צוין אחרת, התוכן של דף זה הוא ברישיון Creative Commons Attribution 4.0 ודוגמאות הקוד הן ברישיון Apache 2.0. לפרטים, ניתן לעיין במדיניות האתר Google Developers. Java הוא סימן מסחרי רשום של חברת Oracle ו/או של השותפים העצמאיים שלה.
עדכון אחרון: 2024-10-23 (שעון UTC).
[null,null,["עדכון אחרון: 2024-10-23 (שעון UTC)."],[[["Existing merchant account holders can use the API explorer to verify their account's compatibility with the Merchant API."],["Account verification involves locating your `merchantId`, constructing the resource name, and executing the `accounts.products.list` method within the API Explorer using your credentials."],["Successful verification is indicated by an HTTP response code `200`, although new accounts may not return any product data."],["After verification, users can proceed to utilize client libraries for accessing other merchant accounts or employ service accounts for authorizing API access to their own account."]]],["To verify a merchant account for API use, locate your `merchantId` in Google Merchant Center and construct the account's resource name. In the API Explorer, use the `accounts.products.list` method, input the resource name in the `parent` field, and select Google OAuth 2.0 and API key credentials. Executing the request should return an HTTP 200 code, confirming successful setup. For new accounts, the product list will be empty. Further access can be configured via client libraries or service accounts.\n"]]