Method: licenseAssignments.update
Tetap teratur dengan koleksi
Simpan dan kategorikan konten berdasarkan preferensi Anda.
Menetapkan ulang SKU produk pengguna dengan SKU yang berbeda dalam produk yang sama.
Permintaan HTTP
PUT https://licensing.googleapis.com/apps/licensing/v1/product/{productId}/sku/{skuId}/user/{userId}
URL menggunakan sintaksis gRPC Transcoding.
Parameter jalur
Parameter |
productId |
string
ID unik produk. Untuk informasi selengkapnya tentang produk dalam versi API ini, lihat Produk dan SKU.
|
skuId |
string
ID unik SKU produk. Untuk informasi selengkapnya tentang SKU yang tersedia dalam versi API ini, lihat Produk dan SKU.
|
userId |
string
Alamat email utama pengguna saat ini. Jika alamat email pengguna berubah, gunakan alamat email baru dalam permintaan API Anda. Karena userId dapat berubah, jangan gunakan nilai userId sebagai kunci untuk data persisten. Kunci ini dapat rusak jika alamat email pengguna saat ini berubah. Jika userId ditangguhkan, status lisensi akan berubah.
|
Isi permintaan
Isi permintaan memuat instance LicenseAssignment
.
Isi respons
Jika berhasil, isi respons memuat instance LicenseAssignment
.
Cakupan otorisasi
Memerlukan cakupan OAuth berikut:
https://www.googleapis.com/auth/apps.licensing
Untuk mengetahui informasi selengkapnya, lihat Panduan otorisasi.
Kecuali dinyatakan lain, konten di halaman ini dilisensikan berdasarkan Lisensi Creative Commons Attribution 4.0, sedangkan contoh kode dilisensikan berdasarkan Lisensi Apache 2.0. Untuk mengetahui informasi selengkapnya, lihat Kebijakan Situs Google Developers. Java adalah merek dagang terdaftar dari Oracle dan/atau afiliasinya.
Terakhir diperbarui pada 2025-07-25 UTC.
[null,null,["Terakhir diperbarui pada 2025-07-25 UTC."],[],[],null,["# Method: licenseAssignments.update\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\nReassign a user's product SKU with a different SKU in the same product.\n\n### HTTP request\n\n`PUT https://licensing.googleapis.com/apps/licensing/v1/product/{productId}/sku/{skuId}/user/{userId}`\n\nThe URL uses [gRPC Transcoding](https://google.aip.dev/127) syntax.\n\n### Path parameters\n\n| Parameters ||\n|-------------|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| `productId` | `string` A product's unique identifier. For more information about products in this version of the API, see [Products and SKUs](https://developers.google.com/workspace/admin/licensing/v1/how-tos/products). |\n| `skuId` | `string` A product SKU's unique identifier. For more information about available SKUs in this version of the API, see [Products and SKUs](https://developers.google.com/workspace/admin/licensing/v1/how-tos/products). |\n| `userId` | `string` The user's current primary email address. If the user's email address changes, use the new email address in your API requests. Since a `userId` is subject to change, do not use a `userId` value as a key for persistent data. This key could break if the current user's email address changes. If the `userId` is suspended, the license status changes. |\n\n### Request body\n\nThe request body contains an instance of [LicenseAssignment](/workspace/admin/licensing/reference/rest/v1/licenseAssignments#LicenseAssignment).\n\n### Response body\n\nIf successful, the response body contains an instance of [LicenseAssignment](/workspace/admin/licensing/reference/rest/v1/licenseAssignments#LicenseAssignment).\n\n### Authorization scopes\n\nRequires the following OAuth scope:\n\n- `https://www.googleapis.com/auth/apps.licensing`\n\nFor more information, see the [Authorization guide](/workspace/guides/configure-oauth-consent)."]]