llama-stack-mirror/tests/integration/providers/test_providers.py
Charlie Doern 520b55073a feat: add provider API for listing and inspecting provider info
currently the `inspect` API for providers is really a `list` API. Create a new `providers` API which has a GET `providers/{provider_id}` inspect API
which returns "user friendly" configuration to the end user. Also add a GET `/providers` endpoint which returns the list of providers as `inspect/providers` does today.

This API follows CRUD and is more intuitive/RESTful.

This work is part of the RFC at #1359

Signed-off-by: Charlie Doern <cdoern@redhat.com>
2025-03-13 17:40:28 -04:00

17 lines
554 B
Python

# Copyright (c) Meta Platforms, Inc. and affiliates.
# All rights reserved.
#
# This source code is licensed under the terms described in the LICENSE file in
# the root directory of this source tree.
import pytest
from llama_stack_client import LlamaStackClient
from llama_stack import LlamaStackAsLibraryClient
class TestProviders:
@pytest.mark.asyncio
def test_list(self, llama_stack_client: LlamaStackAsLibraryClient | LlamaStackClient):
provider_list = llama_stack_client.providers.list()
assert provider_list is not None