type Tag @model @auth(rules: [{allow: public, operations: [read]}]) { """Id generated by database""" id: ID! """Tag name - without the hashtag""" name: String! """Relationship representing a Course's tags""" courses: [Course] @manyToMany(relationName: "CourseTag") } type SocialMediaLink { """The enum represneting the social media platform""" platform: SocialMediaPlatform! """Social media URL""" url: AWSURL! } enum SocialMediaPlatform { INSTAGRAM LINKEDIN FACEBOOK GITHUB TWITTER TWITCH YOUTUBE DISCORD } enum SkillLevel { BEGINNER INTERMEDIATE ADVANCED } type Contributor @model @auth(rules: [{allow: public, operations: [read]}]) { """ID generated by database""" id: ID! """Contributor's job title""" jobTitle: String! """Contributor's social media links""" socialNetwork: [SocialMediaLink] """Relationship representing a contributor's courses""" courses: [Course] @manyToMany(relationName: "ContributorCourse") """String bio for Contributor""" bio: String! """URL or relative path string for contributor's profile picture""" profilePic: String! """ Contributor's username that is used for the URL/path. This is to help with contributors who might have the same name so the username should be unique """ username: String! """Contributor's last name. This is displayed on their bio page""" lastName: String! """Contributor's first name. This is displayed on their bio page""" firstName: String! } type Lesson @model @auth(rules: [{allow: public, operations: [read]}]) { """ID generated by the database""" id: ID! """Lesson title""" title: String! """Markdown content for the lesson""" content: String! """ YouTube embed ID for the lesson. Can be found in the url or from the 'Share' link on the video's page """ youtubeEmbedId: String """Number representing what chapter the lesson belongs to""" chapter: Int! """Relationship representing the course that the lesson belongs to""" courseLesson: Course @hasOne """Number representing the order of the lesson within the Course""" lessonNumber: Int! """Meta description for lesson""" description: String! } type Course @model @auth(rules: [{allow: public, operations: [read]}]) { """ID generated by the database""" id: ID! """Course title""" title: String! """The estimated number of hours the course will take to complete""" timeHours: Int! """The estimated number of remaining minutes the course will take to complete""" timeMinutes: Int! """ The learning objective of the course. Can be markdown and is only shown on the course overview page. """ learningObjective: String! """ Short summary in plain text of the course. This property is shown on the course card """ description: String! """Array of plain text describing the requirements to take the course""" requirements: [String!] """URL or relative path string for the course's picture""" image: String! """Relationship representing the contributors who created the course""" contributors: [Contributor] @manyToMany(relationName: "ContributorCourse") """Relationship of the course's tags""" courseTags: [Tag] @manyToMany(relationName: "CourseTag") """Course's skill level""" skillLevel: SkillLevel! """Date when course was created""" dateCreated: AWSDateTime! """ Boolean to denote if the course should be featured on the home page. There should only be one featured at a time. """ isFeatured: Boolean! imageAltText: String """ YouTube embed ID for the course's trailer. Can be found in the url or from the 'Share' link on the video's page """ trailerEmbedId: String courseUrlTitle: String! published: Boolean }