Nube learning to play with apis

thank you for that,
i dont really know how to use curl, so i have been using ajax which i am sort of comfortable with for this purpose…
and im pretty sure it needs my client id and my secret which i tried using the ajax built in methods{username:name, password:password} would that not be the right way to go?

ill post up my code in just a second