12

I'm doing some research on the feasibility of an iPhone application, and can't find any indication in Apple's documentation that an iPhone app can read the call history of the phone, specifically the number/address book entry called, when, and the duration.

Does anyone know if this is possible, and how?

Note: The purpose is to remove the need for the user to perform this data-entry themselves. The application is for recording interactions with customer service centers.

Chris Hanson
  • 54,380
  • 8
  • 73
  • 102
Chris Wenham
  • 23,679
  • 13
  • 59
  • 69
  • Have a look at this link, this website challenge this functionality https://iosstuff.wordpress.com/2011/08/19/accessing-iphone-call-history/ – Anurag Sharma Jan 08 '17 at 10:25

5 Answers5

10

Unfortunately you can't access the call history. The only User Data you have API access to is the address book. You can also access photos/pictures but only by starting an iPhone-controlled dialog that allows the user to choose a single image.

It's a bit sucky, hopefully this will be expanded in future versions.

Andrew Grant
  • 58,260
  • 22
  • 130
  • 143
  • 2
    Hey @Andrew do you know this app works - http://itunes.apple.com/us/app/callog/id327883585?mt=8 – Saurabh Jun 10 '11 at 13:36
  • 1
    @Saurabh the description of that app says "When you make your phone calls using this app...". You have to call from the app in order for it to be logged. – Richard Venable Aug 23 '13 at 19:34
  • Yeah @RichardVenable, It's there in their app description, So, It's clear that It's not possible to access the call history programmatically from any app. I read the 2 points as "• This app keeps those casual phone calls for you, when you make phone calls using this app, or import call from a file. • When you make your phone calls using this app it automatically opens at the end of phone call and the phone call is saved to this app." – Ashok Dec 31 '15 at 10:28
3

You can access call history on the Mac by sniffing around the iTunes directory. There are apps out there that do this.

schwa
  • 11,962
  • 14
  • 43
  • 54
2

Seems the only way is to read the log from the iTunes side but now from the phone:

http://arstechnica.com/apple/news/2007/11/iphonelogd-another-solution-for-viewing-your-iphone-call-log.ars

2

AFAIK you can't access call history. The address book is a database of contacts, not call information.

You can read more about the address book in the SDK's "Address Book Programming Guide for iPhone OS."

lajos
  • 25,525
  • 19
  • 65
  • 75
2

I did some reading in which states that you can access the call history on the iphone. It may be dated but worth a shot. Apparently the history is/was held in just a sqlite db on a table called call. The db is/was located at /private/var/mobile/library/CallHistory/call_history.db

If you use FMDB, you can simply do something like this.

FMResultSet *rs = [db executeQuery:@"Select * from Call"];

to get the call history