Method: users.settings.cse.keypairs.create
संग्रह की मदद से व्यवस्थित रहें
अपनी प्राथमिकताओं के आधार पर, कॉन्टेंट को सेव करें और कैटगरी में बांटें.
पुष्टि किए गए उपयोगकर्ता के लिए, क्लाइंट-साइड एन्क्रिप्शन S/MIME सार्वजनिक कुंजी सर्टिफ़िकेट चेन और निजी कुंजी का मेटाडेटा बनाता और अपलोड करता है.
अपने संगठन के उपयोगकर्ताओं की पहचान और पासकोड मैनेज करने वाले एडमिन को, अनुरोधों के लिए सेवा खाते से अनुमति लेनी होगी. इस खाते के पास https://www.googleapis.com/auth/gmail.settings.basic
स्कोप वाले उपयोगकर्ताओं के नाम पर काम करने के लिए, डोमेन के लिए अनुमति देने का अधिकार होना चाहिए.
अपनी पहचान और की-पेयर मैनेज करने वाले उपयोगकर्ताओं के लिए, अनुरोधों के लिए हार्डवेयर पासकोड एन्क्रिप्शन चालू और कॉन्फ़िगर होना ज़रूरी है.
एचटीटीपी अनुरोध
POST https://gmail.googleapis.com/gmail/v1/users/{userId}/settings/cse/keypairs
यूआरएल में gRPC ट्रांसकोडिंग सिंटैक्स का इस्तेमाल किया गया है.
पाथ पैरामीटर
पैरामीटर |
userId |
string
अनुरोध करने वाले का मुख्य ईमेल पता. पुष्टि किए गए उपयोगकर्ता की जानकारी देने के लिए, खास वैल्यू me का इस्तेमाल किया जा सकता है.
|
अनुरोध का मुख्य भाग
अनुरोध के मुख्य भाग में CseKeyPair
का उदाहरण है.
जवाब का मुख्य भाग
कामयाब रहने पर, जवाब के मुख्य हिस्से में CseKeyPair
का नया इंस्टेंस शामिल किया जाता है.
अनुमति के दायरे
इसके लिए, OAuth के इनमें से किसी एक स्कोप की ज़रूरत होती है:
https://www.googleapis.com/auth/gmail.settings.basic
https://www.googleapis.com/auth/gmail.settings.sharing
ज़्यादा जानकारी के लिए, अनुमति से जुड़ी गाइड देखें.
जब तक कुछ अलग से न बताया जाए, तब तक इस पेज की सामग्री को Creative Commons Attribution 4.0 License के तहत और कोड के नमूनों को Apache 2.0 License के तहत लाइसेंस मिला है. ज़्यादा जानकारी के लिए, Google Developers साइट नीतियां देखें. Oracle और/या इससे जुड़ी हुई कंपनियों का, Java एक रजिस्टर किया हुआ ट्रेडमार्क है.
आखिरी बार 2025-07-25 (UTC) को अपडेट किया गया.
[null,null,["आखिरी बार 2025-07-25 (UTC) को अपडेट किया गया."],[],[],null,["# Method: users.settings.cse.keypairs.create\n\n- [HTTP request](#body.HTTP_TEMPLATE)\n- [Path parameters](#body.PATH_PARAMETERS)\n- [Request body](#body.request_body)\n- [Response body](#body.response_body)\n- [Authorization scopes](#body.aspect)\n- [Try it!](#try-it)\n\nCreates and uploads a client-side encryption S/MIME public key certificate chain and private key metadata for the authenticated user.\n\nFor administrators managing identities and keypairs for users in their organization, requests require authorization with a [service account](https://developers.google.com/identity/protocols/OAuth2ServiceAccount) that has [domain-wide delegation authority](https://developers.google.com/identity/protocols/OAuth2ServiceAccount#delegatingauthority) to impersonate users with the `https://www.googleapis.com/auth/gmail.settings.basic` scope.\n\nFor users managing their own identities and keypairs, requests require [hardware key encryption](https://support.google.com/a/answer/14153163) turned on and configured.\n\n### HTTP request\n\n`POST https://gmail.googleapis.com/gmail/v1/users/{userId}/settings/cse/keypairs`\n\nThe URL uses [gRPC Transcoding](https://google.aip.dev/127) syntax.\n\n### Path parameters\n\n| Parameters ||\n|----------|-------------------------------------------------------------------------------------------------------------------------|\n| `userId` | `string` The requester's primary email address. To indicate the authenticated user, you can use the special value `me`. |\n\n### Request body\n\nThe request body contains an instance of [CseKeyPair](/workspace/gmail/api/reference/rest/v1/users.settings.cse.keypairs#CseKeyPair).\n\n### Response body\n\nIf successful, the response body contains a newly created instance of [CseKeyPair](/workspace/gmail/api/reference/rest/v1/users.settings.cse.keypairs#CseKeyPair).\n\n### Authorization scopes\n\nRequires one of the following OAuth scopes:\n\n- `https://www.googleapis.com/auth/gmail.settings.basic`\n- `\n https://www.googleapis.com/auth/gmail.settings.sharing`\n\nFor more information, see the [Authorization guide](/workspace/guides/configure-oauth-consent)."]]