Q:

Call an ActionCreator from another ActionCreator

I need to call an ActionCreator from another
ducks/products.ts - ActionCreator and Reducers of Products...
import { setStock } from './Store.ts';
//....
export const addProduct = (product: IProduct) => async (
  dispatch: Dispatch,
  getState: () => IState,
  { auth }: IServices
) => {
    dispatch(fetchStart());

    const response = await Axios.post('/api/products', product)

    const producto = response.data as IDataProduct

    // # I need to call SetStock() 
    // # [Try 1] to Call
    setStock(producto)

    // # [Try 2] to Call
    // return (dispatch2: any) => {
      //  dispatch2(
         //setStock(producto._id)
        //  )
    // }

    dispatch(fetchSucess(producto))
};

I saw an example that used try 2, but it doesn't work, and the first try does nothing,
ducks/stores.ts
export const setStock = (product: any) => async (
  dispatch: Dispatch,
  getState: () => any,
  { auth, db }: IServices
) => {
  console.log('INIT SETSTOCKACTIONCREATOR....')
  dispatch(fetchStart());
  try {
    const ref = db.collection("stores").doc(storeId);    
    await ref.update({ [product._id]: product.newStock });

    dispatch(updateSucess({ _id: storeId, stock: product.newStock, productId: product.productId }));

  } catch (error) {    
    dispatch(fetchError(error));
  }
};

I can't do a Dispatch(setStock(producto)) because I get the following from the typescript: 
Argument of type '(dispatch: Dispatch, getState: () => any, { auth, db }: IServices) => Promise' is not assignable to parameter of type 'AnyAction'. 
Property 'type' is missing in type '(dispatch: Dispatch, getState: () => any, { auth, db }: IServices) => Promise' but required in type 'AnyAction'

A:

You just need to dispatch the setStock action like dispatch(setStock(producto._id)) which is similar to what you do for fetchStart
export const addProduct = (product: IProduct) => async (
  dispatch: ThunkAction<Promise<void>, {}, {}, AnyAction>,
  getState: () => IState,
  { auth }: IServices
) => {
    dispatch(fetchStart());

    const response = await Axios.post('/api/products', product)

    const producto = response.data as IDataProduct

    dispatch(setStock(producto._id))

    dispatch(fetchSucess(producto))
};

