Enrollments

English only

Use Cases

Enrollments in Pluvo are processed through an OfferEvent. A user does not enroll directly in a training, but in a specific entry moment within an offering. In this API documentation, you'll see how to enroll users, unenroll them, and retrieve enrollment information.

Check enrollment status

Check if a user is enrolled in a specific event, including status and date.

query {
  enrollment(userId: "uuid-user", offerEventId: "uuid-event") {
    id
    status
    enrolledAt
  }
}

List all enrollments for user

Provides an overview of all events for which a user is enrolled.

query {
  enrollments(userId: "uuid-user") {
    id
    offerEvent {
      id
      title
    }
    status
  }
}

Enroll user in event

Enrolls a user in a specific offer-event. You can optionally specify the status directly (ENROLLED, WAITLISTED, etc.).

mutation {
  enrollUserInOfferEvent(
    enrollment: {
      userId: "uuid-user"
      offerEventId: "uuid-event"
      status: ENROLLED
    }
  ) {
    enrollment {
      id
      status
    }
  }
}

Unenroll / cancel

Removes an enrollment or changes the status to CANCELLED.

mutation {
  unenrollUserFromOfferEvent(
    userId: "uuid-user"
    offerEventId: "uuid-event"
  ) {
    success
  }
}

GraphQL Definitions

Type: Enrollment

Provides the enrollment status of a user for a specific event.

type Enrollment {
  id: ID!
  userId: ID!
  offerEventId: ID!
  status: EnrollmentStatus!
  enrolledAt: DateTime!
}

Enum: EnrollmentStatus

enum EnrollmentStatus {
  ENROLLED
  WAITLISTED
  CANCELLED
  DECLINED
}

Queries

enrollment(userId: UUID!, offerEventId: UUID!): Enrollment
enrollments(userId: UUID): [Enrollment!]!

Mutations

enrollUserInOfferEvent(enrollment: EnrollUserInput!): EnrollUserPayload
unenrollUserFromOfferEvent(userId: UUID!, offerEventId: UUID!): UnenrollUserPayload

Notes

  • Status WAITLISTED is used when the event is full but a waitlist is active.
  • CANCELLED and DECLINED distinguish between active and passive cancellation.
  • For updates to existing enrollments (e.g., status changes), there is no separate mutation — enroll again with the modified status.
Close notification