>Please look at the intercept example could you please expand on this?
Where do I find the intercept example? Thank you Peppe On Thu, Nov 3, 2022 at 11:17 PM Michael Van Canneyt via lazarus <lazarus@lists.lazarus-ide.org> wrote: > > > > On Thu, 3 Nov 2022, duilio foschi wrote: > > > Hi Michael, > > > > I was able to log the info shown in this pic > > https://i.ibb.co/f4MJQFJ/1.jpg > > > > (I used a rough writeln for now). > > > > This is fine when you want to verify the behaviour of the application > > itself. > > > > 1. > > == > > Is there a way to have the server log HTTP commands received from the > > client? > > > > Like: > > http://localhost:3000/EXPENSES?fmt=buf&humanreadable=1 > > Yes. > > Please look at the intercept example. You can register an interceptor (a kind > of middleware) and log all URLs. > > > > 2. > > == > > Is there a way to have the server log the data returned to the client? > > > > This data will be very valuable when trying to debug a client > > developed by 3th parties that misbehave (what is my condition now). > > > > The alternative will be to use a HTTP proxy. > > Same here: you can register an interceptor for this, use the iaAfter to > indicate that the interceptor takes place after the request was handled. > > The content should still be available in the response.content or > response.contentstream. > > Michael. > -- > _______________________________________________ > lazarus mailing list > lazarus@lists.lazarus-ide.org > https://lists.lazarus-ide.org/listinfo/lazarus -- _______________________________________________ lazarus mailing list lazarus@lists.lazarus-ide.org https://lists.lazarus-ide.org/listinfo/lazarus