You need to be able to "wrap" values and then also "wrap" functions in the way you expect. That's literally it.
Btw, the list monad example is stupid imo and borderline misleading. The promise/nullable/Either examples are better. you "wrap" a function by putting it as the only value in a list, and "map" pretty much acts as your function wrapper, but technically this you need to jump through a couple hoops to make it monadic, and I'm just not sure the metaphor is helpful here
λ> do { a <- [1,2]; pure a; }
[1,2]
-- oh so it returns the list unchanged
λ> do { a <- [1,2]; b <- [3,4]; pure a; }
[1,1,2,2]
-- no what is this spooky action at a distance
λ> do { a <- [1,2]; b <- [3,4]; pure [a]; }
[[1],[1],[2],[2]]
-- ...
λ> do { a <- [1,2]; b <- [3,4]; c <- []; pure [a]; }
[]
λ> do { a <- [1,2]; b <- [3,4]; c <- [5]; pure [a,b,c]; }
[[1,3,5],[1,4,5],[2,3,5],[2,4,5]]A bigger issue is that you're missing a piece. If you can "wrap" values and "wrap" functions such that they operate on wrapped values, you (probably) have a functor. To be a monad you also need to have the ability to turn multiple layers of wrapping into one layer of wrapping. For lists, that's "flatten".
I said "probably" above because there are rules these pieces need to follow to behave well. They're pretty simple but I don't think we need to dig into them at this level of discussion.
I might have some inaccuracies in how I state this since I’m not from a functional programming background, but I think of monads as an abstraction of chaining functions over a value such that each returned value can specify what further transformations it supports, and particularly in such a way that generic transformations (like sequence reversal) can easily be applied, and errors or empty values can be accounted for within the control flow.
I think sometimes people call this a “fluent API”, but I would never call it “a generalization of callbacks” or of promises.
Anyway there’s a much more mathematically precise way of stating it but this is my intuitive caveman way of thinking about it.
(I'm trying very hard not to fall into the trying-to-explain-monads trap!)