Tag Archives: Kiva

Kiva Country Collector – Now storing loan IDs.

I had to archive everyone’s cached data, because I’ve made a major change to the data model and it wasn’t fully backwards compatible.

The upside, is that it’ll be less API intensive about pulling in updated data and won’t start from scratch each time.

The downside, though, is that I’m storing loan IDs now. So, that’s something you should consider if you want to use the app. If you don’t select the “Privacy Mode”, then I’ll be storing your lender id, loan IDs and countries you’ve loaned to in a file that looks like this:

$ head lenders/bswopes.csv 
"DO","[519186, 453620, 414509, 253513]"
"BF","[561459, 455699, 406311, 346733]"
"KH","[271711, 295024, 238144, 265943]"
"XK","[508414, 518939, 482881, 443775]"
"BO","[518671, 290774, 232177, 196661]"
"YE","[510083, 412907, 425078, 391416]"
"LR","[434516, 404925, 297545, 203097]"
"BJ","[561715, 404260, 361734, 227187]"
"JO","[480732, 443313, 380336, 310151]"
"AZ","[483852, 337269, 355439, 295106, 234743]"

Here’s what it had looked like before:

$ head old-format/bswopes.csv 
"DO",4
"BF",4
"KH",4
"XK",4
"BO",4
"YE",4
"BI",4
"BJ",4
"JO",4
"HN",4

EDIT 20130921: I’ve converted to json format and also include the total lender_count to clean up the re-import.

SearchKiva

A teammate on Kiva pointed out this awesome site SearchKiva by Boni Gopalan. It looks great and is incredibly responsive, so I wanted to give it a shout out.

If you were struggling with KivaLens, check it out.

Kiva Country Collector – Python scripts on GitHub

I’ve been a Kiva.org lender for a while, and I always try to pick up new countries when they’re available… KivaLens has been giving me trouble, though, so I started writing something myself against the kiva api.

You can find (and contribute code to) the project over on github at: https://github.com/bswopes/kiva-country-collector

$ ./kiva-loans.py -i bswopes
User ID: bswopes
No new countries found. Looking for less used countries.
Found 1 loans for country ALBANIA
Country ALBANIA, previous loan count 2