Hello Sergio,
we use your OpenApi generator (version from May 2023) as it was part of sgcWebSockets.
Now we have a new project and identified a problem with an OpenAPI specification:
https://rksv.fiskaly.com/api/v1/_spec.json
It generates code successfully, but there are some parts missing.
For example it generates the following class:
TsgcOpenAPI_CreateSignatureCreationUnitRequest_Class = class(TsgcOpenAPIClass)
private
[sgcAdditionalProperties]
Fmetadata: TsgcOpenAPI_MetadataRequest_Class;
Flegal_entity_id: String;
Flegal_entity_name: string;
public
class function Read(const aValue: string): TsgcOpenAPI_CreateSignatureCreationUnitRequest_Class;
public
property Metadata: TsgcOpenAPI_MetadataRequest_Class read Fmetadata write Fmetadata;
property Legal_entity_id: String read Flegal_entity_id write Flegal_entity_id;
property Legal_entity_name: string read Flegal_entity_name write Flegal_entity_name;
end;
As I understand the spec, the property
Legal_entity_id should be a class instead of a string.
...
"VatId": {
"type": "object",
"properties": {
"vat_id": {
"type": "string",
"description": "A value added tax identification number (e.g. \"ATU73948115\") is an identifier used for value added tax purposes.",
"pattern": "^ATU\\d{8}$",
"example": "ATU73948115"
}
},
"required": [
"vat_id"
],
"additionalProperties": false
},
"TaxId": {
"type": "object",
"properties": {
"tax_id": {
"type": "string",
"pattern": "^\\d{2}[ -]?\\d{3}\\/?\\d{4}$",
"description": "The \"Steuernummer\" is a unique identifier (e.g. \"04-999/9048\") provided by the financial authorities.",
"example": "04-999/9048"
}
},
"required": [
"tax_id"
],
"additionalProperties": false
},
"Gln": {
"type": "object",
"properties": {
"gln": {
"type": "string",
"pattern": "^\\d{13}$",
"description": "The Global Location Number (GLN) is a unique identifier provided by Bundesanstalt Statistik Österreich.",
"example": "1234567890123"
}
},
"required": [
"gln"
],
"additionalProperties": false
},
"LegalEntityId": {
"description": "A unique identifier of the legal entity that operates the Signature Creation Unit.",
"oneOf": [
{
"$ref": "#/components/schemas/VatId"
},
{
"$ref": "#/components/schemas/TaxId"
},
{
"$ref": "#/components/schemas/Gln"
}
]
},
"LegalEntityName": {
"type": "string",
"description": "The name of the legal entity that is bound to the Signature Creation Unit."
},
"CreateSignatureCreationUnitRequest": {
"type": "object",
"properties": {
"metadata": {
"$ref": "#/components/schemas/MetadataRequest"
},
"legal_entity_id": {
"$ref": "#/components/schemas/LegalEntityId"
},
"legal_entity_name": {
"$ref": "#/components/schemas/LegalEntityName"
}
},
"required": [
"legal_entity_id"
],
"additionalProperties": false
},
...
I've tried your latest trial of the OpenApi generator, but it still can't handle the mentioned spec.
If you can fix this, we are willing to buy it.
Best regards,
Waldemar Derr