Blog Search
Blog Latest Comments
nice!
by Hunter Eskew on Tuesday, August 16, 2011
Hahaha, not blogging from the iPad. This time it was me trying to do 8 things at once :) But I've since corrected. And ...
by TJ Muehleman on Wednesday, May 11, 2011
Blogging from your iPad again, I see :). Great stuff, TJ! It's always so intriguing to hear where our architecture is ...
by kcoleman on Wednesday, May 11, 2011
Interesting stuff TJ! Please immediately come up with a clever acronym for cloud based OEM before Gartner or Forrester ...
by Kevin Fielding on Wednesday, May 11, 2011
Ho ADACarolyn, To further elaborate: any email generated from the community platform (invites, report abuse notificati...
by kcoleman on Thursday, May 05, 2011
Page  of  Total Items: 28

firstprevnextlast

ThePort's Product and Technology blog. We'll share helpful tips about the platform, talk about upcoming releases, and maybe on occasion share a story or two on how awesome the team is here.
Dugan
Coming 2nd Quarter 2010: Port2Port data available in JSONP
Posted by Dugan
Tuesday, April 06, 2010
Comments (2)
As you may be aware, we have been exposing Port2Port apis via xml for some time now. Xml is great for server-to-server calls where the caller (i.e. "you the developer") wants to fetch an xml representation of some object in thePort's system, do something with that xml, and then serve it out however you see fit. However, a question we had been getting quite often is "Sure, I can work with xml, but what I'd really like to do is more client-side calls directly to your api's and let my javascript process that data".

Enter JSONP or "JSON with padding". Our apis now allow you to submit the name of your method in the querystring:


Notice "callback" specified in the querystring. Supplying this will take the Json payload and wrap your method around it before it comes back to the client. That javascript method will then execute as expected.

Further JSONP reading here.

 
  • Visit gadgeteer's profile
    gadgeteer: hmm. isn't exposing the devkey to the javascript in the browser a security whole?
     

  • Visit Dugan's profile
    Dugan: Fine question, Gadgeteer. We have recently implemented different security levels of dev keys; both a Read key which can be used to fetch data and a Read/Write key which can both Get and Post (this would most likely be the key that you're currently using). All client-side requests would need to use the Read key.