A network logger for iOS and macOS projects.

Overview

OkLog for iOS and macOS

Build Status SPM compatible CocoaPods Compatible codebeat badge Languages

OkLog-Swift is a network logger written in Swift highly inspired by simonpercic's original OkLog implementation to be used in iOS and macOS projects.

What does it do?

OkLog encodes request & response data and generates an URL from where you can see all those info nicely, making it easy to debug and share network data. Here's an example.

Installation

CocoaPods

OkLog is integrated with CocoaPods. To use it in your project, add to your Podfile:

pod 'OkLog'

or

pod 'OkLog/Alamofire'

and then don't forget to run:

$ pod install

Swift Package Manager

OkLog is also available through SPM.

Usage

URLSession

In the URLSession's result closure simply call

OkLog.log(request: request, response: response, data: data)

to get the URL printed in Xcode's console, or

let url = OkLog.getUrl(request: request, response: response, data: data)

to retrieve it and do whatever you want.

Alamofire

If you are using Alamofire, place

OkLog.log(response)

or

let url = OkLog.getUrl(response)

in the request's completion closure.

You can also opt-out from URL shortening by specifying shortenUrl: false as parameter.

An example project is included with a few sample requests using URLSession and Alamofire.

You might also like...
Logger for Xcode
Logger for Xcode

CSwiftLog Usage Log.log("Message text without category") Log.my.log("Message text with custom category") Log.network.log("Message text with network ca

A simple logger for your swift applications.

AHQSLogger A simple logging system. Usage import AHQSLogger Use the following methods for loggging. Logging an information / debug You can log a simp

A debug log framework for use in Swift projects. Allows you to log details to the console (and optionally a file), just like you would have with NSLog() or print(), but with additional information, such as the date, function name, filename and line number.
XCLog is a Swift extension that helps you print something in console when debugging your projects.

XCLog XCLog is a Swift extension that helps you print something in console when debugging your projects. Installation Open Xcode File Add Packages

TraceLog is a highly configurable, flexible, portable, and simple to use debug logging system for Swift and Objective-C applications running on Linux, macOS, iOS, watchOS, and tvOS.

Please star this github repository to stay up to date. TraceLog Introduction TraceLog is a highly configurable, flexible, portable, and simple to use

Bugsnag error monitoring & exception reporter for iOS, macOS, tvOS and watchOS

Bugsnag error monitoring & exception reporter for iOS, macOS, tvOS and watchOS The Bugsnag crash reporter for Cocoa library automatically detects cras

Elegant and extensive logging facility for OS X & iOS (includes database, Telnet and HTTP servers)

Overview XLFacility, which stands for Extensive Logging Facility, is an elegant and powerful logging facility for OS X & iOS. It was written from scra

πŸ“±πŸ’¬πŸš¦ TinyConsole is a micro-console that can help you log and display information inside an iOS application, where having a connection to a development computer is not possible.
πŸ“±πŸ’¬πŸš¦ TinyConsole is a micro-console that can help you log and display information inside an iOS application, where having a connection to a development computer is not possible.

TinyConsole TinyConsole is a tiny log console to display information while using your iOS app and written in Swift. Usage Wrap your Main ViewControlle

In-App iOS Debugging Tool With Enhanced Logging, Networking Info, Crash reporting And More.
In-App iOS Debugging Tool With Enhanced Logging, Networking Info, Crash reporting And More.

The debugger tool for iOS developer. Display logs, network request, device informations, crash logs while using the app. Easy accessible with its bubble head button πŸ”˜ . Easy to integrate in any apps, to handle development or testing apps easier. First version, there is plenty of room for improvement.

Releases(0.2.4)
Owner
Diego Trevisan Lara
nil
Diego Trevisan Lara
Simple network activity logger for iOS

Reqres is a simple library for logging all requests and responses in your app. It supports Alamofire and also requests made via native NSURLSession. ⬆

Ackee 85 Aug 21, 2022
An Alamofire network activity logger view

?? AlamofireLogbook An Alamofire network activity logger view Installation AlamofireLogbook is available through CocoaPods. To install it, simply add

Michael Daoud 12 Oct 30, 2019
Easy to use and lightweight logger for iOS, macOS, tvOS, watchOS and Linux in Swift.

Lighty Easy to use and lightweight logger for iOS, macOS, tvOS, watchOS and Linux in Swift. Screenshots Requirements Lighty Version Minimum iOS Target

Abdullah Selek 51 Dec 21, 2022
A lightweight Swift logger, uses `print` in development and `NSLog` in production. Support colourful and formatted output.

Loggerithm A lightweight Swift logger, uses print in Debug and NSLog in Production with colourful output. Why In Swift, we usually use print to log in

HongHao Zhang 270 Oct 8, 2022
A fancy logger yet lightweight, and configurable. πŸ–¨

?? ?? Important: Printer can only print console logs if you're running an app in the Simulator. If you're running in a real device it will not print a

Hemang 66 Dec 7, 2022
A custom logger implementation and Task Local helper for swift-log

LGNLog A custom logger implementation and TaskLocal helper for Swift-Log. Why and how This package provides two and a half things (and a small bonus):

17:11 Games 0 Oct 26, 2021
Tracker - A simple location logger app written in Swift and MVVM architecture

Tracker - A simple location logger app written in Swift and MVVM architecture

Loay Ashraf 1 Mar 12, 2022
Bugfender SDK for iOS, a remote logger tailor-made for mobile

Bugfender SDK for iOS Bugfender is a cloud service to collect mobile application logs. Developers can control log sending programmatically and manuall

Bugfender 69 Dec 4, 2022
Stock tradings Logger app for iOS

Stock Logger Contributor: Name: Prof. Darren Takaki Author: Name: Ibrahim (Wusiman Yibulayin) Student ID: 0728356 Table of contents Description Gettin

null 2 Jul 28, 2022
LogDog is designed to work out of the box, you can use the pre-configured logger anytime, anywhere

LogDog user-friendly logging apple/swift-log api compatible Usage LogDog is designed to work out of the box, you can use the pre-configured logger any

Luo Xiu 21 Aug 14, 2022