Skip to content

'apictl init' silently drops 'subtypeConfiguration' for AI APIs #5145

Description

@iloshinik

Description

'apictl init --definition --oas ' drops the 'subtypeConfiguration' block when regenerating a project from an AI API's exported definition. The regenerated 'api.yaml' is missing the field entirely, so the API is no longer recognized as an AI API on subsequent import. It is imported as a plain REST API as the AI configuration is stored under the 'subtypeConfiguration' block and it is missing in the api.yaml.

Steps to Reproduce

  1. Create an AI API.
  2. Export it and confirm the exported 'api.yaml' contains:
     subtypeConfiguration:
       subtype: AIAPI
       _configuration: "{...}"
  1. apictl init openai-test-api --definition <exported-api.yaml> --oas <exported-swagger.yaml>
  2. Inspect openai-test-api/api.yaml.
    Expected: 'subtypeConfiguration' is preserved in the generated api.yaml.
    Actual: 'subtypeConfiguration' is absent entirely.

Version

4.6.0

Environment Details (with versions)

No response

Metadata

Metadata

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions