0

I've just found a simple way to get the some CallLogs (CallerID, Username, To, From, Call duration, Date, Status, ...) from the new Linphone library for swift (SDK 5.0).

I just want to share it with you

1 Answer 1

0

Referring to Linphone's documentation, and some testings, I found at least 2 simple ways to retrieve the CallLog and read it:

1. Using CoreDelegateStub

CoreDelegateStub( onCallStateChanged: { (core: Core, call: Call, state: Call.State, message: String) in

So, you can use the call attribute to get the CallerID(Username) for example, like that:

call.callLog?.fromAddress?.username

Remember, the callLog object contains a ton of parameters that you can find in the documentation

2. Using Core from Linphone wrapper

var mCore: Core!
self.mCore.callLogs

In that way, you can retrieve all your call logs in an array, so you will need to choose an item and get the attributes from it like I've shown above.

self.mCore.callLogs[0].fromAddress?.username
Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.