Skip to main content

Endpoint

Enum Endpoint 

Source
pub enum Endpoint {
Show 19 variants SendMessage, GetMessages, UploadFile, ResumableUploadFile, EditMessage, DeleteMessage, GetMessage, GetMessageHistory, ReportMessage, MatchesNarrow, Register, Reaction, Render, FetchApiKey, UpdateMessageFlags, UpdateMessageFlagsNarrow, MarkAllAsRead, MarkStreamAsRead, MarkTopicAsRead,
}
Expand description

Represents the Zulip API endpoint variants.

Variants§

§

SendMessage

Represents the Send Message API endpoint.

§

GetMessages

Represents the Get Messages API endpoint.

§

UploadFile

Represents the Upload File API endpoint.

§

ResumableUploadFile

Represents the Resumable Upload File API endpoint.

§

EditMessage

Represents the Edit Message API endpoint.

§

DeleteMessage

Represents the Delete Message API endpoint.

§

GetMessage

Represents the Get Message API endpoint.

§

GetMessageHistory

Represents the Get Message History API endpoint.

§

ReportMessage

Represents the Report Message API endpoint.

§

MatchesNarrow

Represents the Matches Narrow API endpoint.

§

Register

Represents the Register API endpoint.

§

Reaction

Represents the Reactions API endpoint.

§

Render

Represents the Render API endpoint.

§

FetchApiKey

Represents the Fetch API Key API endpoint.

§

UpdateMessageFlags

Represents the Update Message Flags API endpoint.

§

UpdateMessageFlagsNarrow

Represents the Update Message Flags for Narrow API endpoint.

§

MarkAllAsRead

Represents the Mark All as Read API endpoint.

§

MarkStreamAsRead

Represents the Mark Stream as Read API endpoint.

§

MarkTopicAsRead

Represents the Mark Topic as Read API endpoint.

Implementations§

Source§

impl Endpoint

Source

pub const SEND_MESSAGE: &str = "api/v1/messages"

Represents the string value for the Send Message endpoint.

Source

pub const GET_MESSAGES: &str = "api/v1/messages"

Represents the string value for the Get Messages endpoint.

Source

pub const UPLOAD_FILE: &str = "api/v1/user_uploads"

Represents the string value for the Upload File endpoint.

Source

pub const RESUMABLE_UPLOAD_FILE: &str = "api/v1/tus"

Represents the string value for the Resumable Upload File endpoint.

Source

pub const EDIT_MESSAGE: &str = "api/v1/messages"

Represents the string value for the Edit Message endpoint.

Source

pub const DELETE_MESSAGE: &str = "api/v1/messages"

Represents the string value for the Delete Message endpoint.

Source

pub const GET_MESSAGE: &str = "api/v1/messages"

Represents the string value for the Get Message endpoint.

Source

pub const GET_MESSAGE_HISTORY: &str = "api/v1/messages"

Represents the string value for the Get Message History endpoint.

Source

pub const REPORT_MESSAGE: &str = "api/v1/messages"

Represents the string value for the Report Message endpoint.

Source

pub const MATCHES_NARROW: &str = "api/v1/messages/matches_narrow"

Represents the string value for the Matches Narrow endpoint.

Source

pub const REGISTER: &str = "api/v1/register"

Represents the string value for the Register endpoint.

Source

pub const REACTION: &str = "api/v1/messages"

Represents the string value for the Reactions endpoint.

Source

pub const RENDER: &str = "api/v1/messages/render"

Represents the string value for the Render endpoint.

Source

pub const FETCH_API_KEY: &str = "api/v1/fetch_api_key"

Represents the string value for the Fetch API Key endpoint.

Source

pub const UPDATE_MESSAGE_FLAGS: &str = "api/v1/messages/flags"

Represents the string value for the Update Message Flags endpoint.

Source

pub const UPDATE_MESSAGE_FLAGS_NARROW: &str = "api/v1/messages/flags/narrow"

Represents the string value for the Update Message Flags for Narrow endpoint.

Source

pub const MARK_ALL_AS_READ: &str = "api/v1/mark_all_as_read"

Represents the string value for the Mark All as Read endpoint.

Source

pub const MARK_STREAM_AS_READ: &str = "api/v1/mark_stream_as_read"

Represents the string value for the Mark Stream as Read endpoint.

Source

pub const MARK_TOPIC_AS_READ: &str = "api/v1/mark_topic_as_read"

Represents the string value for the Mark Topic as Read endpoint.

Source

pub const fn new() -> Self

Creates a new Endpoint.

Source

pub const fn as_str(&self) -> &'static str

Gets the string representation of the Endpoint.

Trait Implementations§

Source§

impl Clone for Endpoint

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 Copy for Endpoint

Source§

impl Debug for Endpoint

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Default for Endpoint

Source§

fn default() -> Self

Returns the “default value” for a type. Read more
Source§

impl Display for Endpoint

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Eq for Endpoint

Source§

impl From<Endpoint> for &'static str

Source§

fn from(val: Endpoint) -> Self

Converts to this type from the input type.
Source§

impl From<Endpoint> for String

Source§

fn from(val: Endpoint) -> Self

Converts to this type from the input type.
Source§

impl PartialEq for Endpoint

Source§

fn eq(&self, other: &Self) -> bool

Equality operator ==. Read more
1.0.0 (const: unstable) · Source§

fn ne(&self, other: &Rhs) -> bool

Inequality operator !=. Read more
Source§

impl StructuralPartialEq for Endpoint

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<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
where ST: ?Sized, DT: ?Sized,

Source§

impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
where ST: ?Sized, DT: ?Sized,

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<Q, K> Equivalent<K> for Q
where Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,

Source§

fn equivalent(&self, key: &K) -> bool

Checks if this value is equivalent to the given key. Read more
Source§

impl<Q, K> Equivalent<K> for Q
where Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,

Source§

fn equivalent(&self, key: &K) -> bool

Compare self to key and return true if they are equal.
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> Read<Exclusive, BecauseExclusive> for T
where T: ?Sized,

Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
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> ToString for T
where T: Display + ?Sized,

Source§

fn to_string(&self) -> String

Converts the given value to a String. 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<V, T> VZip<V> for T
where V: MultiLane<T>,

Source§

fn vzip(self) -> V

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