I'm using the Java SDK.
ManageOfferOperation class passing an amount and price but it's not taking the price I set. Instead it always sets a different price, which I believe is the market price.
Is there something I'm missing?
Stellar Stack Exchange is a question and answer site for developers and users of Stellar and the Stellar Distributed Exchange. It only takes a minute to sign up.Sign up to join this community
The price you set with
manageOffer is the maximum price when buying and the minimum price when selling. So it will match the best available price in the orderbook.
If you make an offer that has an immediate counterpart on the orderbook it will behave like a market order (take liquidity).
If you make an offer that doesn't have an immediate counterpart in the orderbook it will behave like a limited order (provide liquidity).