Skip to content

feat: add ProviderType classification and JSONC support for providers#406

Merged
manojbajaj95 merged 1 commit into
mainfrom
feature/provider-type-classification
Jun 10, 2026
Merged

feat: add ProviderType classification and JSONC support for providers#406
manojbajaj95 merged 1 commit into
mainfrom
feature/provider-type-classification

Conversation

@manojbajaj95

Copy link
Copy Markdown
Collaborator

Summary

  • Adds ProviderType enum (app, llm, mcp) to enums.py and exports it from the top-level package
  • Adds optional type: ProviderType | None field to ProviderDefinition (optional so existing custom providers without the field remain valid)
  • Backfills "type" on all 71 bundled provider JSONs: openai and google-vertex-ai"llm", everything else → "app"
  • Adds parse_jsonc() to utils.py — regex-based comment stripper (no new dependency) that handles // line comments and /* */ block comments while preserving string literals
  • Updates provider_repository.py to load both .json and .jsonc bundled files via parse_jsonc
  • Updates authsome provider register CLI command to use parse_jsonc (accepts both .json and .jsonc files)
  • Updates docs/register-provider.md: mentions .jsonc support, adds type field to both templates and the field reference table

Closes #362

Test plan

  • uv run pytest — all 340 tests pass
  • uv run ruff check src/ tests/ — no issues
  • uv run ty check src/ — no issues
  • Verify authsome provider list shows providers loaded correctly with the type field
  • Verify authsome provider register my-provider.jsonc parses a JSONC file with comments

🤖 Generated with Claude Code

Adds a `type` field (app | llm | mcp) to ProviderDefinition so consumers
can filter and display providers by category. Backfills all 71 bundled
providers. Also introduces a `parse_jsonc` utility that strips // and /* */
comments before JSON parsing, and wires it into the bundled loader and the
CLI register command so both .json and .jsonc provider files are accepted.

Closes #362

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@manojbajaj95 manojbajaj95 merged commit dfabe6c into main Jun 10, 2026
5 checks passed
@manojbajaj95 manojbajaj95 deleted the feature/provider-type-classification branch June 10, 2026 06:05
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.

feat: classify bundled providers by type (MCP servers, LLMs, apps)

1 participant