I use the iTunes library primarily from another application. Are there any methods, preferably automated, to add music to the iTunes Library — i e the .itl file, not only the .xml — without actually using the iTunes GUI for this? For instance command line alternatives or even third party solutions with privileges in the OS.

I think the audio app Max has some iTunes settings that are not using the add to iTunes folder (which is what I'm using now), but I'm not certain on how that works or even if this could help me. Unfortunately C is not my language so hard to determine the exact methodology from the > source code https://github.com/sbooth/Max/tree/master. Probably a dead end anyway.

I have feeling there isn't a good method, but sometimes you miss the obvious solution.

  • Why? only iTunes uses the .itl file. It would hiccup if you explained your longer term goal – Mark Sep 4 '15 at 10:39
  • See edited question. Why would iTunes hiccup if the itl file was in the same state as if iTunes had done the adding? The cache would surely adapt when iTunes reads in the itl. Apple could have opened up the library with an API. I suppose they haven't, but if not they should do it for basic functions like this. – MiB Sep 4 '15 at 10:42
  • You know that you can just drag and drop music files over the iTunes window, right? .itl format is proprietary: stackoverflow.com/questions/2622690/itl-itunes-library-format and seems to change with each new version of iTunes. Messing with it is likely not in your best interest. You could write an Applescript App, or Automator task that'll move everything in a folder, or all selected files, over to your "add to iTunes" folder then restart iTunes with only a couple clicks. – Wayfaring Stranger Sep 7 '15 at 13:53
  • Yeah, I might have to resort to starting up iTunes. Bad Apple I think. I don't really want to mess with the itl file. I want Apple to implement an API for the iTunes library or make it known how an existing API can be used. Ah, well... – MiB Sep 9 '15 at 16:00
  • OK, it seems to be a way to add tracks to iTunes programmatically by creating playlists. Likely this is what the mentioned Max app uses. Researching this now. – MiB Sep 9 '15 at 16:13

You must log in to answer this question.

Browse other questions tagged .