Я ищу какое -то решение или, может быть, какой -то скрипт, который может помочь мне заменить ($ ref) или расширить его определения в файле YML с помощью проверки схемы. (Для получения подробной информации, пожалуйста, найдите пример ниже) < /p>
** Пример: ввод с $ ref ** < /p>
Я ищу какое -то решение или, может быть, какой -то скрипт, который может помочь мне заменить ($ ref) или расширить его определения в файле YML с помощью проверки схемы. (Для получения подробной информации, пожалуйста, найдите пример ниже) < /p> ** Пример: ввод с $ ref ** < /p> [code] /pets/{petId}: get: summary: Info for a specific pet operationId: showPetById tags: - pets parameters: - name: petId in: path required: true description: The id of the pet to retrieve schema: type: string responses: '200': description: Expected response to a valid request content: application/json: schema: $ref: "#/components/schemas/Pet" default: description: unexpected error content: application/json: schema: $ref: "#/components/schemas/Error" components: schemas: Pet: type: object required: - id - name properties: id: type: integer format: int64 name: type: string tag: type: string Pets: type: array items: $ref: "#/components/schemas/Pet" Error: type: object required: - code - message properties: code: type: integer format: int32 message: type: string [/code] [b] output: all $ ref Заменяет или расширен до его определения (с проверкой схемы) [/b] [code] /pets/{petId}: get: summary: Info for a specific pet operationId: showPetById tags: - pets parameters: - name: petId in: path required: true description: The id of the pet to retrieve schema: type: string responses: '200': description: Expected response to a valid request content: application/json: schema: type: object required: - id - name properties: id: type: integer format: int64 name: type: string tag: type: string
Я ищу какое -то решение или, может быть, какой -то скрипт, который может помочь мне заменить ($ ref) или расширить его определения в файле YML с помощью проверки схемы. (Для получения подробной информации, пожалуйста, найдите пример ниже)
**...
Я ищу какое-то решение или, возможно, какой-нибудь скрипт, который поможет мне заменить ($ref) или расширить его определения в файле YML с проверкой схемы. (Подробнее см. в примере ниже)
**Пример: ввод с помощью $ref **
/pets/{petId}:
get:
summary:...
Учитывая следующий класс:
public record Response
{
public ImmutableList? Completes { get; init; } = null;
public ImmutableList? Incompletes { get; init; } = null;