Skip to content

feat: Add CIMD client registration support and tenant metadata settings#1369

Merged
ankita10119 merged 13 commits intomasterfrom
DXCDT-1515-cimd-manual-registration
Apr 23, 2026
Merged

feat: Add CIMD client registration support and tenant metadata settings#1369
ankita10119 merged 13 commits intomasterfrom
DXCDT-1515-cimd-manual-registration

Conversation

@kushalshit27
Copy link
Copy Markdown
Contributor

🔧 Changes

  • Add CIMD-aware client handling so Deploy CLI can register clients from an external_client_id metadata document instead of treating them like standard clients. This adds schema support for external_client_id, external_metadata_type, external_metadata_created_by, and jwks_uri.
  • Extend the tenant handler schema and typing to support client_id_metadata_document_supported and resource_parameter_profile, so these tenant settings can be exported and imported alongside the existing tenant configuration.

Examples

YAML format

CIMD Client:

clients:
  - name: "MCP Tool Server"
    external_client_id: "https://mcpserver.example.com/client.json"
    external_metadata_type: "cimd"
    external_metadata_created_by: "admin"
    jwks_uri: "https://mcpserver.example.com/jwks.json"
    description: "editable after registration"

Tenant:

tenant:
  client_id_metadata_document_supported: true
  resource_parameter_profile: "compatibility"

JSON format

CIMD Client:

{
  "name": "MCP Tool Server",
  "external_client_id": "https://mcpserver.example.com/client.json",
  "external_metadata_type": "cimd",
  "external_metadata_created_by": "admin",
  "jwks_uri": "https://mcpserver.example.com/jwks.json",
  "description": "editable after registration"
}

Tenant:

{
  "client_id_metadata_document_supported": true,
  "resource_parameter_profile": "compatibility"
}

🔬 Testing

  • Review the new unit coverage in test/tools/auth0/handlers/clients.tests.js:
    • create a CIMD client through registerCimdClient without issuing a follow-up patch
    • match an existing CIMD client by external_client_id and update only editable fields
    • allow validation when CIMD metadata fields are present
  • Review the tenant handler coverage in test/tools/auth0/handlers/tenant.tests.ts to confirm the new tenant settings are preserved on export and included on update.

📝 Checklist

  • All new/changed/fixed functionality is covered by tests (or N/A)
  • I have added documentation for all new/changed functionality (or N/A)

* refactor: Getting enabled clients for connection

* feat(test): add test for fetching enabled clients while preserving connection order
- test/tools/auth0/handlers/connections.tests.js: implement test to validate pool usage for enabled clients
feat(clients.tests.js): implement tests for CIMD client creation and updates
- src/tools/auth0/handlers/clients.ts: added external_client_id, external_metadata_type, external_metadata_created_by, jwks_uri fields
- src/tools/auth0/handlers/clients.ts: implemented createClient and updateClient methods for CIMD clients
- test/tools/auth0/handlers/clients.tests.js: added tests for creating and updating CIMD clients
- test/tools/auth0/handlers/clients.tests.js: added validation test for external_metadata_type without external_client_id
- src/tools/auth0/handlers/clients.ts: replace omit with pick to specify editable fields
- src/tools/auth0/handlers/clients.ts: add new editable fields for CIMD clients
@kushalshit27 kushalshit27 requested a review from a team as a code owner April 22, 2026 05:01
… client change calculations

feat(src/tools/auth0/handlers/clients.ts): update identifiers for client handling
@codecov-commenter
Copy link
Copy Markdown

codecov-commenter commented Apr 22, 2026

Codecov Report

❌ Patch coverage is 80.64516% with 6 lines in your changes missing coverage. Please review.
✅ Project coverage is 79.75%. Comparing base (d68b6da) to head (80b21d0).

Files with missing lines Patch % Lines
src/tools/auth0/handlers/clients.ts 80.00% 2 Missing and 4 partials ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master    #1369      +/-   ##
==========================================
- Coverage   79.75%   79.75%   -0.01%     
==========================================
  Files         153      153              
  Lines        6969     6998      +29     
  Branches     1525     1530       +5     
==========================================
+ Hits         5558     5581      +23     
- Misses        781      783       +2     
- Partials      630      634       +4     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Comment thread src/tools/auth0/handlers/clients.ts Outdated
@ankita10119 ankita10119 marked this pull request as draft April 23, 2026 10:30
@ankita10119 ankita10119 marked this pull request as ready for review April 23, 2026 12:09
@ankita10119 ankita10119 self-requested a review April 23, 2026 12:16
@ankita10119 ankita10119 merged commit 70fa163 into master Apr 23, 2026
9 checks passed
@ankita10119 ankita10119 deleted the DXCDT-1515-cimd-manual-registration branch April 23, 2026 13:28
@ankita10119 ankita10119 mentioned this pull request Apr 23, 2026
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.

4 participants