Hi Martin,

Switching to POST changes the error to a 400 .

I have it working from a simple html form posting through firefox,  
but am trying to get it going in java.  The java program succeeds in  
GETting data from connotea - just can't post.
Is there a particular user-agent or other request property that i  
should be using?

thanks
-Ben


On Aug 2, 2007, at 12:34 PM, Martin Flack wrote:

> Ben,
>
> Has to be HTTP POST not GET.
>
> I'm attaching a script that I developed for testing.
>
> Martin
>
> Benjamin Good wrote:
>> Hi there,
>>   Is there anything wrong with this ?
>> http://www.connotea.org/data/add?uri=http%3A%2F%  
>> 2Fbioinfo.icapture.ubc.ca%2Fekawas&tags=test%2C+%22test+post%22  
>> +another+test
>> I think authentication is working fine, but I get a 501 response
>> −
>>      <rdf:RDF>
>> −
>>      <Response rdf:about="">
>> <code>501</code>
>> <message>Not Implemented</message>
>> <isFailure>1</isFailure>
>> <user>MrED</user>
>> <apiVersion>0.1.0</apiVersion>
>> <bibliotechVersion>1.7.1</bibliotechVersion>
>> </Response>
>> </rdf:RDF>
>> whats up ?
>> thanks
>> -Ben
>
> #!/bin/bash
> # post something to Connotea from the command line, requires lwp- 
> request
> # lwp-request is part of libwww-perl which is a package on some  
> Linux platforms and available on CPAN
> # edit the variables below for input
> # output is a dump of the HTTP transaction to stdout including  
> Connotea's XML response
>
> user=EDIT
> pass=EDIT
> host=www.connotea.org
> # note all following fields should be url escaped
> uri=http%3A//www.cnn.com
> # separate tags with %20 (spacebar)
> tags=abc%20def%20ghi
> # could also pass in usertitle, description, mywork, private, etc.
>
> echo "uri=$uri&tags=$tags" | lwp-request -C "$user:$pass" -u -U -s - 
> S -e -m POST "http://$host/data/add";
>


-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >>  http://get.splunk.com/
_______________________________________________
Connotea-code-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/connotea-code-devel

Reply via email to