nocobase-app-plugin-users
Fungsinya
Skill ini mengintegrasikan plugin Users NocoBase ke dalam aplikasi dan membangun halaman manajemen pengguna di atas API-nya. Cocok untuk administrator dan pengembang yang mengelola siapa saja yang memiliki akun di aplikasi.
Kapan dipakai
- ✓Saat Anda ingin halaman admin untuk membuat, menonaktifkan, atau mengatur ulang akun pengguna.
- ✓Saat plugin lain perlu menambahkan peran sendiri ke manajemen pengguna.
- ✓Saat Anda perlu mengonfigurasi izin plugin users.
Link skill
https://github.com/nocobase/nocobase/blob/v3-develop/packages/plugins/app-plugin-users/skills/nocobase-app-plugin-users/SKILL.mdSalin lalu tempelkan ke AI Anda (Claude, ChatGPT, atau Cursor) dan minta AI mengikuti instruksinya.
Cara pakai
Cara paling mudah: salin pesan ini dan tempelkan ke AI Anda. AI akan membaca skill dan mengikuti instruksinya.
Pesan siap tempel
Untuk Claude Code, Codex, atau Cursor: jalankan di folder proyek, lalu skill langsung terpasang.
Unduh SKILL.md lalu taruh di folder skill agen Anda.
Contoh permintaan ke AI
“Bisakah Anda menambahkan halaman manajemen pengguna ke aplikasi NocoBase saya tempat admin bisa mengundang orang dan menonaktifkan akun?”
5 skill baru setiap minggu. 1 menit baca.
Cara kerjanya
AI mendaftarkan plugin dan membangun halaman di atas API-nya untuk aksi daftar, pembuatan, pembaruan, penonaktifan, dan atur ulang. Penyimpanan akun dan sesi tetap berada pada plugin autentikasi.
Konten teknis (SKILL.md asli)
Teks asli dari pembuat, dalam bahasa Inggris, langsung dari GitHub.
User Management App Plugin
Use this Skill when an application needs user management, or when another plugin needs to expose application-specific roles in user management. Do not use it to modify the Users plugin source or to replace Authentication's user, account, or Session storage.
Public surfaces
- Client registration factory and
UsersClientOptions:@nocobase/app-plugin-users/client. It contributes only the public invitation page at/invite/:token; there is no user management page. - Typed API client:
UsersClientand its types from@nocobase/app-plugin-users/client/user-client. - Server contracts:
userManagementServiceToken,userRoleScopeRegistryToken,UserRoleScope, and related types from@nocobase/app-plugin-users/server/tokens. - HTTP API:
GET /api/users(page,pageSize,q,status,roleScope,role,sort=name,order=asc|desc; answers{ data, meta: { page, pageSize, total } }),GET /api/users/options,GET /api/users/:userId(latest managed profile and role scopes, requiresuser/read, 404 for absent accounts),POST /api/users,PATCH /api/users/:userId,DELETE /api/users/:userId?confirm=true,POST /api/users/:userId/disable|enable|resetPassword|revokeSessions, andPUT /api/users/:userId/roleScopes/:scope. The running application documents each one, with request and response schemas, at/api/swagger/docs(JSON at/api/swagger) under theUserstag. Failures use the standard error body; branch onerror.reason, such asUSER_NOT_FOUND,SELF_DELETE_NOT_ALLOWED,LAST_ASSIGNMENTorUSER_EMAIL_CONFLICT.
UsersClient.update(userId, { name?, username?, email?, roleScopes? }) supports one atomic editor Save. Profile fields require update; submitted roleScopes additionally require assign-role. A roles-only payload requires assign-role without update. The service validates scope values, runs each applicable target-account guard, and commits profile changes and all submitted scope replacements in the caller-owned transaction, notifying permission clients only after commit. Omitted scopes are preserved. Keep the existing per-scope PUT for callers needing only one scope. Do not implement a combined Save as sequential profile and role requests: a later failure would leave a partially saved account.
Every HTTP route requires Authentication and Authorization. Routes check the user record type with the applicable action from read, create, update, disable, enable, assign-role, reset-password, revoke-sessions or delete. Account creation checks both create and assign-role. delete is permitted only while an application role scope can clean a deleted user up.
Register the plugin
- Register Authentication, Authorization, and then Users in the App's Client
and Server plugin arrays. The Client factory takes no placement options:
users(). - Grant only the
useractions those roles need, on{ type: 'user', id: '*' }becauseuseris a record type. The plugin creates no roles and grants no access by itself. - For a user management page, build it in the App on
UsersClientand declare it among the App's own routes with the page access it needs; the plugin ships none.
The invitation page reports results through useToaster() from @nocobase/app-client, so the App needs the @nocobase/app-client that exports it and registers a toaster service, as the templates do: client/lib/toaster.ts from the template, and this.app.container.instance(toasterToken, createToaster()) in the register() of client/service-provider.ts, with the Toaster component mounted in client/react-providers.ts. Without the registration nothing throws, but its toasts are only logged to the browser console.
The default app permission-set scope is supplied by Users whenever the Authorization plugin's authorizationToken is available. Do not copy a user-roles Provider into an application. Set users.permissionSets: false to replace the default with an application-owned scope.
Add an application role scope
Resolve userRoleScopeRegistryToken in an application or business plugin
ServiceProvider and register one UserRoleScope during boot(). The scope owns
its available options, current assignment lookup, role filtering, atomic
replacement, and any disable guard. Unregister it during shutdown().
Use the DatabaseConnection passed to each scope method. This is the
caller-owned transaction used to keep account cr
Pertanyaan umum
Apakah ini menggantikan sistem login?
Tidak. Plugin autentikasi menyimpan akun dan sesi.
Apakah ini sudah menyertakan halaman admin secara default?
Tidak. Plugin hanya menambahkan halaman undangan publik, sehingga halaman admin perlu Anda buat sendiri.
Bisakah aplikasi menambahkan peran sendiri?
Bisa, melalui kontrak cakupan peran yang disediakan aplikasi atau plugin lain.
Detail
Deskripsi asli dari pembuat
Integrate the Users plugin into a NocoBase App, build a user management page on its API and configure its permissions, or add an application-owned role scope through the public Server contracts.
repo: nocobase/nocobase
Popularitas
- Bintang GitHub
- 25k
- Peringkat
- #10107
- Lisensi
- —
- Diperbarui
- 2/11/2026
Komentar
- …
Skill lain dari repositori ini
nocobase-app-development
25kMembantu agent Anda membangun halaman, rute, data, izin, dan tes untuk aplikasi bisnis NocoBase 3 yang lengkap.
shadcn
25kMembantu agent Anda menemukan, menambahkan, memperbaiki, dan memberi gaya komponen shadcn/ui pada proyek web, dengan memakai dokumentasi resmi dan registry-nya.
nocobase-app-plugin-development
25kMembantu agent Anda membuat dan memelihara plugin NocoBase 3 di dalam aplikasi yang sudah ada, mencakup bagian server, klien, database, dan registrasi.
nocobase-app-upgrade
25kMembantu agent Anda meningkatkan aplikasi NocoBase ke rilis template yang lebih baru, membawa perubahan template sambil tetap mempertahankan pekerjaan Anda sendiri.
Skill serupa
reverse-engineer-anything
422kMembantu agent Anda memeriksa aplikasi dan paket yang sudah dirilis untuk menjelaskan fitur, membandingkan versi, atau memandu pembangunan ulang dengan alat REA.
1password
394kMembantu agent Anda mengatur CLI 1Password, masuk, serta membaca atau menyisipkan rahasia tanpa menampilkan nilainya di chat.
healthcheck
394kMembantu agent Anda mengaudit komputer atau server OpenClaw dari risiko keamanan seperti SSH, firewall, pembaruan, dan cadangan, lalu menyarankan perbaikan aman.