Course Listings
Course Listings
Abschnitt betitelt „Course Listings“A CourseListing (Kursausschreibung) is the public-facing announcement of one or more courses on a ListingPlatform (Ausschreibungsplattform). The listing controls what anonymous visitors see on your website — name, description, hero image, availability window, and whether successful enrollment should auto-book a participant or only create a registration.
Courses themselves are not public. A course becomes visible only through the listing it is linked to.
ListingPlatform ──has many──▶ CourseListing ──has many──▶ CourseCreate a Course Listing
Abschnitt betitelt „Create a Course Listing“Mutation
Abschnitt betitelt „Mutation“mutation CreateCourseListing( $courseListing: CourseListingCreateInput! $parentID: ID) { createCourseListing(courseListing: $courseListing, parentID: $parentID) { status message id courseListing { id name urlSlug showOnlineFrom showOnlineTo } }}input CourseListingCreateInput { "Display name — 2 to 255 characters" name: String
"Plain-text description, up to 1000 characters" description: String
"Rich HTML description (no length limit)" descriptionHtml: String
"Hero image URL, up to 500 characters" imageUrl: String
"Window in which the listing is shown to visitors" showOnlineFrom: Date showOnlineTo: Date
"When true: successful enrollment immediately books a CourseParticipant if seats are available. When false: only a CourseRegistration is created and staff confirms manually." autoCreateCourseParticipant: Boolean
"UID of the ListingPlatform this listing belongs to" listingPlatformID: ID
"Slug used in the public URL: /listing/<urlSlug>" urlSlug: String
isActive: Boolean
# ...plus all BaseObjectInput fields (remarks, validFrom, validTo, ...)}Minimal variables
Abschnitt betitelt „Minimal variables“{ "parentID": "b0b0cafe-...-01", "courseListing": { "name": "Italienischkurse — Frühling 2026", "description": "Einstiegskurse Italienisch A1 und A2, Start im Mai.", "showOnlineFrom": "2026-03-01", "showOnlineTo": "2026-05-03", "autoCreateCourseParticipant": false, "listingPlatformID": "b0b0cafe-...-01", "urlSlug": "italienischkurse-fruehling-2026", "isActive": true }}Link Courses to a Listing
Abschnitt betitelt „Link Courses to a Listing“Courses are attached through the join entity CourseListingCourse. Use saveCourseListingCourse to create (no id) or update (with id) the link:
mutation SaveCourseListingCourse($input: CourseListingCourseInput!) { saveCourseListingCourse(input: $input) { status message courseListingCourse { id isActive orderNr } }}input CourseListingCourseInput { "Omit to create a new link; provide to update an existing one." id: Int
"Target listing. Optional when the server can infer it from context." courseListingId: ID
"Course to attach. Required." courseId: ID!
"Override course fee on this listing only (in CHF)" overridePrice: Decimal
"Override listing-level visibility window" overrideShowOnlineFrom: Date overrideShowOnlineTo: Date
"Display order on the listing page" orderNr: Int
isActive: Boolean = true}Example: attach a course
Abschnitt betitelt „Example: attach a course“{ "input": { "courseListingId": "aa11bb22-...-33", "courseId": "4a9e2c17-...-b3", "overridePrice": "480.00", "orderNr": 1, "isActive": true }}Remove a course from a listing
Abschnitt betitelt „Remove a course from a listing“mutation { deleteCourseListingCourse(id: 42) { status message }}The link is removed; the course itself is untouched.
Update / Delete a Listing
Abschnitt betitelt „Update / Delete a Listing“mutation UpdateCourseListing($id: ID!, $courseListing: CourseListingUpdateInput!) { updateCourseListing(id: $id, courseListing: $courseListing) { status message }}
mutation DeleteCourseListing { deleteCourseListing(id: "aa11bb22-...-33") { status message }}Listing Platforms
Abschnitt betitelt „Listing Platforms“A ListingPlatform groups listings — typically one per public website, school site or brand. Platforms are created through the standard CRUD mutations:
mutation CreateListingPlatform( $listingPlatform: ListingPlatformCreateInput! $parentID: ID) { createListingPlatform(listingPlatform: $listingPlatform, parentID: $parentID) { status message id listingPlatform { id name isDefault } }}input ListingPlatformCreateInput { name: String description: String "Marks this platform as the default when a course listing omits platformGuid" isDefault: Boolean # ...plus all BaseObjectInput fields}Public Query: fetch a listing’s course
Abschnitt betitelt „Public Query: fetch a listing’s course“The public website renders a listing by its course GUID. This query is public (@Authorized({ authType: 'Public' })), returns only the fields a visitor should see, and is safe to call from a browser:
query PublicCourse($guid: String!) { publicCourse(guid: $guid) { GUID name siteName descriptionHtml imageUrl startAt finishAt price objectTypeName isSignedUp autoCreateCourseParticipant availability { placesTotal placesAvailable placesWaiting } }}Pair this with publicEnrollToCourse to build a full public sign-up flow.
Auto-Create Participant Behaviour
Abschnitt betitelt „Auto-Create Participant Behaviour“The autoCreateCourseParticipant flag on CourseListing (and the live value surfaced on PublicCourse) governs what happens after a successful public enrollment:
| Value | Result |
|---|---|
false | Create a CourseRegistration. Staff reviews and books manually (Buchen) → CourseParticipant. |
true | If seats are available, immediately create a CourseParticipant (in addition to the registration). |
Use true for low-touch courses with instant confirmation; use false whenever staff needs to validate each registration (limited capacity, prerequisites, payment up-front, …).
Related
Abschnitt betitelt „Related“- Courses — the operational course entity
- Public Enrollment — consume a listing from a public form