I'd like to pump out the raw-ish HTTP requests/responses to the console to aid debugging.
I've looked at the various docs on GitHub and had a quick search through the code and couldn't find anything obvious, so I'm guessing the answer is no. But just wanted to check if I have missed anything obvious.
AFURLConnectionOperation
sends notifications when operations start and end. You can easily log requests by listening for those notifications and logging the notification object:
[[NSNotificationCenter defaultCenter] addObserverForName:AFNetworkingOperationDidStartNotification
object:nil
queue:nil
usingBlock:^(NSNotification *note) {
NSLog(@"Operation Started: %@", [note object]);
}];
Combine with FormatterKit's TTTURLRequestFormatter
for best results!
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With