Embed an array of objects with the latest template examples

Hey, im using this Template to build my app upon. The only problem is, that i need an array of objects in my schema, which i can’t seem to get working.
My mongoDB schema looks like this:

  "title": "Media",
  "properties": {
    "_id": {
      "bsonType": "objectId"
    },
    "access": {
      "bsonType": "array",
      "items": {
        "bsonType": "string"
      }
    },
    "collectionType": {
      "bsonType": "string"
    },
    "media": {
      "bsonType": "array",
      "items": {
        "bsonType": "object",
        "name": "Media_media",
        "properties": {
          "author": {
            "bsonType": "string"
          },
          "createdAt": {
            "bsonType": "string"
          },
          "genre": {
            "bsonType": "string"
          },
          "language": {
            "bsonType": "string"
          },
          "length": {
            "bsonType": "int"
          },
          "link": {
            "bsonType": "string"
          },
          "mediaName": {
            "bsonType": "string"
          },
          "note": {
            "bsonType": "string"
          },
          "releaseDate": {
            "bsonType": "string"
          },
          "type": {
            "bsonType": "string"
          }
        }
      }
    },
    "userId": {
      "bsonType": "string"
    }
  }
}

I would appreciate any help

Hello @Silas_Jeydo ,

I notice you haven’t had a response to this topic yet - were you able to find a solution?
If not, could you please provide me with below details to help me understand your use-case?

  • Sample Document
  • Are you facing any errors?
  • Expected output

Regards,
Tarun