[][src]Struct newsblur_api::NewsBlurApi

pub struct NewsBlurApi { /* fields omitted */ }

Implementations

impl NewsBlurApi[src]

pub fn new(
    url: &Url,
    username: &str,
    password: &str,
    cookie: Option<String>
) -> Self
[src]

Create a new instance of the NewsBlurApi

pub async fn login(&mut self, client: &Client) -> Result<String, ApiError>[src]

Login to NewsBlur. This must be called before other functions

On success returns the cookie used for login

pub async fn logout(&self, client: &Client) -> Result<(), ApiError>[src]

Logout of NewsBlur

pub async fn signup(&self, _client: &Client) -> Result<(), ApiError>[src]

Sign up to NewsBlur

pub async fn search_feed(
    &self,
    client: &Client,
    address: &str
) -> Result<(), ApiError>
[src]

Retrieve information about a feed from its website or RSS address.

pub async fn get_feeds(&self, client: &Client) -> Result<Value, ApiError>[src]

Retrieve a list of feeds to which a user is actively subscribed.

pub async fn favicons(
    &self,
    client: &Client,
    feed_id: &str
) -> Result<Value, ApiError>
[src]

Retrieve a list of favicons for a list of feeds. Used when combined with /reader/feeds and include_favicons=false, so the feeds request contains far less data. Useful for mobile devices, but requires a second request.

pub async fn get_original_page(
    &self,
    client: &Client,
    id: &str
) -> Result<String, ApiError>
[src]

Retrieve the original page from a single feed.

pub async fn get_original_text(
    &self,
    client: &Client,
    id: &str
) -> Result<String, ApiError>
[src]

Retrieve the original page from a single feed.

pub async fn refresh_feeds(&self, client: &Client) -> Result<Value, ApiError>[src]

Up-to-the-second unread counts for each active feed. Poll for these counts no more than once a minute.

pub async fn get_read_stories(
    &self,
    client: &Client,
    page: u32
) -> Result<Value, ApiError>
[src]

Feed of previously read stories.

pub async fn get_stories(
    &self,
    client: &Client,
    id: &str,
    include_content: bool,
    page: u32
) -> Result<Value, ApiError>
[src]

Retrieve stories from a single feed.

pub async fn mark_stories_read(
    &self,
    client: &Client,
    story_hash: &str
) -> Result<(), ApiError>
[src]

Mark stories as read using their unique story_hash.

pub async fn mark_story_unread(
    &self,
    client: &Client,
    story_hash: &str
) -> Result<(), ApiError>
[src]

Mark a single story as unread using its unique story_hash.

pub async fn mark_story_hash_as_starred(
    &self,
    client: &Client,
    story_hash: &str
) -> Result<(), ApiError>
[src]

Mark a story as starred (saved).

pub async fn mark_story_hash_as_unstarred(
    &self,
    client: &Client,
    story_hash: &str
) -> Result<(), ApiError>
[src]

Mark a story as unstarred (unsaved).

pub async fn get_unread_story_hashes(
    &self,
    client: &Client
) -> Result<Value, ApiError>
[src]

The story_hashes of all unread stories. Useful for offline access of stories and quick unread syncing. Use include_timestamps to fetch stories in date order.

pub async fn get_stared_story_hashes(
    &self,
    client: &Client
) -> Result<Value, ApiError>
[src]

pub async fn get_river_stories(
    &self,
    client: &Client,
    hashes: &[&str]
) -> Result<Value, ApiError>
[src]

Retrieve up to 100 stories when specifying by story_hash.

pub async fn mark_feed_read(
    &self,
    client: &Client,
    feed_id: &str
) -> Result<(), ApiError>
[src]

pub async fn mark_all_read(&self, client: &Client) -> Result<(), ApiError>[src]

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T> Instrument for T[src]

impl<T> Instrument for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

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

The type returned in the event of a conversion error.