Metode PickerBuilder.setAppId
Tetap teratur dengan koleksi
Simpan dan kategorikan konten berdasarkan preferensi Anda.
Menetapkan ID aplikasi yang perlu mengakses file pengguna melalui
Drive API.
Hal ini diperlukan untuk cakupan https://www.googleapis.com/auth/drive.file
.
Contoh
Penggunaan dasar
const builder = new google.pickerPickerBuilder()
.setAppId('1234567890');
Tanda Tangan
setAppId(appId: string): PickerBuilder;
Detail
Opsional |
Tidak |
Final |
Tidak |
Dengan kontrasepsi |
Tidak |
Statis |
Tidak |
Parameter
Nama |
Jenis |
Opsional |
Deskripsi |
appId |
string |
Tidak |
Nomor project Cloud. |
Hasil
PickerBuilder
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 PickerBuilder.setAppId\n\nSets the Id of the application needing to access the user's files via the\n[Drive API](/workspace/drive/api).\n\nThis is required for the `https://www.googleapis.com/auth/drive.file` scope.\n\nExamples\n--------\n\nBasic usage \n\n const builder = new google.pickerPickerBuilder()\n .setAppId('1234567890');\n\nSignature\n---------\n\n setAppId(appId: string): PickerBuilder;\n\nDetails\n-------\n\n| Optional | No |\n| Final | No |\n| Protected | No |\n| Static | No |\n|-----------|----|\n\nParameters\n----------\n\n| Name | Type | Optional | Description |\n|---------|----------|----------|---------------------------|\n| `appId` | `string` | No | The Cloud project number. |\n\nReturns\n-------\n\n[PickerBuilder](./picker.pickerbuilder)"]]