On Mon, Mar 2, 2009 at 5:26 PM, kiko <[email protected]> wrote:
>
> the form-cli was a hack because the ruote-rest was failing if it was
> other types of content-types so I needed to put some random content-
> type, and the blank pdef argument was required for some reason I never
> figured out.
>
> I made an attempt to launch the process as an httparty client. Also I
> don't get much of what you mean about your last response, it seems
> your recommending using OpenWFE objects to create the xml or json text
> on the client and send to the server? My understanding is if you post
> to http:<ruote-web2 server>/processes with parameter pdef_url to the
> process file and parameter fields with a json representation of the
> payload. My issue is getting the authentication to work.
Hello Francisco,
I couldn't get Httparty to run with "application/json" for now. But
this shell script works fine :
---8<---
curl \
--verbose \
--basic --user "admin:admin" \
-H "Content-Type: application/json" \
-H "Accept: application/json" \
--data '{"pdef_url":"public/defs/sequence1.rb", "fields":{"a":"b"}}' \
http://localhost:3000/processes
--->8---
Note that the JSON version of the launchitem is inserted as the body
of the post, not as the a query (URL) parameter.
I'll try again with Httparty (or rest_client) after the supper.
Best regards,
--
John Mettraux - http://jmettraux.wordpress.com
--~--~---------~--~----~------------~-------~--~----~
you received this message because you are subscribed to the "ruote users" group.
to post : send email to [email protected]
to unsubscribe : send email to [email protected]
more options : http://groups.google.com/group/openwferu-users?hl=en
-~----------~----~----~----~------~----~------~--~---