pub struct Api { /* private fields */ }Expand description
Low-level notion Api.
Implementations§
Source§impl Api
impl Api
pub fn new(token: &str) -> Self
pub async fn get_object<T>(&self, id: &str) -> Result<T, NotionError>where
T: DeserializeOwned + Requestable,
pub async fn list<T, P>(
&self,
pagination: &P,
) -> Result<PaginationResult<T>, NotionError>where
T: DeserializeOwned,
P: Pagination<T> + NextCursor,
Trait Implementations§
Auto Trait Implementations§
impl !RefUnwindSafe for Api
impl !UnwindSafe for Api
impl Freeze for Api
impl Send for Api
impl Sync for Api
impl Unpin for Api
impl UnsafeUnpin for Api
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more