Method: edits.apks.addexternallyhosted
संग्रह की मदद से व्यवस्थित रहें
अपनी प्राथमिकताओं के आधार पर, कॉन्टेंट को सेव करें और कैटगरी में बांटें.
APK को Google Play पर अपलोड किए बिना ही नया APK बनाता है. इसके बजाय, APK को किसी खास यूआरएल पर होस्ट करता है. यह फ़ंक्शन 'कारोबार के लिए Play' का इस्तेमाल करने वाले सिर्फ़ उन संगठनों के लिए उपलब्ध है जिनका ऐप्लिकेशन, संगठनों में डिस्ट्रिब्यूशन पर पाबंदी लगाने के लिए कॉन्फ़िगर किया गया है.
एचटीटीपी अनुरोध
POST https://androidpublisher.googleapis.com/androidpublisher/v3/applications/{packageName}/edits/{editId}/apks/externallyHosted
यह यूआरएल gRPC ट्रांसकोडिंग सिंटैक्स का इस्तेमाल करता है.
पाथ पैरामीटर
पैरामीटर |
packageName |
string
ऐप्लिकेशन का पैकेज नाम.
|
editId |
string
बदलाव का आइडेंटिफ़ायर.
|
अनुरोध का मुख्य भाग
अनुरोध के मुख्य हिस्से में, यहां दिए गए स्ट्रक्चर का डेटा शामिल होता है:
फ़ील्ड |
externallyHostedApk |
object (ExternallyHostedApk )
बाहरी रूप से होस्ट किए गए APK की परिभाषा और वह कहां मौजूद है.
|
जवाब का मुख्य भाग
बाहरी रूप से होस्ट किया गया नया APK बनाने का रिस्पॉन्स.
अगर एपीआई सही से जुड़ जाता है, ताे जवाब के मुख्य भाग में नीचे दिए गए स्ट्रक्चर शामिल होता है.
फ़ील्ड |
externallyHostedApk |
object (ExternallyHostedApk )
बाहरी रूप से होस्ट किए गए APK की परिभाषा और वह कहां मौजूद है.
|
अनुमति के दायरे
नीचे दिए गए OAuth के लिंक की ज़रूरत हाेती है:
https://www.googleapis.com/auth/androidpublisher
ExternallyHostedApk
इस ऐप्लिकेशन के लिए उपलब्ध ऐसे APK के बारे में बताता है जिसे बाहरी तौर पर होस्ट किया गया हो और जिसे Google Play पर अपलोड नहीं किया गया हो. यह फ़ंक्शन 'कारोबार के लिए Play' का इस्तेमाल करने वाले सिर्फ़ उन संगठनों के लिए उपलब्ध है जिनका ऐप्लिकेशन, संगठनों में डिस्ट्रिब्यूशन पर पाबंदी लगाने के लिए कॉन्फ़िगर किया गया है.
JSON के काेड में दिखाना |
{
"packageName": string,
"applicationLabel": string,
"versionCode": integer,
"versionName": string,
"fileSize": string,
"fileSha1Base64": string,
"fileSha256Base64": string,
"iconBase64": string,
"minimumSdk": integer,
"certificateBase64s": [
string
],
"externallyHostedUrl": string,
"maximumSdk": integer,
"nativeCodes": [
string
],
"usesFeatures": [
string
],
"usesPermissions": [
{
object (UsesPermission )
}
]
} |
फ़ील्ड |
packageName |
string
पैकेज का नाम.
|
applicationLabel |
string
ऐप्लिकेशन लेबल.
|
versionCode |
integer
इस APK का वर्शन कोड.
|
versionName |
string
इस APK के वर्शन का नाम.
|
fileSize |
string (int64 format)
इस APK का फ़ाइल साइज़, बाइट में.
|
fileSha1Base64 |
string
इस APK का sha1 चेकसम, जिसे base64 कोड में बदले गए बाइट कलेक्शन के रूप में दिखाया गया है.
|
fileSha256Base64 |
string
इस APK का sha256 चेकसम, जिसे base64 कोड में बदले गए बाइट कलेक्शन के रूप में दिखाया गया है.
|
iconBase64 |
string
APK से मिली आइकॉन इमेज, जिसे base64 कोड में बदले गए बाइट अरे के तौर पर दिखाया गया है.
|
minimumSdk |
integer
SDK टूल का कम से कम लेवल, जिसे इस APK ने टारगेट किया है.
|
certificateBase64s[] |
string
इस APK पर हस्ताक्षर करने के लिए इस्तेमाल किया जाने वाला सर्टिफ़िकेट या सर्टिफ़िकेट-चेन का इस्तेमाल करने पर सर्टिफ़िकेट का कलेक्शन. इसे base64 कोड में बदले गए बाइट कलेक्शन के रूप में दिखाया जाता है.
|
externallyHostedUrl |
string
वह यूआरएल जिस पर APK होस्ट किया गया है. यह एचटीटीपीएस यूआरएल होना चाहिए.
|
maximumSdk |
integer
इस APK के साथ ज़्यादा से ज़्यादा कितने SDK टूल काम करते हैं (ज़रूरी नहीं).
|
nativeCodes[] |
string
इस APK के साथ काम करने वाले स्थानीय कोड एनवायरमेंट (ज़रूरी नहीं).
|
usesFeatures[] |
string
इस APK के लिए ज़रूरी सुविधाएं (ज़रूरी नहीं).
|
usesPermissions[] |
object (UsesPermission )
इस APK ने जिन अनुमतियों के लिए अनुरोध किया है.
|
UsesPermission
इस APK की ओर से इस्तेमाल की जाने वाली अनुमति.
JSON के काेड में दिखाना |
{
"name": string,
"maxSdkVersion": integer
} |
फ़ील्ड |
name |
string
अनुरोध की गई अनुमति का नाम.
|
maxSdkVersion |
integer
आपके पास SDK टूल का ज़्यादा से ज़्यादा वह वर्शन होना चाहिए जिसके लिए अनुमति की ज़रूरत है. हालांकि, ऐसा करना ज़रूरी नहीं है.
|
जब तक कुछ अलग से न बताया जाए, तब तक इस पेज की सामग्री को Creative Commons Attribution 4.0 License के तहत और कोड के नमूनों को Apache 2.0 License के तहत लाइसेंस मिला है. ज़्यादा जानकारी के लिए, Google Developers साइट नीतियां देखें. Oracle और/या इससे जुड़ी हुई कंपनियों का, Java एक रजिस्टर किया हुआ ट्रेडमार्क है.
आखिरी बार 2025-07-26 (UTC) को अपडेट किया गया.
[null,null,["आखिरी बार 2025-07-26 (UTC) को अपडेट किया गया."],[[["\u003cp\u003eCreates a new APK hosted at a specified URL instead of uploading it to Google Play, restricted to Managed Play organizations.\u003c/p\u003e\n"],["\u003cp\u003eRequires an HTTP POST request to \u003ccode\u003ehttps://androidpublisher.googleapis.com/androidpublisher/v3/applications/{packageName}/edits/{editId}/apks/externallyHosted\u003c/code\u003e.\u003c/p\u003e\n"],["\u003cp\u003eThe request body defines the externally-hosted APK with details like package name, version code, checksums, and hosting URL.\u003c/p\u003e\n"],["\u003cp\u003eThe response provides the details of the successfully created externally hosted APK.\u003c/p\u003e\n"],["\u003cp\u003eThis functionality requires the \u003ccode\u003ehttps://www.googleapis.com/auth/androidpublisher\u003c/code\u003e authorization scope.\u003c/p\u003e\n"]]],["This document details the process of creating an externally hosted APK for Managed Play applications. The core action is sending a `POST` request to a specific endpoint with the `packageName` and `editId`. The request body includes an `externallyHostedApk` object, defining the APK's metadata like its URL, version, checksums, supported SDKs, and required permissions. The server returns the same object in the response upon successful creation. This process is authorized with the `androidpublisher` scope.\n"],null,["# Method: edits.apks.addexternallyhosted\n\n- [HTTP request](#body.HTTP_TEMPLATE)\n- [Path parameters](#body.PATH_PARAMETERS)\n- [Request body](#body.request_body)\n - [JSON representation](#body.request_body.SCHEMA_REPRESENTATION)\n- [Response body](#body.response_body)\n - [JSON representation](#body.ApksAddExternallyHostedResponse.SCHEMA_REPRESENTATION)\n- [Authorization scopes](#body.aspect)\n- [ExternallyHostedApk](#ExternallyHostedApk)\n - [JSON representation](#ExternallyHostedApk.SCHEMA_REPRESENTATION)\n- [UsesPermission](#UsesPermission)\n - [JSON representation](#UsesPermission.SCHEMA_REPRESENTATION)\n- [Try it!](#try-it)\n\nCreates a new APK without uploading the APK itself to Google Play, instead hosting the APK at a specified URL. This function is only available to organizations using Managed Play whose application is configured to restrict distribution to the organizations.\n\n### HTTP request\n\n`POST https://androidpublisher.googleapis.com/androidpublisher/v3/applications/{packageName}/edits/{editId}/apks/externallyHosted`\n\nThe URL uses [gRPC Transcoding](https://google.aip.dev/127) syntax.\n\n### Path parameters\n\n| Parameters ||\n|---------------|-----------------------------------|\n| `packageName` | `string` Package name of the app. |\n| `editId` | `string` Identifier of the edit. |\n\n### Request body\n\nThe request body contains data with the following structure:\n\n| JSON representation |\n|---------------------------------------------------------------------------------------------------------------------------------------|\n| ``` { \"externallyHostedApk\": { object (/android-publisher/api-ref/rest/v3/edits.apks/addexternallyhosted#ExternallyHostedApk) } } ``` |\n\n| Fields ||\n|-----------------------|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| `externallyHostedApk` | `object (`[ExternallyHostedApk](/android-publisher/api-ref/rest/v3/edits.apks/addexternallyhosted#ExternallyHostedApk)`)` The definition of the externally-hosted APK and where it is located. |\n\n### Response body\n\nResponse for creating a new externally hosted APK.\n\nIf successful, the response body contains data with the following structure:\n\n| JSON representation |\n|---------------------------------------------------------------------------------------------------------------------------------------|\n| ``` { \"externallyHostedApk\": { object (/android-publisher/api-ref/rest/v3/edits.apks/addexternallyhosted#ExternallyHostedApk) } } ``` |\n\n| Fields ||\n|-----------------------|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| `externallyHostedApk` | `object (`[ExternallyHostedApk](/android-publisher/api-ref/rest/v3/edits.apks/addexternallyhosted#ExternallyHostedApk)`)` The definition of the externally-hosted APK and where it is located. |\n\n### Authorization scopes\n\nRequires the following OAuth scope:\n\n- `https://www.googleapis.com/auth/androidpublisher`\n\nExternallyHostedApk\n-------------------\n\nDefines an APK available for this application that is hosted externally and not uploaded to Google Play. This function is only available to organizations using Managed Play whose application is configured to restrict distribution to the organizations.\n\n| JSON representation |\n|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| ``` { \"packageName\": string, \"applicationLabel\": string, \"versionCode\": integer, \"versionName\": string, \"fileSize\": string, \"fileSha1Base64\": string, \"fileSha256Base64\": string, \"iconBase64\": string, \"minimumSdk\": integer, \"certificateBase64s\": [ string ], \"externallyHostedUrl\": string, \"maximumSdk\": integer, \"nativeCodes\": [ string ], \"usesFeatures\": [ string ], \"usesPermissions\": [ { object (/android-publisher/api-ref/rest/v3/edits.apks/addexternallyhosted#UsesPermission) } ] } ``` |\n\n| Fields ||\n|------------------------|--------------------------------------------------------------------------------------------------------------------------------------------------------|\n| `packageName` | `string` The package name. |\n| `applicationLabel` | `string` The application label. |\n| `versionCode` | `integer` The version code of this APK. |\n| `versionName` | `string` The version name of this APK. |\n| `fileSize` | `string (`[int64](https://developers.google.com/discovery/v1/type-format)` format)` The file size in bytes of this APK. |\n| `fileSha1Base64` | `string` The sha1 checksum of this APK, represented as a base64 encoded byte array. |\n| `fileSha256Base64` | `string` The sha256 checksum of this APK, represented as a base64 encoded byte array. |\n| `iconBase64` | `string` The icon image from the APK, as a base64 encoded byte array. |\n| `minimumSdk` | `integer` The minimum SDK targeted by this APK. |\n| `certificateBase64s[]` | `string` A certificate (or array of certificates if a certificate-chain is used) used to sign this APK, represented as a base64 encoded byte array. |\n| `externallyHostedUrl` | `string` The URL at which the APK is hosted. This must be an https URL. |\n| `maximumSdk` | `integer` The maximum SDK supported by this APK (optional). |\n| `nativeCodes[]` | `string` The native code environments supported by this APK (optional). |\n| `usesFeatures[]` | `string` The features required by this APK (optional). |\n| `usesPermissions[]` | `object (`[UsesPermission](/android-publisher/api-ref/rest/v3/edits.apks/addexternallyhosted#UsesPermission)`)` The permissions requested by this APK. |\n\nUsesPermission\n--------------\n\nA permission used by this APK.\n\n| JSON representation |\n|------------------------------------------------------|\n| ``` { \"name\": string, \"maxSdkVersion\": integer } ``` |\n\n| Fields ||\n|-----------------|-------------------------------------------------------------------------------------|\n| `name` | `string` The name of the permission requested. |\n| `maxSdkVersion` | `integer` Optionally, the maximum SDK version for which the permission is required. |"]]