feati(api): add connectors API

Closes #4235 and #4061 (partially)

Signed-off-by: Jaideep Rao <jrao@redhat.com>
This commit is contained in:
Jaideep Rao 2025-11-28 21:34:00 +05:30
parent 89807dc117
commit 8a5a56f166
11 changed files with 1977 additions and 0 deletions

View file

@ -8612,6 +8612,90 @@ components:
- chunk_id
title: Chunk
description: A chunk of content that can be inserted into a vector database.
Connector:
properties:
identifier:
type: string
title: Identifier
description: Unique identifier for this resource in llama stack
provider_resource_id:
anyOf:
- type: string
- type: 'null'
description: Unique identifier for this resource in the provider
provider_id:
type: string
title: Provider Id
description: ID of the provider that owns this resource
type:
type: string
const: connector
title: Type
default: connector
connector_type:
$ref: '#/components/schemas/ConnectorType'
default: mcp
connector_id:
anyOf:
- type: string
- type: 'null'
description: User-specified identifier for the connector
url:
type: string
title: Url
description: URL of the connector
created_at:
type: string
format: date-time
title: Created At
description: Timestamp of creation
updated_at:
type: string
format: date-time
title: Updated At
description: Timestamp of last update
server_name:
anyOf:
- type: string
- type: 'null'
description: Name of the server
server_label:
anyOf:
- type: string
- type: 'null'
description: Label of the server
server_description:
anyOf:
- type: string
- type: 'null'
description: Description of the server
tools:
anyOf:
- items:
$ref: '#/components/schemas/MCPListToolsTool'
type: array
- type: 'null'
description: List of tools available from the connector
registry_id:
anyOf:
- type: string
- type: 'null'
description: ID of the registry this connector belongs to
type: object
required:
- identifier
- provider_id
- url
- created_at
- updated_at
title: Connector
description: A connector resource representing a connector registered in Llama Stack.
ConnectorType:
type: string
enum:
- mcp
title: ConnectorType
description: Type of connector.
ConversationItemInclude:
type: string
enum:
@ -8702,6 +8786,42 @@ components:
- cancelled
title: JobStatus
description: Status of a job execution.
ListConnectorsResponse:
properties:
data:
items:
$ref: '#/components/schemas/Connector'
type: array
title: Data
type: object
required:
- data
title: ListConnectorsResponse
description: Response containing a list of connectors.
ListRegistriesResponse:
properties:
data:
items:
$ref: '#/components/schemas/Registry'
type: array
title: Data
type: object
required:
- data
title: ListRegistriesResponse
description: Response containing a list of registries.
ListToolsResponse:
properties:
data:
items:
$ref: '#/components/schemas/MCPListToolsTool'
type: array
title: Data
type: object
required:
- data
title: ListToolsResponse
description: Response containing a list of tools.
MCPListToolsTool:
properties:
input_schema:
@ -9094,6 +9214,63 @@ components:
required:
- reasoning_tokens
title: OutputTokensDetails
Registry:
properties:
identifier:
type: string
title: Identifier
description: Unique identifier for this resource in llama stack
provider_resource_id:
anyOf:
- type: string
- type: 'null'
description: Unique identifier for this resource in the provider
provider_id:
type: string
title: Provider Id
description: ID of the provider that owns this resource
type:
type: string
const: registry
title: Type
default: registry
registry_type:
$ref: '#/components/schemas/RegistryType'
default: mcp
user_registry_id:
anyOf:
- type: string
- type: 'null'
description: User-specified identifier for the registry
url:
type: string
title: Url
description: URL of the registry
created_at:
type: string
format: date-time
title: Created At
description: Timestamp of creation
updated_at:
type: string
format: date-time
title: Updated At
description: Timestamp of last update
type: object
required:
- identifier
- provider_id
- url
- created_at
- updated_at
title: Registry
description: A registry resource representing a registry of connectors.
RegistryType:
type: string
enum:
- mcp
title: RegistryType
description: Type of registry.
SearchRankingOptions:
properties:
ranker:
@ -9567,6 +9744,45 @@ components:
type: string
title: DialogType
type: object
RegistryInput:
description: Input for creating a registry.
properties:
url:
title: Url
type: string
user_registry_id:
anyOf:
- type: string
- type: 'null'
description: User-specified identifier for the registry
nullable: true
registry_type:
$ref: '#/components/schemas/RegistryType'
default: mcp
required:
- url
title: RegistryInput
type: object
ConnectorInput:
description: Input for creating a connector.
properties:
connector_type:
$ref: '#/components/schemas/ConnectorType'
default: mcp
connector_id:
anyOf:
- type: string
- type: 'null'
description: Unique identifier for the connector
nullable: true
url:
description: URL of the connector
title: Url
type: string
required:
- url
title: ConnectorInput
type: object
ConversationMessage:
description: OpenAI-compatible message item for conversations.
properties:
@ -9702,6 +9918,7 @@ components:
- files
- prompts
- conversations
- connectors
- inspect
title: Api
type: string