--- displayed_sidebar: servicesSidebar --- import TypeList from "@site/src/components/TypeList" # SalesChannelService ## constructor ### Parameters ___ ## Properties `","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"__moduleDeclaration__","type":"`Record`","description":"","optional":true,"defaultValue":"","expandable":false,"children":[]}]} sectionTitle="SalesChannelService"/> ___ ## Accessors ### activeManager\_ #### Returns ___ ## Methods ### withTransaction #### Parameters #### Returns ### shouldRetryTransaction\_ #### Parameters ` \\| `object`","description":"","optional":false,"defaultValue":"","expandable":false,"children":[]}]} sectionTitle="shouldRetryTransaction_"/> #### Returns ### atomicPhase\_ Wraps some work within a transactional block. If the service already has a transaction manager attached this will be reused, otherwise a new transaction manager is created. #### Type Parameters #### Parameters Promise<TResult>","description":"the transactional work to be done","optional":false,"defaultValue":"","expandable":false,"children":[]},{"name":"isolationOrErrorHandler","type":"`IsolationLevel` \\| (`error`: TError) => Promise<void \\| TResult>","description":"the isolation level to be used for the work.","optional":true,"defaultValue":"","expandable":false,"children":[]},{"name":"maybeErrorHandlerOrDontFail","type":"(`error`: TError) => Promise<void \\| TResult>","description":"Potential error handler","optional":true,"defaultValue":"","expandable":false,"children":[]}]} sectionTitle="atomicPhase_"/> #### Returns ### retrieve\_ A generic retrieve used to find a sales channel by different attributes. #### Parameters #### Returns ### retrieve Retrieve a SalesChannel by id #### Parameters #### Returns ### retrieveByName Find a sales channel by name. #### Parameters #### Returns ### listAndCount Lists sales channels based on the provided parameters and include the count of sales channels that match the query. #### Parameters #### Returns ### list Lists sales channels based on the provided parameters. #### Parameters #### Returns ### create Creates a SalesChannel This feature is under development and may change in the future. To use this feature please enable the corresponding feature flag in your medusa backend project. #### Parameters #### Returns ### update #### Parameters #### Returns ### delete Deletes a sales channel from This feature is under development and may change in the future. To use this feature please enable the corresponding feature flag in your medusa backend project. #### Parameters #### Returns ### createDefault Creates a default sales channel, if this does not already exist. #### Returns ### retrieveDefault Retrieves the default sales channel. #### Returns ### listProductIdsBySalesChannelIds List all product ids that belongs to the sales channels ids #### Parameters #### Returns ### removeProducts Remove a batch of product from a sales channel #### Parameters #### Returns ### addProducts Add a batch of product to a sales channel #### Parameters #### Returns