Skip to main content

CalendarsAppointmentsResource

Struct CalendarsAppointmentsResource 

Source
pub struct CalendarsAppointmentsResource<'a> { /* private fields */ }
Expand description

client.calendars().appointments()

Implementations§

Source§

impl<'a> CalendarsAppointmentsResource<'a>

Source

pub fn meeting_requests( &self, ) -> CalendarsAppointmentsMeetingRequestsResource<'a>

Source

pub fn templates(&self) -> CalendarsAppointmentsTemplatesResource<'a>

Source

pub fn change_impact( &self, calendar_id: impl Display, appointment_id: impl Display, body: &AppointmentChangeImpactCreate, ) -> Result<Vec<Value>>

Preview impacts of an appointment schedule change

POST /calendars/{calendarId}/appointments/{appointmentId}/changeimpact

Calculates supported event, service-assignment and resource-booking impacts of the proposed schedule without saving the appointment.

§Example
let body = models::AppointmentChangeImpactCreate {
    end_date: DateOrDateTime::DateTime("2026-09-20T09:30:00Z".parse()?),
    start_date: DateOrDateTime::DateTime("2026-09-20T08:00:00Z".parse()?),
    ..Default::default()
};
for appointment in client.calendars().appointments().change_impact(42, 4, &body)? {
    println!("{:?}", appointment);
}
Source

pub fn create( &self, calendar_id: impl Display, body: &AppointmentCreate, ) -> Result<AppointmentBase>

Create an appointment or series

POST /calendars/{calendarId}/appointments

Creates a calendar appointment, with optional recurrence, resource reservations, service-planning events and meeting invitations. calendarId comes from the path. Creating registration groups and linked resources requires the corresponding permissions.

§Example
let body = models::AppointmentCreate {
    end_date: DateOrDateTime::DateTime("2026-09-20T09:30:00Z".parse()?),
    start_date: DateOrDateTime::DateTime("2026-09-20T08:00:00Z".parse()?),
    is_internal: true,
    title: "Sunday service".into(),
    ..Default::default()
};
let result = client.calendars().appointments().create(42, &body)?;
println!("{}", result.title);
Source

pub fn delete( &self, calendar_id: impl Display, appointment_id: impl Display, ) -> Result<()>

Delete an appointment or entire series

DELETE /calendars/{calendarId}/appointments/{appointmentId}

Deletes the stored appointment and triggers the cleanup of linked resources. For recurring appointments this removes the whole series. To remove only one occurrence, update the complete series with that local date in exceptions. This requires calendar editing permission or being the appointment’s last editor.

§Example
client.calendars().appointments().delete(42, 4)?;
Source

pub fn get( &self, calendar_id: impl Display, appointment_id: impl Display, ) -> Result<AppointmentCalculated>

Get an appointment series and its dates

GET /calendars/{calendarId}/appointments/{appointmentId}

Returns the stored appointment and all dates calculated from its recurrence settings. calculatedDates is keyed by local start date and contains UTC start/end timestamps even for all-day appointments. This differs from the date-or-timestamp format used by occurrence endpoints.

Use Self::get_with to pass query parameters.

§Example
let appointment = client.calendars().appointments().get(42, 4)?;
println!("{:?}", appointment);
Source

pub fn get_with( &self, calendar_id: impl Display, appointment_id: impl Display, query: &GetCalendarsCalendarIdAppointmentsAppointmentIdQuery, ) -> Result<AppointmentCalculated>

Get an appointment series and its dates

Like Self::get, with query parameters.

GET /calendars/{calendarId}/appointments/{appointmentId}

Returns the stored appointment and all dates calculated from its recurrence settings. calculatedDates is keyed by local start date and contains UTC start/end timestamps even for all-day appointments. This differs from the date-or-timestamp format used by occurrence endpoints.

Source

pub fn get_ical( &self, calendar_id: impl Display, appointment_id: impl Display, ) -> Result<Vec<u8>>

Export an appointment or series as iCalendar

GET /calendars/{calendarId}/appointments/{appointmentId}/ical

Downloads appointment.ics as text/calendar. The export includes recurrence rules, excluded dates and additional dates; it may contain multiple VEVENT entries for additional recurring or standalone dates. This exports the stored appointment/series, not a selected occurrence.

§Example
let data = client.calendars().appointments().get_ical(42, 4)?;
std::fs::write("ergebnis.ics", &data)?;
Source

pub fn get_occurrence( &self, appointment_id: impl Display, start_date: impl Display, ) -> Result<AppointmentOccurrence>

Get one appointment occurrence

GET /calendars/appointments/{appointmentId}/{startDate}

Returns the occurrence starting on the specified local date. appointment.base describes the stored series and appointment.calculated describes this occurrence. Returns 404 if no matching occurrence is available.

Use Self::get_occurrence_with to pass query parameters.

§Example
let occurrence = client.calendars().appointments().get_occurrence(4, "2026-09-20")?;
println!("{:?}", occurrence.title_suffix);
Source

pub fn get_occurrence_with( &self, appointment_id: impl Display, start_date: impl Display, query: &GetCalendarsAppointmentsAppointmentIdStartDateQuery, ) -> Result<AppointmentOccurrence>

Get one appointment occurrence

Like Self::get_occurrence, with query parameters.

GET /calendars/appointments/{appointmentId}/{startDate}

Returns the occurrence starting on the specified local date. appointment.base describes the stored series and appointment.calculated describes this occurrence. Returns 404 if no matching occurrence is available.

Source

pub fn get_occurrence_in_calendar( &self, calendar_id: impl Display, appointment_id: impl Display, start_date: impl Display, ) -> Result<AppointmentOccurrence>

Get one appointment occurrence

GET /calendars/{calendarId}/appointments/{appointmentId}/{startDate}

Returns the occurrence starting on the specified local date. appointment.base describes the stored series and appointment.calculated describes this occurrence. Returns 404 if no matching occurrence is available.

Use Self::get_occurrence_in_calendar_with to pass query parameters.

§Example
let occurrence_in_calendar = client.calendars().appointments().get_occurrence_in_calendar(42, 4, "2026-09-20")?;
println!("{:?}", occurrence_in_calendar.title_suffix);
Source

pub fn get_occurrence_in_calendar_with( &self, calendar_id: impl Display, appointment_id: impl Display, start_date: impl Display, query: &GetCalendarsCalendarIdAppointmentsAppointmentIdStartDateQuery, ) -> Result<AppointmentOccurrence>

Get one appointment occurrence

Like Self::get_occurrence_in_calendar, with query parameters.

GET /calendars/{calendarId}/appointments/{appointmentId}/{startDate}

Returns the occurrence starting on the specified local date. appointment.base describes the stored series and appointment.calculated describes this occurrence. Returns 404 if no matching occurrence is available.

Source

pub fn list( &self, query: &GetCalendarsAppointmentsQuery, ) -> Result<Vec<AppointmentOccurrenceList>>

List appointment occurrences across calendars

GET /calendars/appointments

Returns calculated occurrences for the requested date range, with one entry per occurrence rather than per series. Use appointment.base for the stored series and appointment.calculated for the displayed dates. Recurring occurrences use the installation’s local time across daylight-saving changes. Anonymous users receive only non-internal appointments in calendars they may view.

§Example
let query = GetCalendarsAppointmentsQuery {
    calendar_ids: Some(vec![2, 3]),
    ..Default::default()
};
for appointment in client.calendars().appointments().list(&query)? {
    println!("{:?}", appointment.title_suffix);
}
Source

pub fn list_in_calendar( &self, calendar_id: impl Display, ) -> Result<Vec<AppointmentOccurrenceList>>

List appointment occurrences in a calendar

GET /calendars/{calendarId}/appointments

Returns calculated occurrences for the requested date range, with one entry per occurrence rather than per series. Use appointment.base for the stored series and appointment.calculated for the displayed dates. Recurring occurrences use the installation’s local time across daylight-saving changes. Anonymous users receive only non-internal appointments in calendars they may view.

Use Self::list_in_calendar_with to pass query parameters.

§Example
for in_calendar in client.calendars().appointments().list_in_calendar(42)? {
    println!("{:?}", in_calendar.title_suffix);
}
Source

pub fn list_in_calendar_with( &self, calendar_id: impl Display, query: &GetCalendarsCalendarIdAppointmentsQuery, ) -> Result<Vec<AppointmentOccurrenceList>>

List appointment occurrences in a calendar

Like Self::list_in_calendar, with query parameters.

GET /calendars/{calendarId}/appointments

Returns calculated occurrences for the requested date range, with one entry per occurrence rather than per series. Use appointment.base for the stored series and appointment.calculated for the displayed dates. Recurring occurrences use the installation’s local time across daylight-saving changes. Anonymous users receive only non-internal appointments in calendars they may view.

Source

pub fn split( &self, calendar_id: impl Display, appointment_id: impl Display, body: &AppointmentSplitUpdate, ) -> Result<AppointmentBase>

Split and update an appointment series

POST /calendars/{calendarId}/appointments/{appointmentId}

Creates a new stored appointment from the supplied complete data and removes the selected scope from the original. splitUntilEnd=true cuts the original off before splitDate and requires a split after the original start. false excludes only splitDate and allows splitting the first occurrence. The returned data.id belongs to the new appointment. The new recurrence must describe the intended replacement; splitting does not automatically restrict it to one date. Linked resources are adjusted by their respective workflows.

§Example
let body = models::AppointmentSplitUpdate {
    end_date: DateOrDateTime::DateTime("2026-09-20T09:30:00Z".parse()?),
    start_date: DateOrDateTime::DateTime("2026-09-20T08:00:00Z".parse()?),
    is_internal: true,
    title: "Sunday service".into(),
    split_date: "2026-10-04".parse()?,
    split_until_end: true,
    ..Default::default()
};
let appointment = client.calendars().appointments().split(42, 4, &body)?;
println!("{}", appointment.title);
Source

pub fn update( &self, calendar_id: impl Display, appointment_id: impl Display, body: &AppointmentUpdate, ) -> Result<AppointmentBase>

Update an appointment or series

PUT /calendars/{calendarId}/appointments/{appointmentId}

Replaces editable base fields and the schedule of the stored appointment. This affects the entire series. Existing events and bookings follow the changed schedule. Use changeimpact to inspect supported consequences before submitting a schedule change.

§Example
let body = models::AppointmentUpdate {
    end_date: DateOrDateTime::DateTime("2026-09-20T09:30:00Z".parse()?),
    start_date: DateOrDateTime::DateTime("2026-09-20T08:00:00Z".parse()?),
    is_internal: true,
    title: "Sunday service".into(),
    ..Default::default()
};
let result = client.calendars().appointments().update(42, 4, &body)?;
println!("{}", result.title);

Trait Implementations§

Source§

impl<'a> Clone for CalendarsAppointmentsResource<'a>

Source§

fn clone(&self) -> Self

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl<'a> Copy for CalendarsAppointmentsResource<'a>

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T> Instrument for T

Source§

fn instrument(self, span: Span) -> Instrumented<Self> ⓘ

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
Source§

fn in_current_span(self) -> Instrumented<Self> ⓘ

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> PolicyExt for T
where T: ?Sized,

Source§

fn and<P, B, E>(self, other: P) -> And<T, P>
where T: Sized + Policy<B, E>, P: Policy<B, E>,

Create a new Policy that returns Action::Follow only if self and other return Action::Follow. Read more
Source§

fn or<P, B, E>(self, other: P) -> Or<T, P>
where T: Sized + Policy<B, E>, P: Policy<B, E>,

Create a new Policy that returns Action::Follow if either self or other returns Action::Follow. Read more
Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = !

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, !>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<T> WithSubscriber for T

Source§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> ⓘ
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
Source§

fn with_current_subscriber(self) -> WithDispatch<Self> ⓘ

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more