---
title: "Script - user by group (beanshell)"
canonical: "https://support.appfire.com/space/SCRP/73728604/Script%20-%20user%20by%20group%20(beanshell)"
format: markdown
---
> Macro (aura-html)

| **Parameter** | **Required** | **Default** | **Discussion** |
| --- | --- | --- | --- |
| groupName | :cross_mark: | not set | If not set, all groups/users will be shown. Specifying groupName restricts output to a single group |

### All users in confluence-administrators

```
{beanshell:output=wiki|script=#https://bitbucket.org/bob_swift/examples/raw/tip/confluence/beanshell/userByGroup.bsh|groupName=confluence-administrators} 
{beanshell}

```

![image](media://d8e3f6f0-5642-400a-8996-41d9b854c2d6)

### All groups

```
{beanshell:output=wiki|script=#usersbygroup.bsh} 
{beanshell}
```