Code Monkey home page Code Monkey logo

apple-id-applescript's Introduction

Hi there 👋, I'm bsquidwrd

  • You can call me Squid for short

  • 😄 Pronouns: he/him/they/them

  • 📫 You can reach me on Twitter! (Please honor nohello if you message me)

  • 📖 I currently work full time as an Integration Engineer and am going to school for a Bachelors in Software Engineering

  • 👀 I’m interested in:

    • programming
    • api's
    • automating as much as possible
  • Notes:

    • Any comments/views/statements I make are in no way a reflection of my employer

apple-id-applescript's People

Contributors

aaronfreimark avatar billcampbell avatar janeitzey avatar jrhutson avatar kochalex avatar pwldp avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

apple-id-applescript's Issues

AUS localisation errors

I've modded a copy the script a bit to better support Australian itunes
we run the same date order as Canada which you already had (the easy bit)

I'm having trouble with our 4 digit post code and our 3 letter state code drop down
(mostly because I don't know what I'm doing)
If i leave the code as is (USA) My postcode field is filled in with my City, my City field is left blank and the script errors on State
phone area code and number are also broken but I haven't managed to sort the postcode and state out to get to that yet.

See screenshot for the Aussie iTunes layout
screen shot 2016-01-15 at 2 17 56 pm

I know its all about the order of the fields and what position they are in
are you able to give me a hint as to where the number starts

Cheers

Jeremy

Minor Updates.

I'm running iTunes 12.2.2.25 and running into errors when running the script. To your knowledge do I need to get my machine specifically on 12.2 or one of the other listed versions for it to work?

Script Error - System Events got an error

Script was running fine with iTunes 12.3 running Mac OS 10.10 but after upgrading to 10.11 get this error during dry run when the "Create New Apple ID" button is about to be selected:

Script Error: System Events got an error: Can’t get scroll area 1 of window 1 of application process "iTunes". Invalid index.

I tried clearing the iTunes cache and that didn't help.

script error system events

Time out issue and mouse movement

When I run the script to create ID's, I have to keep moving the mouse every few seconds or the process times out. It started on Friday (12/4/15) when I tried to create a batch of 50 ID's. It started after the 6th ID. at first I thought it was an issue with Apple's site. I restarted the script with ID#7 and it timed out again after 6 more ID's. After 23 ID's, I gave up for the day. (yes, I did have Apple whitelist my IP address).
This morning, I tried it again and it would time out before finishing 1 ID. I rebooted machine and tried again. After it timed out again, I noticed that when I moved the mouse, iTunes would suddenly move to the next screen. I tried again and found that if I didn't physically move the mouse every 10-15 seconds, it would stall until I moved it again. If I kept mouse moving, it would fly though the creation process.

Slides through all the Months. Doesn't pick desired Month and Day

Brandon,

The script recognizes iBooks but when it begins to enter in the birthdate (Jan 1 1980) it skips January and cycles through all the months until it gets to december. Does the same with the days until it gets to 11. It does set the year properly to 1980.

As per the previous post. We found that same error. When looking closely at the Numbers CSV file, it would add an extra row between each appleID. Hence there would be a row between the Header row and the first apple ID and it would cause the same error as mentioned above.

Latest Update

Hey everyone,

I was able to get this running on Friday (Sept 9) and Monday (Sept 12) however it seems like today Apple might have changed something on their end? I'm not sure why this is happening but the script now stops at the agree to terms and condition window.

The AppleScript error message is:

System Events got an error: Can’t get UI element 
"Terms and Conditions and Apple Privacy Policy" of UI 
element 1 of scroll area 1 of group 1 of group 1 of 
splitter group 1 of window "iTunes" of application 
process "iTunes".

Anyone have any ideas?

iTunes: 12.4.3.1
OS: 10.11.6

Thanks,

Works with iTunes 12.2.2

Just wanted to add the comment that I successfully created 210 accounts with 12.2.2.

Thanks for all the hard work!

CSV format problem?

Maybe you know whats wrong with my test csv file:

Email,Password,Secret Question 1,Secret Answer 1,Secret Question 2,Secret Answer 2,Secret Question 3,Secret Answer 3,Month Of Birth,Day Of Birth,Year Of Birth,First Name,Last Name,Address Street,Address City,Address State,Address Zip,Phone Area Code,Phone Number,Rescue Email (Optional),Account Status
[email protected],Pa55word,What was the name of your first pet?,Bob,What was the model of your first car?,porsche,What was the first name of your first boss?,capone,01,01,1970,FirstName,LastName,Ulica,Miasto,wojewodztwo,01-234,48,123456789,[email protected],0

I got an error:

error: Can’t get item 1 of {}." number -1728 from item 1 of {}

at line:

set item loopCounter of columnContents to item columnToGet of item loopCounter of fileContents

in

on getColumnContents(columnToGet, fileContents)
        set columnContents to {}
            repeat with loopCounter from 1 to (count of items of fileContents)
                set columnContents to columnContents & 1
                set item loopCounter of columnContents to item columnToGet of item loopCounter of fileContents
            end repeat
            return columnContents
    end getColumnContents

I need to create 400 Apple IDs. Please help me.
iTunes version 11.4.

Regards
DP

Move localization to separate file

I need a localized version of this script, and see that the localization has to be hardcoded within the script, and then select it by changing in code.

I also noticed the number of forks and that must mean that anyone who need a localized version has to fork the script, but that also means they maybe don't get any updates you provide to the main script.

This could be improved immensely if you moved the localization to a separate file and when the script ran either checked current localization or asked the user from the available localizations in the external file.

Then anyone who does a localization can contribute to one repository and everyone can benefit from that. And also everyone is contributing to the same source and project.

Just looking at the number of forks tells me that this would be an extremely welcome feature.

So my suggestion:

A separate localization file, much like the "strings" file used by objective-c, where anyone can contribute with their language and everyone running (and contributing) to the same script source.

Terms and conditions

Hi,

thank you for the script I like it very much.

I have issues here with the "Agree" checkbox of the terms and conditions step (currently I try to dry run).

It prompts me to do this step manually.

This is the error message:
Unable to locate and check box #2 ''I have read and agree to these terms and conditions.''

I can manually click on "I have read and agree to these terms and conditions" in iTunes then the script continues. Can you help me on that?

I have MacOS 10.11.2 and iTunes 12.3.2.35

The next problems I have found are following:

  1. The birth "day" (month and year work fine). I tried following values 1,10 and 01. Non of them seem to work.
  2. The "state" as well as the "postal code" cannot be filled as well.

Can you help me on these issues?

Kind regards
Karol

Account Status.

Script is currently not updating Account Status field for me when running on 10.11.3 with iTunes 12.3.2.35.

Script stuck on Apple Logo

When running the script, on iTunes 12.1.2, It opens iTunes and goes to the iBooks page, hits the apple logo, then opens the Sign In page. However once it gets to this step, it says 'Script Error - System Events got an error. Can't get scroll area 1 of application process "iTunes". Invalid Index.

I've run the script on OSX 10.10 and 10.11 and I get the same error both times.

I can sometimes (with really good timing) bypass this simply by pressing the 'Creat Apple ID' button.

I've tried finding a more updated version of iTunes but haven't been able to find 12.2 or 12.3. I can find 12.3.3, but it gives the same error.

Script runs, fills fields, does not create account......possible error on last page with payment of none.

I am back at this after a couple months away. I have Mavericks 10.9.5 and iTunes 11.3.

I can run the "dry run" and everything seems to work ok as far a filling in the necessary fields. When I go to live run and create the apple ids, the script processes as if it is working normally. It goes through each line of the csv and proceeds to the next account to create. What I noticed was I wasn't getting any emails for verification. After going back and checking, it seems that itunes is not progressing past the screen where you select billing etc. The "none" button is not staying "highlighted" per se. If I step through it manually it gives me an error that says to contact apple.

Has anyone seen this error? I thought about upgrading to iTunes 12, but I didn't know if that would break other things.

Looks like canadian version got merged with main version.

Unless this was an intentional, somewhere along the way the state and zip section got changed to the Provence and postal code section of Enterprise iOS Apple ID Creator.applescript. I was able to pull the old code from an old revision and made it work. Thanks for all of your work keeping this updated.

Replace starting at Line 1057 ending with 1069

try
set frontmost of application process "iTunes" to true --Verify that iTunes is the front window before performking keystroke event
set focused of pop up button "Select a state" of group 2 of group 10 of theForm to true
keystroke addressState
on error
set errorList to errorList & "Unable to set ''State'' drop-down to " & addressState
end try
-----------
try
set value of text field "Zip" of group 3 of group 10 of theForm to addressZip
on error
set errorList to errorList & "Unable to set ''Zip Code'' field to " & addressZip
end try

System Events Error

I'm getting this error after clicking on iBooks, it won't get past the "Create Apple ID" button, and keeps going back to the Apple Logo. Any thoughts?

error "System Events got an error: Can’t get scroll area 1 of window 1 of application process "iTunes". Invalid index." number -1719 from scroll area 1 of window 1 of application process "iTunes"

Merge conflicts

The last commit to master has some merge conflicts that weren't resolved.

How to whitelist ip

Your script is good but its depend on whitelist ip, because you have one, could you help me to whitelist my ip?

contact Apple

Dose any one contact Itunes Support team to take IP in to whitelisted ??
...........
i think they dont accept this script , because they dont answer me.....
may be im in the wrong way , could someone help me for that????

Error after a while of using the Apple-ID-AppleScript (screenshot)

This happens after a while running with the appleid create script.
And it won't go away.. solution i found is to make a new user and start over again and it works.
If i change back to old user itunes will not work.. and i get that error message after a while in the creation process.
I tried deleting safari cache/cookies and also delete pref files under ~/Library/Preferences
it dont help. A new user seems the best solution for me.
Apple says something is wrong with my internet connection when i have that error.
But i dont hink so.
Anyone else experinced that kind of error message?

screen shot 2015-12-03 at 07 32 13

Unable to Verify itunes is open at the ibooks app store page

Hi Brandon,

Thanks again for the Canada version of the script. It was working fine for me but last week we got the following error message regarding the ibooks page.

Version of itunes and OSX is the same on the machine.

Could you please help me figure out what has
screen shot 2014-08-11 at 11 33 54 am
changed ?

Payment method and fields Canada vs US

screen shot 2014-07-26 at 12 26 39 pm
Hi Brandon,

First of all thank you so much for creating and maintaining this script. We are Catholic School district in Canada. We are about to deploy 1500 devices and need 1500 apple ID's. I was hoping you can help me out making this script work at Canada regarding payment changes US vs Canada. I get to last page in itunes where it selects payment method ''none'' and than I get errors.

  1. Unable to set ''State'' drop down ( We have province not state)
  2. Unable to set ''Zip Code'' field to ( we have postal code )

Could you please let me know how to correct this ?

Thank you,

State (Province) and Zip Code Issues when running Script

Brandon,

Thanks for updating the script on Friday. It now runs smooth when adding in the correct Birthdate. Glad you were able to figure out that bug so fast.

I downloaded that updated script (9/19/14 at 14:31) and ran it today. It halts at the State (the script calls it Province). We figured Apple changed the drop down list by adding the two letter abbreviation jamming up the script. i.e. changing it from "Pennsylvania" to "PA - Pennsylvania. We changed our CSV file to match this new format but the issue persists. I have a screen recording if you are interested in viewing it.

I really appreciate your persistence in making this script work. Very commendable and I'm sure many of us appreciate it although you may rarely get a virtual pat on the back. Keep up the great work!

error number -1719 from static text 1 of scroll area 1 of window 1 of application process "iTunes"

Hi,

OSX 10.9.5
iTunes 9.4 (18)

When I run the script, this loop doesn't stop:

A ''dry run'' will run through every step, EXCEPT actually creating the Apple IDs." buttons {"Actually Create Apple IDs", "Dry Run", "Cancel"}
--> {button returned:"Dry Run"}
end tell
tell application "iTunes"
open location "itms://itunes.apple.com/us/app/ibooks/id364709193?mt=8"
end tell
tell application "System Events"
get description of scroll area 1 of window 1 of application process "iTunes"
--> "logo Apple"
get description of scroll area 1 of window 1 of application process "iTunes"
--> "logo Apple"
get description of scroll area 1 of window 1 of application process "iTunes"
--> "logo Apple"
get description of scroll area 1 of window 1 of application process "iTunes"
--> "logo Apple"
get description of scroll area 1 of window 1 of application process "iTunes"
--> "logo Apple"

etc...

System Events got an error

I tried downgrading to the last itunes version that was supported but still no luck. Would me being on sierra have anything to do with it? Any advice would be greatly appreciated.
screen shot 2017-07-28 at 8 53 49 pm

Selecting "Create apple ID"

hey ev.one:
there is a problem that i catch , when i run this script , itunes goes to get ibook and after click on "Get" btn
new Window "Sign in to ..." shows me in this step script must be click on "Create apple id" but script get an error that say: "System Events got an error: Can’t get scroll area 1 of window 1 of application process "iTunes". Invalid index"

i test it with several version of itunes (12.1.2,,12.2.2) but error dose not change , so where is the problem?!!!!

Script requires manual press of "OK" after each user

Currently experiencing an issue where the script requires manual intervention to press an "OK" button at the end of the user creation process. Otherwise it errors out and doesn't proceed to the next user. Not sure if this is just specific to Canadian iTunes or not. Also the province dropdown from the previous screen doesn't clear, but it still creates the user fine.

itunes

AppleScript Error - Can't get UI element

Hey Brandon,

I came across your script the other day and would love to get this working to deploy 150+ ipads we need to get out as soon as possible.

I am running the script on OSX 10.8.5 with iTunes 12.1.2 and I am getting stuck with the following error (tried on a newer version of iTunes as well):

AppleScript Error - System Events got an error: Can't get UI element "iBooks" of group 2 of UI element 1 of scroll area 1 of splitter group 1 of window 1 of application process "iTunes."

Any suggestions? iTunes gets taken to the iBooks page and then errors out.

Any help would be appreciated! Thanks!

Script breaks with iTunes 12.2

Issues with iTunes 12.2. 'Store' dropdown tab in iTunes toolbar has been renamed 'Account'.

On SignOutiTunesAccount()

set storeMenu to menu "Account" of menu bar item "Account" of menu bar 1 of application process "iTunes"
set storeMenuItems to title of every menu item of storeMenu
end tell

Issues with executing security question fills as well. Continuing to test.

iTunes 12.01

As with everything else, Apple loves breaking things.

This issue is for me to remember to continue working on the script to update for 12.01

Move script to app

I talked to @macmule at JNUC 2015 and decided it was best to move to an App form of this script for easier usage. This is also the only way I can think of to solve #26 and make it easier for people to get updates at the same time.

iTunes 12.3.1.23 error

Error:
error "System Events got an error: Can’t get UI element "Welcome to the iTunes Store" of UI element 1 of scroll area 1 of splitter group 1 of window 1 of application process "iTunes"." number -1728 from UI element "Welcome to the iTunes Store" of UI element 1 of scroll area 1 of splitter group 1 of window 1 of application process "iTunes"

NOTES:
Once you click on the iTunes window it refreshes and loads the [UI element "Welcome to the iTunes Store"]. Tried increasing the wait / repeat counts, iTunes only refreshes to that window once the cursor moves or clicks. I did successfully time it once and get it to refresh without interrupting the script. Completed successfully without intervention after that point.

Doesn't press the "Get" Button

Hi there

After choosing the cvs file.
I started the script, it searches for the iTunes U App but after that it is stuck.
It doesn't presses the "Get" Button and following up there is an Error

"System Events got an error: Can’t get static text 4 of window 1 of application process "iTunes". Invalid index."

and "Sign in to the iTunes Store" is marked in the Script.

any ideas?

Thanks

Optimal Conditions for Running Script

Hi Brandon,

Here's my current environment -

10.11 (El Captian), iTunes 12.1.2, iTunes 12.2, iTunes 12.2.1

10.9 (Mavericks), iTunes 12.1.2, iTunes 12.2, iTunes 12.2.1

I'm currently setting up a 10.10 (Yosemite) VM, to test the conditions.

The first error I run into deals with the checkbox, under the "Terms and Conditions..." page. Here's the error

get value of static text 1 of scroll area 1 of window 1 of application process "iTunes"
count every UI element of UI element 1 of scroll area 1 of splitter group 1 of window 1 of application process "iTunes"

get UI element "Terms and Conditions and Apple Privacy Policy" of UI element 1 of scroll area 1 of splitter group 1 of window 1 of application process "iTunes"

get properties of UI element "Terms and Conditions and Apple Privacy Policy" of UI element 1 of scroll area 1 of splitter group 1 of window "iTunes" of application process "iTunes"

get checkbox 1 of group 5 of UI element 1 of scroll area 1 of splitter group 1 of window 1 of application process "iTunes"

end tell

error "System Events got an error: Can’t get text field 1 of group 3 of UI element 1 of scroll area 1 of splitter group 1 of window "iTunes" of application process "iTunes". Invalid index." number -1719 from text field 1 of group 3 of UI element 1 of scroll area 1 of splitter group 1 of window "iTunes" of application process "iTunes"

These problems are consistent when running under the 10.11 version. What are the recommended environment to run this script?

Enterprise iOS Apple ID Creator.applescript

Hi,

I just started using this script to create Apple id's for my school in Winnipeg, MB. The script works great until it gets to enter "Your Date of Birth" I get the following errors.. Unable to fill Month, Unable to fill Day. All my users account info is enter corectly on the CSV file, but for some reason the script just goes through all the numbers of days and the months and just ends and quit. But the script dose fill in the year with the right information. Is there something I need to enter to make this part work?

Tnanks

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.