Skip to main content
Process.getgroups - node__process.d.ts - Node documentation
property Process.getgroups

Usage in Deno

```typescript import { type Process } from "node:node__process.d.ts"; ```
The `process.getgroups()` method returns an array with the supplementary group IDs. POSIX leaves it unspecified if the effective group ID is included but Node.js ensures it always is. ```js import process from 'node:process'; if (process.getgroups) { console.log(process.getgroups()); // [ 16, 21, 297 ] } ``` This function is only available on POSIX platforms (i.e. not Windows or Android).

Type

() => number[]