Hi, I'm probably one of those not so smart ones...
I'm trying to figure out how to use the API to create new pages but I cant get past the 1st line: "http://yourname:password@your.mingle.server:8080/api/v2/projects/test_project/wiki.xml"
This renders a xml-file but I'm obviously missing something since I don't get it, where do I put in the rest "page[name]=testing wiki creation" and " page[content]=this is new wiki page content"?
Feels like I'm in way over my head when I don't even understand the help...
/Lisa
Comments
2 comments
Hi Lisa,
Thanks for posting. I think several people have had similar questions. The Mingle help is fairly comprehensive, but is sometimes missing practical examples. The Go help gives examples of how to use their API using the curl command line utility. I'm going to take that approach to try to explain how to use this API.
To add the this wiki page using curl, I entered the following at my terminal (split over several lines for readability):
The (relevant) output of that call is:
> Authorization: Basic dHdvcmtlcjox
As a result of this call, I have the following in my logs (split over several lines for readability):
You can see that the name and content are passed as part of the page parameter.
Sorry that I can only tell you what needs to be done rather than how to do it. How to make this call depends on the language and library that you are using. I personally use Ruby with "net/https", but I know others use Ruby with ActiveResource, PHP, Java, .NET, etc.
If you let me know what language and library you are using, I might be able to give a more concrete answer.
-Jay
Thanks Jay!
You've got no idea how much this helps me to understand.
/Lisa
Please sign in to leave a comment.