Skip to content

.Net: Map OpenAPI parameter type to KernelParameterMetadata - #8198

Merged
SergeyMenshykh merged 5 commits into
microsoft:mainfrom
SergeyMenshykh:open-api-parameter-type-mapping
Aug 16, 2024
Merged

SergeyMenshykh merged 5 commits into
microsoft:mainfrom
SergeyMenshykh:open-api-parameter-type-mapping

Conversation

@SergeyMenshykh

@SergeyMenshykh SergeyMenshykh commented Aug 16, 2024 •

Copy link
Copy Markdown
Contributor

Motivation, Context and Description

Today, the OpenAPI functionality that maps the data type of a parameter from the OpenAPI spec to KernelParameterMetadata supports only the mapping for string and boolean types. This PR extends the mapping to support other primitive types like number, integer, and object.

Closes: #8087

Out of scope:

  • Support for the array data type.

@SergeyMenshykh SergeyMenshykh added .NET Issue or Pull requests regarding .NET code openapi Issues related to the OpenAPI function importer labels Aug 16, 2024
@SergeyMenshykh SergeyMenshykh self-assigned this Aug 16, 2024
@SergeyMenshykh
SergeyMenshykh requested a review from a team as a code owner August 16, 2024 16:43
@SergeyMenshykh
SergeyMenshykh added this pull request to the merge queue Aug 16, 2024
Merged via the queue into microsoft:main with commit 184c7c0 Aug 16, 2024
@SergeyMenshykh
SergeyMenshykh deleted the open-api-parameter-type-mapping branch August 16, 2024 18:27
LudoCorporateShark pushed a commit to LudoCorporateShark/semantic-kernel that referenced this pull request Aug 25, 2024
…t#8198)

### Motivation, Context and Description
Today, the OpenAPI functionality that maps the data type of a parameter
from the OpenAPI spec to `KernelParameterMetadata` supports only the
mapping for string and boolean types. This PR extends the mapping to
support other primitive types like `number`, `integer`, and `object`.

Closes: microsoft#8182

Out of scope:
- Support for the `array` data type.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

.NET Issue or Pull requests regarding .NET code openapi Issues related to the OpenAPI function importer

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

.Net: Bug: OpenAIFunctionParameter.ParameterType is null for integer and number types

4 participants