raml-spec icon indicating copy to clipboard operation
raml-spec copied to clipboard

Create a dictionary Type which is using custom Types already defined

Open vayias opened this issue 10 years ago • 2 comments

So let's say I have TypeA which is a string and TypeB which is an object.

I want to define Type3 which is a dictionary with key TypeA and value TypeB. It's not clear how to do that in the documentation.

vayias avatar Apr 08 '16 08:04 vayias

@sichvoge +1, I also need this

sashabaranov avatar Apr 27 '17 12:04 sashabaranov

The best I came up with:

types:
  Value:
    properties: 
      name: TypeA
      value: TypeB
  Type3:
    type: Value[]
      

sashabaranov avatar Apr 27 '17 12:04 sashabaranov