Inconsistent data type rendering
The representation of data types is inconsistent for path parameters and response objects:
In the following sample OpenAPI, a path parameter and a response object property are both defined with type:integer and format:int64.
Sample OpenAPI:
openapi: 3.0.1
info:
title: demo
version: 0.0.1
paths:
/service/{id}:
get:
parameters:
- name: id
in: path
required: true
schema:
type: integer
format: int64
responses:
200:
description: response
content:
application/json:
schema:
type: object
properties:
id:
type: integer
format: int64
While Rapidoc renders "int64" for the path parameters (which seems fine as int64 implies integer type), it shows "integer" for the response object property (see the following screenshot, type information marked green):
This is confusing, as the user will assume that the parameter and property have different data types, which is not the case. Data type information should be rendered uniformly including format details in all places.
We're seeing a similar issue where the type is "string" and the format is "decimal" in which Rapidocs renders the schema as a "decimal" rather than "string".
For example, we have the following schema defined:
RequestedQuantity:
type: string
format: decimal
multipleOf: 0.001
minimum: -9999999999.999
maximum: 9999999999.999
example: '0'
title: Target Quantity
This is misleading and confusing to the API consumer as it makes it appear that the field takes a number and developer don't end up wrapping the value in quotes to make it a string.
We're using version 9.3.8 of the Rapidoc library.