feat: migrate Providers API to FastAPI router pattern (#4405)

# What does this PR do?

Convert Providers API from @webmethod decorators to FastAPI router
pattern.

Fixes: https://github.com/llamastack/llama-stack/issues/4350

<!-- Provide a short summary of what this PR does and why. Link to
relevant issues if applicable. -->

<!-- If resolving an issue, uncomment and update the line below -->
<!-- Closes #[issue-number] -->

## Test Plan
CI

Signed-off-by: Sébastien Han <seb@redhat.com>
This commit is contained in:
Sébastien Han 2025-12-17 16:55:05 +01:00 committed by GitHub
parent 722d9c53e7
commit cd5095a247
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
13 changed files with 287 additions and 121 deletions

View file

@ -3494,20 +3494,25 @@ components:
api:
type: string
title: Api
description: The API name this provider implements
provider_id:
type: string
title: Provider Id
description: Unique identifier for the provider
provider_type:
type: string
title: Provider Type
description: The type of provider implementation
config:
additionalProperties: true
type: object
title: Config
description: Configuration parameters for the provider
health:
additionalProperties: true
type: object
title: Health
description: Current health status of the provider
type: object
required:
- api
@ -3524,6 +3529,7 @@ components:
$ref: '#/components/schemas/ProviderInfo'
type: array
title: Data
description: List of provider information objects
type: object
required:
- data
@ -10703,6 +10709,17 @@ components:
- logger_config
title: PostTrainingRLHFRequest
type: object
InspectProviderRequest:
description: Request model for inspecting a provider by ID.
properties:
provider_id:
description: The ID of the provider to inspect.
title: Provider Id
type: string
required:
- provider_id
title: InspectProviderRequest
type: object
responses:
BadRequest400:
description: The request was invalid or malformed