App Store Adds New Countries

Posted by admin on Jul 28, 2009 in iPhone |

Previously I wrote about where to find cool scripts to handle getting the App Store Rank for each country. Back in April, Apple added a few more countries to the app store, did you know? The script attached below needs to be credited to the original author: Erica Sadun. The version I use is based off of Ben‘s script with my own modifications to it to handle multiple id’s a little cleaner, and really, just a tad of code clean up that made me feel better :)

The script itself is attached as a zip file here: AppStoreRank.zip. This version is still written in Perl, but it is extremely easy to add a new app to the script. At the top, just modify the following section:

@appName = ( { appName =>"Hurricane",
appID => 291430598,
categoryName => "Weather" },
{ appName => "Cat Calls",
appID => 308620543,
categoryName => "Entertainment"}
);


appName is just for display purposes
appID is your application ID from the iTunes store.
categoryName should match a category in the list below (this will pull the right category number).
As you can see in my list, the order of the parameters does not matter.

Added the following store codes to my script:
# stores added April 1, 2009
143508 => “Dominican Republic”,
143509 => ‘Ecuador’,
143516 => ‘Egypt’,
143518 => ‘Estonia’,
143510 => ‘Honduras’,
143511 => ‘Jamaica’,
143517 => ‘Kazakhstan’,
143519 => ‘Latvia’,
143520 => ‘Lithuania’,
143515 => ‘Macau’,
143521 => ‘Malta’,
143523 => ‘Moldova’,
143512 => ‘Nicaragua’,
143513 => ‘Paraguay’,
143514 => ‘Uruguay’

I am a little more retentive than most, and wanted my rankings to be listed in alphabetic order, so my version of the script does this automatically.

Also the way the script is written, it can be used as a stand alone script, or as part of a package.

If you have updated the script to add a check for Ratings, I would be very interested in seeing your changes!

Enjoy!

Tags: ,

12 Comments

alpi
Aug 15, 2009 at 8:46 am

Thx! a little bit slow, but works great and is time-saving!


 
admin
Aug 15, 2009 at 9:06 am

I actually never notice the speed of it. I have the script run through a cron every morning, and send me the report via email, to tell me what my rank is for every store. Honestly, while the script may not be the most speedy one I’ve ever seen, it is hitting over 100 URLs and each hit takes transport time, and then minimal parsing time.


 
links for 2009-08-17 | manicwave.com
Aug 17, 2009 at 4:05 am

[...] From Legacy to Web 2.0 » Blog Archive » App Store Adds New Countries Cool script to download app rankings worldwide (tags: iphone marketing analytics metrics) [...]


 
Adrian Pflugshaupt
Sep 2, 2009 at 2:32 am

First of all thanks for a very useful script. I found a tiny tiny bug I’d like to report. Line 140something says
143459 => “Schweitz/Suisse”.
This should be
143459 => “Schweiz/Suisse”
Or it could just say “Switzerland”
There’s probably not many Swiss developers using your script, but I am one of them and couldn’t help noticing ;)


 
Chris
Sep 15, 2009 at 7:06 am

Is it possible now to get the top 200 with the latest version of iTunes/App Store. What part of the script must be changed to obtain that?


 
Alex
Sep 17, 2009 at 6:18 pm

Thanks heaps for the script.
I’ve modified it further to:
- Allow you to specify the status (free or paid), rather than hardcoded in one function.
- Specify to report on a given country (again, for those non-US developers)
- Top countries (a little quicker than waiting to probe each store front)
- Other minor improvements.

Email me if you want to publish the code.


 
admin
Sep 18, 2009 at 10:08 am

Alex: Those sound like great changes and enhancements. I would be happy to post them. – Sent you an email directly.

Chris: I honestly haven’t had time to investigate the changes, but I have noticed that my results are not as stable as they were prior to the AppStore update. I can’t say when I’ll have the time, but I will definitely post an update or refer to another location for an update as soon as I find one… This is just a copy of someone else’s efforts which have been updated. A branch if you will.


 
Reza
Nov 11, 2009 at 10:58 am

Hi,

This script seems to have stopped working over the last week or so. Do you happen to know how to fix it?

Thanks!


 
admin
Nov 27, 2009 at 10:09 pm

You’ve probably already figured this out, but the link syntax has changed to this:

itunes.apple.com/{country}/app/{appName}/id{appID}?mt=8
http://itunes.apple.com/gb/app/jellycar-2/id337319445?mt=8

Good luck!


 
admin
Dec 31, 2009 at 10:14 am

The attached zip file has been updated to fix the regular expression and use the new syntax found in the AppStore in November.

Hope this helps!


 
iPhone game reviews
Jan 20, 2010 at 3:46 am

Thanks so much for this updated script, I am sure it will be very useful for the work we are doing on http://www.touchiphonegames.com and our new (secret) app store site that will be launching soon! If any of you devs want us to review your games on our site, please do not hesitate to contact us via the contact form on our site.

Cheers

TiG Team :)


 
Bruce
May 19, 2010 at 1:06 pm

I actually never notice the speed of it. I have the script run through a cron every morning, and send me the report via email, to tell me what my rank is for every store. Honestly, while the script may not be the most speedy one I’ve ever seen, it is hitting over 100 URLs and each hit takes transport time, and then minimal parsing time.


 

Reply

Copyright © 2010 From Legacy to Web 2.0 All rights reserved. Theme by Laptop Geek.