pub struct Channels { /* private fields */ }Expand description
Channel operations (sales / fulfillment / end-to-end).
Implementations§
Source§impl Channels
impl Channels
Sourcepub fn is_supported(&self) -> bool
pub fn is_supported(&self) -> bool
Whether channels are supported by the active backend.
Sourcepub fn create(&self, input: CreateChannel) -> Result<Channel>
pub fn create(&self, input: CreateChannel) -> Result<Channel>
Create a new channel.
Sourcepub fn list(&self, filter: ChannelFilter) -> Result<Vec<Channel>>
pub fn list(&self, filter: ChannelFilter) -> Result<Vec<Channel>>
List channels with optional filtering.
Sourcepub fn set_lock(&self, id: ChannelId, locked: bool) -> Result<Channel>
pub fn set_lock(&self, id: ChannelId, locked: bool) -> Result<Channel>
Lock or unlock a channel against external mutations.
Sourcepub fn sync_products(
&self,
id: ChannelId,
items: Vec<ChannelProductSyncItem>,
) -> Result<u64>
pub fn sync_products( &self, id: ChannelId, items: Vec<ChannelProductSyncItem>, ) -> Result<u64>
Bulk upsert/delete channel SKU mappings. Returns the affected count.
Sourcepub fn list_product_mappings(
&self,
id: ChannelId,
) -> Result<Vec<ChannelProductMapping>>
pub fn list_product_mappings( &self, id: ChannelId, ) -> Result<Vec<ChannelProductMapping>>
List a channel’s SKU mappings.
Trait Implementations§
Auto Trait Implementations§
impl !RefUnwindSafe for Channels
impl !UnwindSafe for Channels
impl Freeze for Channels
impl Send for Channels
impl Sync for Channels
impl Unpin for Channels
impl UnsafeUnpin for Channels
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