Hi Bahman,

On 04 Nov 2013, at 20:13, Bahman Movaqar <bah...@bahmanm.com> wrote:

> Hi all,
> 
> Apparently, I finally have the time to do something serious with Pharo.  And 
> I'm intending to get started ASAP before any interruptions :-)
> 
> I'm planning to write a GUI front-end for an application that provides JSON 
> interface --the JSON provider is Fossil SCM (fossil-scm.org).  As the first 
> step I need an HTTP client library that can handle GET/POST requests and a 
> JSON parsing library.  I'd appreciate any suggestions for those libraries.

HTTP is, of course built in. For JSON parsing, you can use NeoJSON. Open the 
Configuration Browser and install is. Then you can do things like:

ZnClient new
  systemPolicy;
  url: 'http://easy.t3-platform.net/rest/geo-ip';
  queryAt: 'address' put: '81.83.7.35';
  accept: ZnMimeType applicationJson;
  contentReader: [ :entity | NeoJSONReader fromString: entity contents ];
  get.

PUT, POST & DELETE are easy as well. I am using this all the time.

Here is some more documentation:

http://zn.stfx.eu/zn/zinc-http-components-paper.html
https://github.com/svenvc/docs/blob/master/neo/neo-json-paper.md

HTH,

Sven

> TIA,
>  
> -- 
> Bahman Movaqar  (
> http://BahmanM.com
> )
> 
> ERP Evaluation, Implementation & Deployment Consultant
> PGP Key ID: 0x6AB5BD68 (keyserver2.pgp.com)
> 


Reply via email to