{"_id":"546809b098b6840800268a32","editedParams":true,"githubsync":"","__v":1,"project":"5467f78598b68408002689f4","user":"5467f76e016b480800bc7c7d","editedParams2":true,"is_link":false,"version":{"_id":"5467f78598b68408002689f7","project":"5467f78598b68408002689f4","__v":1,"createdAt":"2014-11-16T01:01:57.550Z","releaseDate":"2014-11-16T01:01:57.550Z","categories":["5467f78698b68408002689f8"],"is_deprecated":false,"is_hidden":false,"is_beta":false,"is_stable":true,"codename":"","version_clean":"1.0.0","version":"1.0"},"category":{"_id":"5467f78698b68408002689f8","__v":13,"project":"5467f78598b68408002689f4","pages":["5467f78698b68408002689fa","54680584016b480800bc7ca0","546806af016b480800bc7ca3","5468084998b6840800268a28","546808fe016b480800bc7ca6","546809b098b6840800268a32","54680ab898b6840800268a42","54680b5d016b480800bc7cc2","54680b9a016b480800bc7cc5","5468293298b6840800268a79","54682958016b480800bc7cf9","54682fbc016b480800bc7cfd","54f664fd542ade0d00f1c69b"],"version":"5467f78598b68408002689f7","sync":{"url":"","isSync":false},"reference":false,"createdAt":"2014-11-16T01:01:58.022Z","from_sync":false,"order":0,"slug":"api-documentation","title":"API Documentation"},"updates":["57c535dcfc81340e00ebf53c"],"next":{"pages":[],"description":""},"createdAt":"2014-11-16T02:19:28.619Z","link_external":false,"link_url":"","sync_unique":"","hidden":false,"api":{"basic_auth":false,"method":"post","results":{"codes":[{"status":200,"language":"json","code":"{\n  \"page\":{\n    \"path\":\"/lorem-ipsum.md\",\n    \"metadata\":{\n      \"description\":\"bla bla bla\",\n      \"title\":\"Lorem Ipsum\"\n    },\n    \"content\":\"# Hello World\"\n  }\n}","name":""},{"status":400,"language":"json","code":"{\n  \"code\":400,\n  \"status\":\"Bad Request\",\n  \"message\":\"Malformed JSON\"\n}","name":""},{"status":404,"language":"json","code":"{\n  \"code\":404,\n  \"status\":\"Not Found\",\n  \"message\":\"Directory does not exist\"\n}"}]},"try":false,"auth":"never","params":[{"_id":"546809b098b6840800268a35","ref":"","in":"path","required":false,"desc":"Directory where the new page will be created","default":"","type":"string","name":"path"},{"_id":"546809b098b6840800268a34","ref":"","in":"body","required":false,"desc":"Stringified JSON that stores the page metadata","default":"","type":"string","name":"page[meta]"},{"_id":"546809b098b6840800268a33","ref":"","in":"body","required":false,"desc":"Page content in markdown","default":"","type":"string","name":"page[content]"}],"url":"/api/page/:path"},"isReference":false,"order":5,"body":"A filename will be created based on the title of the page. This will be in lowercase, and all spaces will be replaced with hypens and have the `.md` extension appended to the end. E.g. `Lorem Ipsum -> lorem-ipsum.md`\n\nIf a file already exists with that filename, a number will be appended to it. E.g. `lorem-ipsum.md -> lorem-ipsum-1.md -> lorem-ipsum-2.md`\n[block:code]\n{\n  \"codes\": [\n    {\n      \"code\": \"$.post('/api/page/foo/bar', {\\n  meta: JSON.stringify({\\n    title: 'My Amazing Page',\\n    description: 'A short description'\\n  }),\\n  content: '# Hello World'\\n});\",\n      \"language\": \"javascript\"\n    }\n  ]\n}\n[/block]","excerpt":"","slug":"create-page","type":"endpoint","title":"Create Page"}

Definition

{{ api_url }}{{ page_api_url }}

Parameters

Path Params

path:
string
Directory where the new page will be created

Body Params

page[meta]:
string
Stringified JSON that stores the page metadata
page[content]:
string
Page content in markdown

Result Format


Documentation

A filename will be created based on the title of the page. This will be in lowercase, and all spaces will be replaced with hypens and have the `.md` extension appended to the end. E.g. `Lorem Ipsum -> lorem-ipsum.md` If a file already exists with that filename, a number will be appended to it. E.g. `lorem-ipsum.md -> lorem-ipsum-1.md -> lorem-ipsum-2.md` [block:code] { "codes": [ { "code": "$.post('/api/page/foo/bar', {\n meta: JSON.stringify({\n title: 'My Amazing Page',\n description: 'A short description'\n }),\n content: '# Hello World'\n});", "language": "javascript" } ] } [/block]

User Information

Try It Out

post
{{ tryResults.results }}
Method{{ tryResults.method }}
Request Headers
{{ tryResults.requestHeaders }}
URL{{ tryResults.url }}
Request Data
{{ tryResults.data }}
Status
Response Headers
{{ tryResults.responseHeaders }}