glab(1)

✨ glab(1) β€” the repo members add glow-up ✨

okay bestie, so this is a page from the glab manual (yes, the glab, the GitLab CLI, we stan) and it's all about one specific little command that adds a person to your project. it's giving "invite your friend to the group chat" energy and honestly? iconic. let's get into it πŸ’…


🌸 NAME 🌸

glab-repo-members-add β€” literally just: add a member to the project. that's the whole vibe. 🫢


⭐ SYNOPSIS ⭐

glab repo members add [flags]

no positional args, no drama, just flags. periodt.


πŸ¦‹ DESCRIPTION πŸ¦‹

so you wanna add a member to the project with a specified role. that's it, that's the function. but the roles? oh we have a whole lineup, and you're gonna want to know them by heart πŸ‘‘

  • guest (10) β€” can view the project. lurker mode, lowkey valid.
  • reporter (20) β€” can view and create issues. they can post, they can't push.
  • developer (30) β€” can push to non-protected branches. main character energy, but not on main 🚫
  • maintainer (40) β€” can manage the project. they run the group chat.
  • owner (50) β€” full access to the project. absolute final boss, no cap. πŸ”₯

for custom roles, hit up --role-id with the ID of a custom role defined in the project or group. and listen β€” if that custom role does not exist, an error is returned. so double-check your ID bestie, don't come crying to me 😭


✨ OPTIONS ✨

  • -e, --expires-at="" β€” expiration date for the membership, formatted as YYYY-MM-DD. the membership has a scheduled departure, very mysterious of it πŸŽ€
  • -R, --repo="" β€” select another repository. you can use either OWNER/REPO or GROUP/NAMESPACE/REPO. the full URL or Git URL is also accepted. so many ways to say where, we love options πŸ¦‹
  • -r, --role="developer" β€” role for the user. valid picks: guest, reporter, developer, maintainer, owner. default is developer, they really said "start them off reasonable" 🌸
  • --role-id=0 β€” ID of a custom role defined in the project or group. for the ✨ bespoke ✨ role enjoyers.
  • -u, --user-id=0 β€” user ID instead of username. numbers only, no names.
  • --username="" β€” username instead of user-id. names only, no numbers. pick a lane, we support both πŸ’–

🧚 OPTIONS INHERITED FROM PARENT COMMANDS 🧚

  • -h, --help[=false] β€” show help for this command. the classic. the icon. when in doubt, -h it out.

🌈 EXAMPLE 🌈

here's exactly how the cool kids do it, copied with love:

# Add a user as a developer
glab repo members add --username=john.doe --role=developer
# Add a user as a maintainer with expiration date
glab repo members add --username=jane.smith --role=maintainer --expires-at=2024-12-31
# Add a user by ID
glab repo members add --user-id=123 --role=reporter
# Add a user with a custom role
glab repo members add --username=john.doe --role-id=101

see? four whole examples. jane's membership expires at 2024-12-31 and we respect her journey 🫢


πŸ’œ SEE ALSO πŸ’œ


ngl bestie, if you're passing --role-id, make sure that custom role actually exists in the project or group first. otherwise: error. and not the cute kind. πŸ’€

and that's the page!! πŸ’– auto generated by spf13/cobra, dated Nov 2026, and this is glab(1) signing off β€” slay, stay hydrated, and go add some members πŸŽ€βœ¨

πŸ“¦ where this page comes from