Method: achievements.increment
تنظيم صفحاتك في مجموعات
يمكنك حفظ المحتوى وتصنيفه حسب إعداداتك المفضّلة.
لزيادة خطوات الإنجاز باستخدام رقم التعريف المحدّد للمشغّل الذي تمت مصادقته حاليًا.
طلب HTTP
POST https://games.googleapis.com/games/v1/achievements/{achievementId}/increment
مَعلمات المسار
المعلمات |
achievementId |
string
رقم تعريف الإنجاز المستخدَم في هذه الطريقة.
|
معامِلات طلب البحث
المعلمات |
requestId |
string (int64 format)
معرّف رقمي يتم إنشاؤه عشوائيًا لكل طلب يحدّده المتصل. يتم استخدام هذا الرقم في الخادم لضمان التعامل مع الطلب بشكل صحيح عبر مرات إعادة المحاولة.
|
stepsToIncrement |
integer
مطلوب. عدد الخطوات المطلوب زيادتها.
|
نص الطلب
يجب أن يكون نص الطلب فارغًا.
نص الاستجابة
استجابة لزيادة الإنجاز
إذا كانت الاستجابة ناجحة، سيحتوي نص الاستجابة على بيانات بالبنية التالية:
تمثيل JSON |
{
"kind": string,
"currentSteps": integer,
"newlyUnlocked": boolean
} |
الحقول |
kind |
string
تُحدِّد نوع هذا المورد بشكلٍ فريد. وتكون القيمة دائمًا هي السلسلة الثابتة games#achievementIncrementResponse .
|
currentSteps |
integer
الخطوات الحالية المسجَّلة لهذا الإنجاز التدريجي
|
newlyUnlocked |
boolean
ما إذا كانت الخطوات الحالية للإنجاز قد وصلت إلى عدد الخطوات المطلوبة لفتح القفل.
|
نطاقات الأذونات
يتطلب هذا الإعداد أحد نطاقات OAuth التالية:
https://www.googleapis.com/auth/games
https://www.googleapis.com/auth/games_lite
لمزيد من المعلومات، يُرجى الاطِّلاع على نظرة عامة على OAuth 2.0.
يخضع كل من المحتوى وعيّنات التعليمات البرمجية في هذه الصفحة للتراخيص الموضحّة في ترخيص استخدام المحتوى. إنّ Java وOpenJDK هما علامتان تجاريتان مسجَّلتان لشركة Oracle و/أو الشركات التابعة لها.
تاريخ التعديل الأخير: 2025-07-27 (حسب التوقيت العالمي المتفَّق عليه)
[null,null,["تاريخ التعديل الأخير: 2025-07-27 (حسب التوقيت العالمي المتفَّق عليه)"],[],[],null,["# Method: achievements.increment\n\n- [HTTP request](#body.HTTP_TEMPLATE)\n- [Path parameters](#body.PATH_PARAMETERS)\n- [Query parameters](#body.QUERY_PARAMETERS)\n- [Request body](#body.request_body)\n- [Response body](#body.response_body)\n - [JSON representation](#body.IncrementAchievementResponse.SCHEMA_REPRESENTATION)\n- [Authorization scopes](#body.aspect)\n- [Try it!](#try-it)\n\nIncrements the steps of the achievement with the given ID for the currently authenticated player.\n\n### HTTP request\n\n`POST https://games.googleapis.com/games/v1/achievements/{achievementId}/increment`\n\n### Path parameters\n\n| Parameters ||\n|-----------------|---------------------------------------------------------|\n| `achievementId` | `string` The ID of the achievement used by this method. |\n\n### Query parameters\n\n| Parameters ||\n|--------------------|-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| `requestId` | `string (`[int64](https://developers.google.com/discovery/v1/type-format)` format)` A randomly generated numeric ID for each request specified by the caller. This number is used at the server to ensure that the request is handled correctly across retries. |\n| `stepsToIncrement` | `integer` Required. The number of steps to increment. |\n\n### Request body\n\nThe request body must be empty.\n\n### Response body\n\nAn achievement increment response\n\nIf successful, the response body contains data with the following structure:\n\n| JSON representation |\n|-------------------------------------------------------------------------------|\n| ``` { \"kind\": string, \"currentSteps\": integer, \"newlyUnlocked\": boolean } ``` |\n\n| Fields ||\n|-----------------|--------------------------------------------------------------------------------------------------------------------------------|\n| `kind` | `string` Uniquely identifies the type of this resource. Value is always the fixed string `games#achievementIncrementResponse`. |\n| `currentSteps` | `integer` The current steps recorded for this incremental achievement. |\n| `newlyUnlocked` | `boolean` Whether the current steps for the achievement has reached the number of steps required to unlock. |\n\n### Authorization scopes\n\nRequires one of the following OAuth scopes:\n\n- `https://www.googleapis.com/auth/games`\n- `\n https://www.googleapis.com/auth/games_lite`\n\nFor more information, see the [OAuth 2.0 Overview](https://developers.google.com/identity/protocols/OAuth2)."]]