Updated order to call ApiOrder if needed
Fixed API order and tests