Apiary

40 views
Skip to first unread message

Tom Robinson

unread,
Nov 30, 2012, 2:25:31 AM11/30/12
to webp...@googlegroups.com
Met the found of this today: http://apiary.io/

Possibly useful, but pretty neat either way.

Tom Robinson

unread,
Nov 30, 2012, 8:23:37 AM11/30/12
to webp...@googlegroups.com
( s/found/founder/ )

I wrote up an example for the parse markdown block, here's the resulting page they generate: http://docs.tom.apiary.io/

I like how the syntax is basically curl output + Markdown interleaved (looks better syntax highlighted)


--- WebPipes ---
---
Blah blah WebPipes blah blah.
---

--
Block
--

Retrieve the block definition
OPTIONS /
< 200
< Content-Type: application/json
< Access-Control-Allow-Headers: Content-Type
< Access-Control-Allow-Methods: OPTIONS,POST
< Access-Control-Allow-Origin: *
{
  "name": "Parse Markdown",
  "description": "Converts Markdown to HTML.",
  "inputs": [
    {
      "name": "markdown",
      "type": "string",
      "description": "Markdown-formatted content for transformation."
    }
  ],
  "outputs": [
    {
      "name": "html",
      "type": "string",
      "description": "HTML-converted data."
    }
  ]
}

Execute the block
POST /
> Content-Type: application/json
{ "inputs": [{ "markdown": "#[foo](http://bar.com)" }]}
< 200
< Content-Type: application/json
{ "outputs": [{ "html": "<h1><a href=\"http://bar.com\">foo</a></h1>\n" }]}
Reply all
Reply to author
Forward
0 new messages