Skip to content

[DIR-128] Group Create resource action#135

Draft
VVill-ga wants to merge 2 commits into
mainfrom
willgarrison/create-group-rs-action
Draft

[DIR-128] Group Create resource action#135
VVill-ga wants to merge 2 commits into
mainfrom
willgarrison/create-group-rs-action

Conversation

@VVill-ga
Copy link
Copy Markdown

@VVill-ga VVill-ga commented Jan 31, 2026

Okta allows defining custom schemas, sometimes including required fields, so we fetch and parse those at registration time. Plan to expand this for more frequent refreshing of the schema.

The following fields can be added, but they are each additional API calls:

  • Members (+1 api call per user)
  • Owners (+1 api call per user) - also requires OIG
  • Membership Rule
  • Application access assignment

After discussion, we decided to support Members and Applications with limits on each.

@linear
Copy link
Copy Markdown

linear Bot commented Jan 31, 2026

@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai Bot commented Jan 31, 2026

Important

Review skipped

Draft detected.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

  • 🔍 Trigger a full review
✨ Finishing touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch willgarrison/create-group-rs-action

Comment @coderabbitai help to get the list of available commands and usage tips.

@phoebesimon
Copy link
Copy Markdown

@VVill-ga I think I'd lean toward including the ability to set members/owners/applications, but just limit how many can be set as part of the initial request here to something kinda small, like 25 (?). I'm a little more ambivalent on Rules, at least on this first pass, since they feel harder to present nicely in our UI/validate

@VVill-ga VVill-ga force-pushed the willgarrison/create-group-rs-action branch from b94acc6 to 8bae1fa Compare February 4, 2026 19:18
Comment thread pkg/connector/group.go
entitlements = append(entitlements, memberEntitlement)

// Add members to the group
for _, memberID := range memberIDs {
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think custom actions should be doing multiple grants as part of a create. Due to GRPC message limits, we have to restrict the number of users & apps that can be added. Also each request can fail (and doesn't seem to retry if we hit a retryable error), but we can't retry the whole operation since the group already exists and some users are already members. It makes much more sense to me to have an automation that creates the group, then makes grant tasks to add each user. That way if adding one user fails, the other users will still get added and the failed grants can be retried or at least shown on the ticket. If making lots of grants is too slow or inefficient, we should fix that problem instead of trying to work around it.

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fair point on the erroring, if handling it is too complicated we can remove the fields, they are just nice to have for the action with the group template / creation flow.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants