Question regarding raml structure #380

Closed
opened 2025-12-29 08:27:11 +01:00 by adam · 1 comment
Owner

Originally created by @mcheguini on GitHub (Oct 27, 2021).

Hello Stef,

I would like to say thank you for this amazing framework, and your support (:
I am trying to use raml file in WireMock and I am not able to use some capabilities inside the WireMock.NET
I understand you implemented “RamlToOpenApiConverter. and “ConvertToOpenApiDocument” is used to convert raml to OpenAPI
I tried to use “ConvertToOpenApiDocument” and “ConvertToFile” for following example code (it is attached for your kind review)
regarding the mentioned fact, is it possible to use following capabilities in WireMock.NET?

  • Uses (uses can be mocked into the .json file?)
  • Traits (can be converted in .json format?, can I use is: to select an specific trait i.e "is: sometrait" in body?)
  • Is it possible to use "ExactMatcher" WildCard in raml file for post body request?
  • securitySchemes (it will not appear in .json file)
  • example: !include Email_Request_Example.json (I am not able to include .json file)

I was able to use the following json schema as example in raml file, but the problem is each example should be placed in separate .json file (there are a lot of .json example files).
Example: |
{
Some json data
}
Could you please help me to solve previously mentioned inquiries specially with "example: !include examplefile.json"

Also I found, having nested !include will cause an error, for example

types:
  ParentVar: !Parent.raml

in Parent.raml

#%RAML 1.0
type: object
properties:
  somefield:
    type: array
    items: !include child.raml

In mentioned "items: !include child.raml" will cause an error

Originally created by @mcheguini on GitHub (Oct 27, 2021). Hello Stef, I would like to say thank you for this amazing framework, and your support (: I am trying to use raml file in WireMock and I am not able to use some capabilities inside the WireMock.NET I understand you implemented “RamlToOpenApiConverter. and “ConvertToOpenApiDocument” is used to convert raml to OpenAPI I tried to use “ConvertToOpenApiDocument” and “ConvertToFile” for following example code (it is attached for your kind review) regarding the mentioned fact, is it possible to use following capabilities in WireMock.NET? - Uses (uses can be mocked into the .json file?) - Traits (can be converted in .json format?, can I use is: to select an specific trait i.e "is: sometrait" in body?) - Is it possible to use "ExactMatcher" WildCard in raml file for post body request? - securitySchemes (it will not appear in .json file) - example: !include Email_Request_Example.json (I am not able to include .json file) I was able to use the following json schema as example in raml file, but the problem is each example should be placed in separate .json file (there are a lot of .json example files). Example: | { Some json data } Could you please help me to solve previously mentioned inquiries specially with "example: !include examplefile.json" Also I found, having nested !include will cause an error, for example ``` types: ParentVar: !Parent.raml ``` **in Parent.raml** ``` #%RAML 1.0 type: object properties: somefield: type: array items: !include child.raml ``` In mentioned "items: !include child.raml" will cause an error
adam added the question label 2025-12-29 08:27:11 +01:00
adam closed this issue 2025-12-29 08:27:12 +01:00
Author
Owner

@StefH commented on GitHub (Oct 29, 2021):

https://github.com/StefH/RamlToOpenApiConverter/issues/8

@StefH commented on GitHub (Oct 29, 2021): https://github.com/StefH/RamlToOpenApiConverter/issues/8
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/WireMock.Net#380