Skip to content

Conversation

@vmvarela
Copy link

New data sources:

  • github_enterprise_scim_groups — GET /scim/v2/enterprises/{enterprise}/Groups (auto-paginates to fetch all results)
  • github_enterprise_scim_group — GET /scim/v2/enterprises/{enterprise}/Groups/{scim_group_id}
  • github_enterprise_scim_users — GET /scim/v2/enterprises/{enterprise}/Users (auto-paginates to fetch all results)
  • github_enterprise_scim_user — GET /scim/v2/enterprises/{enterprise}/Users/{scim_user_id}

Shared helper/types in util_enterprise_scim.go:

  • SCIM request builder + Accept: application/scim+json
  • SCIM list pagination loop using startIndex/count (exposed as results_per_page, fetch-all by default)
  • Full-fidelity flattening for groups/users (meta, members, emails, roles, name, etc.)

Before the change?

  • No support for reading enterprise SCIM entities

After the change?

  • Implements: enterprise SCIM read data sources for Groups/Users (list + get).

Pull request checklist

  • Schema migrations have been created if needed (example)
  • Tests for the changes have been added (for bug fixes / features)
  • Docs have been reviewed and added / updated if needed (for bug fixes / features)

Does this introduce a breaking change?

Please see our docs on breaking changes to help!

  • Yes
  • No

@github-actions
Copy link

👋 Hi! Thank you for this contribution! Just to let you know, our GitHub SDK team does a round of issue and PR reviews twice a week, every Monday and Friday! We have a process in place for prioritizing and responding to your input. Because you are a part of this community please feel free to comment, add to, or pick up any issues/PRs that are labeled with Status: Up for grabs. You & others like you are the reason all of this works! So thank you & happy coding! 🚀

@vmvarela vmvarela closed this Dec 21, 2025
@vmvarela vmvarela reopened this Dec 22, 2025
Copilot AI review requested due to automatic review settings January 6, 2026 18:15
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR adds comprehensive SCIM (System for Cross-domain Identity Management) data source support for GitHub Enterprise, enabling users to query provisioned groups and users through Terraform.

  • Implements four new data sources for enterprise SCIM groups and users (list and individual retrieval)
  • Adds shared utility functions for SCIM API interactions with automatic pagination support
  • Includes comprehensive test coverage and documentation for all new data sources

Reviewed changes

Copilot reviewed 14 out of 14 changed files in this pull request and generated 4 comments.

Show a summary per file
File Description
github/provider.go Registers the four new SCIM data sources in the provider
github/util_enterprise_scim.go Implements shared SCIM utilities including pagination, request building, and data flattening functions
github/data_source_github_enterprise_scim_groups.go Data source for listing all SCIM groups with filtering and pagination support
github/data_source_github_enterprise_scim_group.go Data source for retrieving a single SCIM group by ID
github/data_source_github_enterprise_scim_users.go Data source for listing all SCIM users with filtering and pagination support
github/data_source_github_enterprise_scim_user.go Data source for retrieving a single SCIM user by ID
github/data_source_github_enterprise_scim_groups_test.go Unit tests for groups listing with multi-page pagination
github/data_source_github_enterprise_scim_group_test.go Unit tests for individual group retrieval
github/data_source_github_enterprise_scim_users_test.go Unit tests for users listing with filtering and pagination
github/data_source_github_enterprise_scim_user_test.go Unit tests for individual user retrieval
website/docs/d/enterprise_scim_groups.html.markdown Documentation for the SCIM groups listing data source
website/docs/d/enterprise_scim_group.html.markdown Documentation for the single SCIM group data source
website/docs/d/enterprise_scim_users.html.markdown Documentation for the SCIM users listing data source
website/docs/d/enterprise_scim_user.html.markdown Documentation for the single SCIM user data source

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@vmvarela vmvarela force-pushed the enterprise-scim branch 2 times, most recently from e64c25b to 615a000 Compare January 8, 2026 16:36
@vmvarela vmvarela changed the title feat: Add Enterprise SCIM data sources (groups/users) [FEAT] Add Enterprise SCIM data sources (groups/users) Jan 8, 2026
…ibutes

- Replace local SCIM types with github.SCIMEnterprise* from go-github v81
- Remove enterpriseSCIMListURL, enterpriseSCIMGet helper functions
- Use client.Enterprise.ListProvisionedSCIMGroups/Users directly
- Remove excluded_attributes parameter from all data sources
- Fix GitHub brand name capitalization in documentation
- Update tests to match new API calls
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.

1 participant