How to get result back from "nyxt -r -e sexpr"?

I would like to create a command line script, to get some information from nyxt.
But the results are printed to the terminal where the nyxt server was started.
Is there some way I can override this to get results back to the terminal where I run “nyxt -r”?
Using nyxt -r is not a requirement, if there is some other way to get info from nyxt, that might be OK to,
as long as it can be done from the command line.

@johan_widen perhaps an example would be helpful. What are you concretely trying to achieve?

For instance:

$ nyxt --remote --quit --eval '(echo "hello")'

(process:29794): Gtk-WARNING **: 15:45:59.784: Locale not supported by C library.
	Using the fallback 'C' locale.
<INFO> [15:45:59] Probing remote instance listening to /run/user/1000/nyxt/nyxt.socket.
<INFO> [15:45:59] External evaluation request: "(echo \"hello\")"
<INFO> [15:45:59] hello
NIL

I want to get a list with the title and url for each buffer. Similar to the chrome brotab extension.
But I see from your example that I seem to have some config problem: I do not get this logging information in the terminal where I executed ‘nyxt -r’. I get that info in the terminal where I started the nyxt server. In the terminal where I ran ‘nyxt -r’ I only get:
[14:52:18] Probing remote instance listening to /run/user/1000/nyxt/nyxt.socket.

This one is, unfortunately, not implemented yet :frowning:

See #1453 for the progress on it.

OK, thanks for the answer.
Until that is fixed I will use emacsclient and GitHub - ag91/emacs-with-nyxt: Some code to make Emacs interact with Nyxt

@johan_widen very good observation! Indeed, it only gets printed to stout when the both nyxt and --remote were both issued in the same shell process. Interesting…