Creating an array of elements declared previously on enum


#1

I’m stuck in one point developing this RAML thing. In my included JSON to test the hierarchy of the RAML objects I need to construct like this:

"communicationWays": [
   {
     "SMS": false,
     "EMAIL": true,
     "VOICE": false,
     "MAIL": false
   }
 ]

But my question is: how can I implement it on RAML part?? I think about something like this…

types:
  communicationWays:
    type: array
      items:
        enum:
        - "SMS"
          # type of each element on enum
            type: boolean
        - "EMAIL"
          # type of each element on enum
            type: boolean
        - "VOICE"
          # type of each element on enum
            type: boolean
        - "MAIL"
          # type of each element on enum
            type: boolean

But, obviously, this is incorrect . I’m just try to explain the structure with the code. I tried to find out in the official RAML documentation but I couldn’t see this example case, nor I couldn’t find anything on forum. Can you help me, please, with this kind of structure?