eGovPDX / Council-Agenda-App

5 stars 0 forks source link

API method for getting user data #33

Open OscarGodson opened 13 years ago

OscarGodson commented 13 years ago

This would be perfect for setting preferences and storing them via localStorage or something.

The call is: https://www.portlandonline.com/apps/external/info2.cfm

And needs some cookie data like cid and and verify hash. I tried for just about 10 minutes but I was having issues. Later on when we need the data I can go back and try to implement it. I'll need to convert the XML to JSON as well on the fly.

It'd work something like:

//Returns ALL user data
app().getUserData()

//Returns just the user's name
app().getUserData('name')

//Returns user's name in ALL the data
app().getUserData().name