/
playintegrity.v1.json
401 lines (401 loc) 路 15.8 KB
/
playintegrity.v1.json
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
{
"auth": {
"oauth2": {
"scopes": {
"https://www.googleapis.com/auth/playintegrity": {
"description": "Private Service: https://www.googleapis.com/auth/playintegrity"
}
}
}
},
"basePath": "",
"baseUrl": "https://playintegrity.googleapis.com/",
"batchPath": "batch",
"canonicalName": "Play Integrity",
"description": "Play Integrity",
"discoveryVersion": "v1",
"documentationLink": "https://developer.android.com/google/play/integrity",
"fullyEncodeReservedExpansion": true,
"icons": {
"x16": "http://www.google.com/images/icons/product/search-16.gif",
"x32": "http://www.google.com/images/icons/product/search-32.gif"
},
"id": "playintegrity:v1",
"kind": "discovery#restDescription",
"mtlsRootUrl": "https://playintegrity.mtls.googleapis.com/",
"name": "playintegrity",
"ownerDomain": "google.com",
"ownerName": "Google",
"parameters": {
"$.xgafv": {
"description": "V1 error format.",
"enum": [
"1",
"2"
],
"enumDescriptions": [
"v1 error format",
"v2 error format"
],
"location": "query",
"type": "string"
},
"access_token": {
"description": "OAuth access token.",
"location": "query",
"type": "string"
},
"alt": {
"default": "json",
"description": "Data format for response.",
"enum": [
"json",
"media",
"proto"
],
"enumDescriptions": [
"Responses with Content-Type of application/json",
"Media download with context-dependent Content-Type",
"Responses with Content-Type of application/x-protobuf"
],
"location": "query",
"type": "string"
},
"callback": {
"description": "JSONP",
"location": "query",
"type": "string"
},
"fields": {
"description": "Selector specifying which fields to include in a partial response.",
"location": "query",
"type": "string"
},
"key": {
"description": "API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token.",
"location": "query",
"type": "string"
},
"oauth_token": {
"description": "OAuth 2.0 token for the current user.",
"location": "query",
"type": "string"
},
"prettyPrint": {
"default": "true",
"description": "Returns response with indentations and line breaks.",
"location": "query",
"type": "boolean"
},
"quotaUser": {
"description": "Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.",
"location": "query",
"type": "string"
},
"uploadType": {
"description": "Legacy upload protocol for media (e.g. \"media\", \"multipart\").",
"location": "query",
"type": "string"
},
"upload_protocol": {
"description": "Upload protocol for media (e.g. \"raw\", \"multipart\").",
"location": "query",
"type": "string"
}
},
"protocol": "rest",
"resources": {
"v1": {
"methods": {
"decodeIntegrityToken": {
"description": "Decodes the integrity token and returns the token payload.",
"flatPath": "v1/{v1Id}:decodeIntegrityToken",
"httpMethod": "POST",
"id": "playintegrity.decodeIntegrityToken",
"parameterOrder": [
"packageName"
],
"parameters": {
"packageName": {
"description": " Package name of the app the attached integrity token belongs to.",
"location": "path",
"pattern": "^[^/]+$",
"required": true,
"type": "string"
}
},
"path": "v1/{+packageName}:decodeIntegrityToken",
"request": {
"$ref": "DecodeIntegrityTokenRequest"
},
"response": {
"$ref": "DecodeIntegrityTokenResponse"
},
"scopes": [
"https://www.googleapis.com/auth/playintegrity"
]
}
}
}
},
"revision": "20221001",
"rootUrl": "https://playintegrity.googleapis.com/",
"schemas": {
"AccountActivity": {
"description": "Contains a signal helping apps differentiating between likely genuine users and likely non-genuine traffic (such as accounts being used for fraud, accounts used by automated traffic, or accounts used in device farms) based on the presence and volume of Play store activity.",
"id": "AccountActivity",
"properties": {
"activityLevel": {
"description": "Required. Indicates the activity level of the account.",
"enum": [
"ACTIVITY_LEVEL_UNSPECIFIED",
"UNEVALUATED",
"UNUSUAL",
"UNKNOWN",
"TYPICAL_BASIC",
"TYPICAL_STRONG"
],
"enumDescriptions": [
"Activity level has not been set.",
"Account activity level is not evaluated because one of the prerequisite conditions is not met (e.g., device is not trusted, the user does not have Play app license)",
"Google Play store activity is unusual for at least one of the user accounts on the device. Google Play recommends checking that this is a real user.",
"Google Play does not have sufficient activity for the user account on the device. The account may be new, or it may lack activity on Google Play.",
"Google Play store activity is typical for the user account or accounts on the device.",
"Google Play store activity is typical for the user account or accounts on the device, with harder to replicate signals."
],
"type": "string"
}
},
"type": "object"
},
"AccountDetails": {
"description": "Contains the account information such as the licensing status for the user in the scope.",
"id": "AccountDetails",
"properties": {
"accountActivity": {
"$ref": "AccountActivity",
"description": "Details about the account activity for the user in the scope."
},
"accountRiskVerdict": {
"$ref": "AccountRiskVerdict",
"description": "Details about the account risk for the user in the scope. This feature is available only to selected developers."
},
"appLicensingVerdict": {
"description": "Required. Details about the licensing status of the user for the app in the scope.",
"enum": [
"UNKNOWN",
"LICENSED",
"UNLICENSED",
"UNEVALUATED"
],
"enumDescriptions": [
"Play does not have sufficient information to evaluate licensing details",
"The app and certificate match the versions distributed by Play.",
"The certificate or package name does not match Google Play records.",
"Licensing details were not evaluated since a necessary requirement was missed. For example DeviceIntegrity did not meet the minimum bar or the application was not a known Play version."
],
"type": "string"
}
},
"type": "object"
},
"AccountRiskVerdict": {
"description": "Contains information about account risk that indicates if the current user session seems low risk, unknown, or risky before you allow important actions to proceed.",
"id": "AccountRiskVerdict",
"properties": {
"risk": {
"description": "Required. Indicates the account risk level of the current user session.",
"enum": [
"RISK_UNSPECIFIED",
"UNEVALUATED",
"HIGHER",
"UNKNOWN",
"LOWER",
"LOWEST"
],
"enumDescriptions": [
"Risk has not been set.",
"The account risk is not evaluated, because the device is not trusted or the user does not have a Play app license.",
"Play thinks that at least one of the user accounts on the device has some unusual store engagement behavior that could be risky.",
"Play does not have sufficient information to assess the risk. The account may be new, or it may lack activity on the Play Store.",
"Play thinks the user could be genuine, since there is some store engagement. However, some signals to support the trust level are missing.",
"Play thinks the user is more likely to be genuine due to harder to replicate store engagement signals."
],
"type": "string"
},
"riskLevel": {
"description": "Required. Indicates the account risk level of the current user session.",
"enum": [
"RISK_LEVEL_UNSPECIFIED",
"RISK_LEVEL_UNEVALUATED",
"RISK_LEVEL_RISK",
"RISK_LEVEL_UNKNOWN",
"RISK_LEVEL_LOW_RISK",
"RISK_LEVEL_LOWEST_RISK"
],
"enumDescriptions": [
"Risk level has not been set.",
"The account risk is not evaluated, because the device is not trusted or the user does not have a Play app license.",
"Play thinks that at least one of the user accounts on the device has some unusual store engagement behavior that could be risky.",
"Play does not have sufficient information to assess the risk. The account may be new, or it may lack activity on the Play Store.",
"Play thinks the user could be genuine, since there is some store engagement. However, some signals to support the trust level are missing.",
"Play thinks the user is more likely to be genuine due to harder to replicate store engagement signals."
],
"type": "string"
}
},
"type": "object"
},
"AppIntegrity": {
"description": "Contains the application integrity information.",
"id": "AppIntegrity",
"properties": {
"appRecognitionVerdict": {
"description": "Required. Details about the app recognition verdict",
"enum": [
"UNKNOWN",
"PLAY_RECOGNIZED",
"UNRECOGNIZED_VERSION",
"UNEVALUATED"
],
"enumDescriptions": [
"Play does not have sufficient information to evaluate app integrity",
"The app and certificate match the versions distributed by Play.",
"The certificate or package name does not match Google Play records.",
"Application integrity was not evaluated since a necessary requirement was missed. For example DeviceIntegrity did not meet the minimum bar."
],
"type": "string"
},
"certificateSha256Digest": {
"description": "The SHA256 hash of the requesting app's signing certificates (base64 web-safe encoded). Set iff app_recognition_verdict != UNEVALUATED.",
"items": {
"type": "string"
},
"type": "array"
},
"packageName": {
"description": "Package name of the application under attestation. Set iff app_recognition_verdict != UNEVALUATED.",
"type": "string"
},
"versionCode": {
"description": "Version code of the application. Set iff app_recognition_verdict != UNEVALUATED.",
"format": "int64",
"type": "string"
}
},
"type": "object"
},
"DecodeIntegrityTokenRequest": {
"description": "Request to decode the integrity token.",
"id": "DecodeIntegrityTokenRequest",
"properties": {
"integrityToken": {
"description": "Encoded integrity token.",
"type": "string"
}
},
"type": "object"
},
"DecodeIntegrityTokenResponse": {
"description": "Response containing the decoded integrity payload.",
"id": "DecodeIntegrityTokenResponse",
"properties": {
"tokenPayloadExternal": {
"$ref": "TokenPayloadExternal",
"description": "Plain token payload generated from the decoded integrity token."
}
},
"type": "object"
},
"DeviceIntegrity": {
"description": "Contains the device attestation information.",
"id": "DeviceIntegrity",
"properties": {
"deviceRecognitionVerdict": {
"description": "Details about the integrity of the device the app is running on",
"items": {
"enum": [
"UNKNOWN",
"MEETS_BASIC_INTEGRITY",
"MEETS_DEVICE_INTEGRITY",
"MEETS_STRONG_INTEGRITY",
"MEETS_VIRTUAL_INTEGRITY"
],
"enumDescriptions": [
"Play does not have sufficient information to evaluate device integrity",
"App is running on a device that passes basic system integrity checks, but may not meet Android platform compatibility requirements and may not be approved to run Google Play services.",
"App is running on GMS Android device with Google Play services.",
"App is running on GMS Android device with Google Play services and has a strong guarantee of system integrity such as a hardware-backed keystore.",
"App is running on an Android emulator with Google Play services which meets core Android compatibility requirements."
],
"type": "string"
},
"type": "array"
}
},
"type": "object"
},
"RequestDetails": {
"description": "Contains the integrity request information.",
"id": "RequestDetails",
"properties": {
"nonce": {
"description": "Required. Nonce that was provided in the request (which is base64 web-safe no-wrap).",
"type": "string"
},
"requestPackageName": {
"description": "Required. Application package name this attestation was requested for. Note: This field makes no guarantees or promises on the caller integrity. For details on application integrity, check application_integrity.",
"type": "string"
},
"timestampMillis": {
"description": "Required. Timestamp, in milliseconds, of the integrity application request.",
"format": "int64",
"type": "string"
}
},
"type": "object"
},
"TestingDetails": {
"description": "Contains additional information generated for testing responses.",
"id": "TestingDetails",
"properties": {
"isTestingResponse": {
"description": "Required. Indicates that the information contained in this payload is a testing response that is statically overridden for a tester.",
"type": "boolean"
}
},
"type": "object"
},
"TokenPayloadExternal": {
"description": "Contains basic app information and integrity signals like device attestation and licensing details.",
"id": "TokenPayloadExternal",
"properties": {
"accountDetails": {
"$ref": "AccountDetails",
"description": "Required. Details about the Play Store account."
},
"appIntegrity": {
"$ref": "AppIntegrity",
"description": "Required. Details about the application integrity."
},
"deviceIntegrity": {
"$ref": "DeviceIntegrity",
"description": "Required. Details about the device integrity."
},
"requestDetails": {
"$ref": "RequestDetails",
"description": "Required. Details about the integrity request."
},
"testingDetails": {
"$ref": "TestingDetails",
"description": "Indicates that this payload is generated for testing purposes and contains any additional data that is linked with testing status."
}
},
"type": "object"
}
},
"servicePath": "",
"title": "Google Play Integrity API",
"version": "v1",
"version_module": true
}