{"id":22454493,"url":"https://github.com/siteleaf/siteleaf-v1-api","last_synced_at":"2025-04-13T23:05:43.214Z","repository":{"id":8577211,"uuid":"10207652","full_name":"siteleaf/siteleaf-v1-api","owner":"siteleaf","description":"Siteleaf v1 API documentation","archived":false,"fork":false,"pushed_at":"2016-06-06T19:09:41.000Z","size":14,"stargazers_count":34,"open_issues_count":0,"forks_count":1,"subscribers_count":11,"default_branch":"master","last_synced_at":"2025-02-01T17:31:03.386Z","etag":null,"topics":["archived","documentation","siteleaf-api","siteleaf-v1"],"latest_commit_sha":null,"homepage":"http://www.siteleaf.com","language":null,"has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/siteleaf.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2013-05-21T23:31:32.000Z","updated_at":"2024-01-25T23:39:05.000Z","dependencies_parsed_at":"2022-08-29T22:51:53.611Z","dependency_job_id":null,"html_url":"https://github.com/siteleaf/siteleaf-v1-api","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/siteleaf%2Fsiteleaf-v1-api","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/siteleaf%2Fsiteleaf-v1-api/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/siteleaf%2Fsiteleaf-v1-api/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/siteleaf%2Fsiteleaf-v1-api/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/siteleaf","download_url":"https://codeload.github.com/siteleaf/siteleaf-v1-api/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":245850360,"owners_count":20682647,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["archived","documentation","siteleaf-api","siteleaf-v1"],"created_at":"2024-12-06T07:08:15.673Z","updated_at":"2025-03-27T13:16:05.823Z","avatar_url":"https://github.com/siteleaf.png","language":null,"funding_links":[],"categories":[],"sub_categories":[],"readme":"**NOTE:** These documents refer to an outdated version of Siteleaf, and are provided for archival purposes. For help with the latest version of the Siteleaf API see \u003chttp://learn.siteleaf.com/api/\u003e.\n\n# Siteleaf - API Documentation\n## API Authentication\nSiteleaf uses Basic Auth of the user's API key and secret to authenticate each request. To retrieve a user's API key and secret, use the `POST /v1/auth` endpoint, passing the user's email and password authenticated with Basic Auth.\n### Basic Auth\n```shell\ncurl -X GET -u api_key:api_secret https://api.siteleaf.com/\u003capi_endpoint\u003e\n```\n## API Endpoints\n### POST /v1/auth.json\nAuthenticates user and returns user API keys\n\n#### Request\n```shell\ncurl -X POST -u email:password https://api.siteleaf.com/v1/auth.json\n```\n\n#### Response\n```json\n{\n  \"api_key\": \"e4f5b6acae2c39079c07e35d90d87b1c\",\n  \"api_secret\": \"106afa1abf96767774bbcc4dd766d419\"\n}\n```\n\n-\n### GET /v1/ping.json\nPings the server.\n\n#### Response\n```json\n{\n  \"ping\": \"pong\"\n}\n```\n\n-\n### GET /v1/users/me.json\n\nReturns the current user.\n\n#### Response\n```json\n{\n  \"id\": \"51af47a8ef75ac5e8c000001\",\n  \"email\": \"barry@whitehouse.gov\",\n  \"firstname\": \"Barack\",\n  \"lastname\": \"Obama\",\n  \"fullname\": \"Barack Obama\",\n  \"created_at\": \"2015-06-24T10:08:20.741-04:00\",\n  \"updated_at\": \"2015-06-24T10:08:20.741-04:00\"\n}\n```\n\n-\n### GET /v1/users.json\n\nReturns array of users associated with your sites and the sites you belong to.\n\n#### Response\n```json\n[\n {\n   \"id\": \"51af47a8ef75ac5e8c000001\",\n   \"email\": \"barry@whitehouse.gov\",\n   \"firstname\": \"Barack\",\n   \"lastname\": \"Obama\",\n   \"fullname\": \"Barack Obama\",\n   \"created_at\": \"2015-06-24T10:08:20.746-04:00\",\n   \"updated_at\": \"2015-06-24T10:08:20.746-04:00\"\n }\n]\n```\n\n-\n### GET /v1/sites.json\n\nReturns an array of sites that the authenticated user belongs to.\n\n#### Params\n* **domain** *(optional)* — Site domain\n* **include** *(optional)* — Array of entities to include (`user`, `pages`, `assets`)\n\n\n#### Response\n```json\n[\n {\n   \"id\": \"51af47c1ef75acd940000002\",\n   \"title\": \"My Site\",\n   \"domain\": \"mysite.com\",\n   \"cname\": \"abcdefghijklmnopqrst-abcdefghijklmnopqrstuvwxyz123456.a1.abc.rackcdn.com\",\n   \"timezone\": \"Eastern Time (US \u0026 Canada)\",\n   \"created_at\": \"2015-06-24T10:08:20.748-04:00\",\n   \"updated_at\": \"2015-06-24T10:08:20.748-04:00\",\n   \"user_id\": \"51af47a8ef75ac5e8c000001\",\n   \"meta\": [\n \n   ]\n }\n]\n```\n\n-\n### POST /v1/sites.json\n\nCreates a site belonging to the authenticated user.\n\n#### Params\n* **title**  — Site title\n* **domain**  — Site domain\n* **timezone** *(optional)* — Site timezone\n* **meta** *(optional)* — Array of Site metadata\n\n\n#### Response\n```json\n{\n  \"id\": \"51af47c1ef75acd940000002\",\n  \"title\": \"My Site\",\n  \"domain\": \"mysite.com\",\n  \"cname\": \"abcdefghijklmnopqrst-abcdefghijklmnopqrstuvwxyz123456.a1.abc.rackcdn.com\",\n  \"timezone\": \"Eastern Time (US \u0026 Canada)\",\n  \"created_at\": \"2015-06-24T10:08:20.746-04:00\",\n  \"updated_at\": \"2015-06-24T10:08:20.746-04:00\",\n  \"user_id\": \"51af47a8ef75ac5e8c000001\",\n  \"meta\": [\n\n  ]\n}\n```\n\n-\n### GET /v1/sites/:id.json\n\nReturns the given site.\n\n#### Params\n* **include** *(optional)* — Array of entities to include (`user`, `pages`, `assets`)\n\n\n#### Response\n```json\n{\n  \"id\": \"51af47c1ef75acd940000002\",\n  \"title\": \"My Site\",\n  \"domain\": \"mysite.com\",\n  \"cname\": \"abcdefghijklmnopqrst-abcdefghijklmnopqrstuvwxyz123456.a1.abc.rackcdn.com\",\n  \"timezone\": \"Eastern Time (US \u0026 Canada)\",\n  \"created_at\": \"2015-06-24T10:08:20.746-04:00\",\n  \"updated_at\": \"2015-06-24T10:08:20.746-04:00\",\n  \"user_id\": \"51af47a8ef75ac5e8c000001\",\n  \"meta\": [\n\n  ]\n}\n```\n\n-\n### PUT /v1/sites/:id.json\n\nUpdates the given site.\n\n#### Params\n* **title** *(optional)* — Site title\n* **domain** *(optional)* — Site domain\n* **timezone** *(optional)* — Site timezone\n* **meta** *(optional)* — Array of Site metadata\n* **hosting** *(optional)* — Site hosting (`siteleaf`, `ftp`, `s3`, `cloudfiles`, `github`)\n* **ftp_settings** *(optional)* — Site FTP settings (see hosting settings)\n* **s3_settings** *(optional)* — Site S3 settings (see hosting settings)\n* **cloudfiles_settings** *(optional)* — Site Cloudfiles settings (see hosting settings)\n* **github_settings** *(optional)* — Site GitHub settings (see hosting settings)\n* **user_id** *(optional)* — Site owner ID (must have role)\n\n\n#### Response\n```json\n{\n  \"id\": \"51af47c1ef75acd940000002\",\n  \"title\": \"My Site\",\n  \"domain\": \"mysite.com\",\n  \"cname\": \"abcdefghijklmnopqrst-abcdefghijklmnopqrstuvwxyz123456.a1.abc.rackcdn.com\",\n  \"timezone\": \"Eastern Time (US \u0026 Canada)\",\n  \"created_at\": \"2015-06-24T10:08:20.746-04:00\",\n  \"updated_at\": \"2015-06-24T10:08:20.746-04:00\",\n  \"user_id\": \"51af47a8ef75ac5e8c000001\",\n  \"meta\": [\n\n  ]\n}\n```\n\n-\n### DELETE /v1/sites/:id.json\n\nDeletes the given site.\n\n-\n### POST /v1/sites/:id/publish.json\n\nPublishes the site in the background and returns a job id.\nCheck it's status at GET /v1/jobs/:job_id\n\n#### Response\n```json\n{\n  \"job_id\": \"abcdef0123456789abcdef01\"\n}\n```\n\n-\n### GET /v1/sites/:id/pages.json\n\nReturns an array of all pages for the given site.\n\n#### Params\n* **include** *(optional)* — Array of entities to include (`user`, `site`, `parent`, `pages`, `posts`, `assets`)\n\n\n#### Response\n```json\n[\n {\n   \"id\": \"51a39a57ef75ac7634000006\",\n   \"title\": \"My Content\",\n   \"slug\": \"my-content\",\n   \"url\": \"/pages/my-content\",\n   \"body\": \"This is *my* content\",\n   \"visibility\": \"draft\",\n   \"created_at\": \"2015-06-24T10:08:20.751-04:00\",\n   \"updated_at\": \"2015-06-24T10:08:20.751-04:00\",\n   \"published_at\": \"2015-06-24T10:08:20.751-04:00\",\n   \"user_id\": \"51af47a8ef75ac5e8c000001\",\n   \"site_id\": \"51af47c1ef75acd940000002\",\n   \"parent_id\": \"51a39a57ef75ac7634000005\",\n   \"meta\": [\n \n   ]\n }\n]\n```\n\n-\n### POST /v1/sites/:id/pages.json\n\nCreates a page on the given site.\n\n#### Params\n* **title**  — Page title\n* **body** *(optional)* — Page body\n* **custom_slug** *(optional)* — Page custom slug\n* **published_at** *(optional)* — Page published date\n* **visibility** *(optional)* — Page visibility (`draft`, `hidden`, `visible`)\n* **user_id** *(optional)* — Page author ID\n* **parent_id** *(optional)* — Page parent ID\n* **meta** *(optional)* — Array of Page metadata\n* **asset_ids** *(optional)* — Array of existing Asset IDs\n\n\n#### Response\n```json\n{\n  \"id\": \"51a39a57ef75ac7634000006\",\n  \"title\": \"My Content\",\n  \"slug\": \"my-content\",\n  \"url\": \"/pages/my-content\",\n  \"body\": \"This is *my* content\",\n  \"visibility\": \"draft\",\n  \"created_at\": \"2015-06-24T10:08:20.749-04:00\",\n  \"updated_at\": \"2015-06-24T10:08:20.749-04:00\",\n  \"published_at\": \"2015-06-24T10:08:20.749-04:00\",\n  \"user_id\": \"51af47a8ef75ac5e8c000001\",\n  \"site_id\": \"51af47c1ef75acd940000002\",\n  \"parent_id\": \"51a39a57ef75ac7634000005\",\n  \"meta\": [\n\n  ]\n}\n```\n\n-\n### PUT /v1/sites/:id/pages.json\n\nRepositions pages on the given site.\n\n#### Params\n* **ids**  — Nested JSON array of Page IDs and their children\n\n\n#### Request\n\n```shell\ncurl -u API_KEY:API_SECRET \\\n  -X PUT \\\n  -d 'ids=[{\"id\":\"51a38...\"},{\"id\":\"51a15...\",\"children\":[{\"id\":\"51a39...\"},{\"id\":\"51a40...\"}]}]' \\\n  https://api.siteleaf.com/v1/sites/51a158a8ef75ac1ada000001/pages\n```\n\n#### Response\n```json\n[\n {\n   \"id\": \"51a39a57ef75ac7634000006\",\n   \"title\": \"My Content\",\n   \"slug\": \"my-content\",\n   \"url\": \"/pages/my-content\",\n   \"body\": \"This is *my* content\",\n   \"visibility\": \"draft\",\n   \"created_at\": \"2015-06-24T10:08:20.751-04:00\",\n   \"updated_at\": \"2015-06-24T10:08:20.751-04:00\",\n   \"published_at\": \"2015-06-24T10:08:20.751-04:00\",\n   \"user_id\": \"51af47a8ef75ac5e8c000001\",\n   \"site_id\": \"51af47c1ef75acd940000002\",\n   \"parent_id\": \"51a39a57ef75ac7634000005\",\n   \"meta\": [\n \n   ]\n }\n]\n```\n\n-\n### GET /v1/sites/:id/posts.json\n\nReturns an array of all posts for the given site.\n\n#### Params\n* **include** *(optional)* — Array of entities to include (`user`, `site`, `parent`, `assets`)\n\n\n#### Response\n```json\n[\n {\n   \"id\": \"51a39a57ef75ac7634000006\",\n   \"title\": \"My Content\",\n   \"slug\": \"my-content\",\n   \"url\": \"/pages/my-content\",\n   \"body\": \"This is *my* content\",\n   \"visibility\": \"draft\",\n   \"created_at\": \"2015-06-24T10:08:20.754-04:00\",\n   \"updated_at\": \"2015-06-24T10:08:20.754-04:00\",\n   \"published_at\": \"2015-06-24T10:08:20.754-04:00\",\n   \"user_id\": \"51af47a8ef75ac5e8c000001\",\n   \"site_id\": \"51af47c1ef75acd940000002\",\n   \"parent_id\": \"51a39a57ef75ac7634000005\",\n   \"meta\": [\n \n   ]\n }\n]\n```\n\n-\n### GET /v1/sites/:id/assets.json\n\nReturns an array of all assets for the given site.\n\n#### Response\n```json\n[\n {\n   \"id\": \"51a39a57ef75ac7634000009\",\n   \"filename\": \"my-file.gif\",\n   \"url\": \"/assets/my-file.gif\",\n   \"permalink\": \"http://mysite.com/assets/my-file.gif\",\n   \"file\": {\n     \"url\": null,\n     \"thumbnail\": {\n       \"url\": null\n     }\n   },\n   \"content_type\": \"image/gif\",\n   \"filesize\": 23856,\n   \"checksum\": \"9187a6775bdce8f1f2143accea89ba6c\",\n   \"created_at\": \"2015-06-24T10:08:20.841-04:00\",\n   \"updated_at\": \"2015-06-24T10:08:20.841-04:00\",\n   \"meta\": [\n \n   ]\n }\n]\n```\n\n-\n### POST /v1/sites/:id/assets.json\n\nCreates an asset on the given site.\n\n#### Params\n* **file** *(optional)* — Asset file\n* **url** *(optional)* — Asset remote URL\n* **meta** *(optional)* — Array of Asset metadata\n\n\n#### Response\n```json\n{\n  \"id\": \"51a39a57ef75ac7634000009\",\n  \"filename\": \"my-file.gif\",\n  \"url\": \"/assets/my-file.gif\",\n  \"permalink\": \"http://mysite.com/assets/my-file.gif\",\n  \"file\": {\n    \"url\": null,\n    \"thumbnail\": {\n      \"url\": null\n    }\n  },\n  \"content_type\": \"image/gif\",\n  \"filesize\": 23856,\n  \"checksum\": \"9187a6775bdce8f1f2143accea89ba6c\",\n  \"created_at\": \"2015-06-24T10:08:20.756-04:00\",\n  \"updated_at\": \"2015-06-24T10:08:20.756-04:00\",\n  \"meta\": [\n\n  ]\n}\n```\n\n-\n### GET /v1/sites/:id/users.json\n\nReturns an array of users for the given site.\n\n#### Response\n```json\n[\n {\n   \"id\": \"51af47a8ef75ac5e8c000001\",\n   \"email\": \"barry@whitehouse.gov\",\n   \"firstname\": \"Barack\",\n   \"lastname\": \"Obama\",\n   \"fullname\": \"Barack Obama\",\n   \"created_at\": \"2015-06-24T10:08:20.746-04:00\",\n   \"updated_at\": \"2015-06-24T10:08:20.746-04:00\"\n }\n]\n```\n\n-\n### GET /v1/pages.json\n\nReturns an array of Pages created by the authenticated user.\n\n#### Params\n* **include** *(optional)* — Array of entities to include (`user`, `site`, `parent`, `pages`, `posts`, `assets`)\n\n\n#### Response\n```json\n[\n {\n   \"id\": \"51a39a57ef75ac7634000006\",\n   \"title\": \"My Content\",\n   \"slug\": \"my-content\",\n   \"url\": \"/pages/my-content\",\n   \"body\": \"This is *my* content\",\n   \"visibility\": \"draft\",\n   \"created_at\": \"2015-06-24T10:08:20.751-04:00\",\n   \"updated_at\": \"2015-06-24T10:08:20.751-04:00\",\n   \"published_at\": \"2015-06-24T10:08:20.751-04:00\",\n   \"user_id\": \"51af47a8ef75ac5e8c000001\",\n   \"site_id\": \"51af47c1ef75acd940000002\",\n   \"parent_id\": \"51a39a57ef75ac7634000005\",\n   \"meta\": [\n \n   ]\n }\n]\n```\n\n-\n### GET /v1/pages/:id.json\n\nReturns the given page.\n\n#### Params\n* **include** *(optional)* — Array of entities to include (`user`, `site`, `parent`, `pages`, `posts`, `assets`)\n\n\n#### Response\n```json\n{\n  \"id\": \"51a39a57ef75ac7634000006\",\n  \"title\": \"My Content\",\n  \"slug\": \"my-content\",\n  \"url\": \"/pages/my-content\",\n  \"body\": \"This is *my* content\",\n  \"visibility\": \"draft\",\n  \"created_at\": \"2015-06-24T10:08:20.749-04:00\",\n  \"updated_at\": \"2015-06-24T10:08:20.749-04:00\",\n  \"published_at\": \"2015-06-24T10:08:20.749-04:00\",\n  \"user_id\": \"51af47a8ef75ac5e8c000001\",\n  \"site_id\": \"51af47c1ef75acd940000002\",\n  \"parent_id\": \"51a39a57ef75ac7634000005\",\n  \"meta\": [\n\n  ]\n}\n```\n\n-\n### PUT /v1/pages/:id.json\n\nUpdates the given page.\n\n#### Params\n* **title** *(optional)* — Page title\n* **body** *(optional)* — Page body\n* **custom_slug** *(optional)* — Page slug\n* **published_at** *(optional)* — Page published date\n* **visibility** *(optional)* — Page visibility (`draft`, `hidden`, `visible`)\n* **user_id** *(optional)* — Page author ID\n* **parent_id** *(optional)* — Page parent ID\n* **meta** *(optional)* — Array of Page Metadata (see Metadata)\n* **position** *(optional)* — Position of page\n\n\n#### Response\n```json\n{\n  \"id\": \"51a39a57ef75ac7634000006\",\n  \"title\": \"My Content\",\n  \"slug\": \"my-content\",\n  \"url\": \"/pages/my-content\",\n  \"body\": \"This is *my* content\",\n  \"visibility\": \"draft\",\n  \"created_at\": \"2015-06-24T10:08:20.749-04:00\",\n  \"updated_at\": \"2015-06-24T10:08:20.749-04:00\",\n  \"published_at\": \"2015-06-24T10:08:20.749-04:00\",\n  \"user_id\": \"51af47a8ef75ac5e8c000001\",\n  \"site_id\": \"51af47c1ef75acd940000002\",\n  \"parent_id\": \"51a39a57ef75ac7634000005\",\n  \"meta\": [\n\n  ]\n}\n```\n\n-\n### DELETE /v1/pages/:id.json\n\nDeletes the given page.\n\n-\n### GET /v1/pages/:id/posts.json\n\nReturns an array of posts on the given page.\n\n#### Params\n* **offset** *(optional)* — Number of Posts to offset\n* **count** *(optional)* — Number of Posts to return\n* **include** *(optional)* — Array of entities to include (`user`, `site`, `parent`, `assets`)\n\n\n#### Response\n```json\n[\n {\n   \"id\": \"51a39a57ef75ac7634000006\",\n   \"title\": \"My Content\",\n   \"slug\": \"my-content\",\n   \"url\": \"/pages/my-content\",\n   \"body\": \"This is *my* content\",\n   \"visibility\": \"draft\",\n   \"created_at\": \"2015-06-24T10:08:20.754-04:00\",\n   \"updated_at\": \"2015-06-24T10:08:20.754-04:00\",\n   \"published_at\": \"2015-06-24T10:08:20.754-04:00\",\n   \"user_id\": \"51af47a8ef75ac5e8c000001\",\n   \"site_id\": \"51af47c1ef75acd940000002\",\n   \"parent_id\": \"51a39a57ef75ac7634000005\",\n   \"meta\": [\n \n   ]\n }\n]\n```\n\n-\n### POST /v1/pages/:id/posts.json\n\nCreates a post on the given page.\n\n#### Params\n* **title**  — Post title\n* **body** *(optional)* — Post body\n* **custom_slug** *(optional)* — Post custom slug\n* **published_at** *(optional)* — Post published date\n* **visibility** *(optional)* — Post visibility\n* **user_id** *(optional)* — Post author ID\n* **meta** *(optional)* — Array of Taxonomy\n* **taxonomy** *(optional)* — Array of Metadata\n* **asset_ids** *(optional)* — Array of Asset IDs\n\n\n#### Response\n```json\n{\n  \"id\": \"51a39a57ef75ac7634000006\",\n  \"title\": \"My Content\",\n  \"slug\": \"my-content\",\n  \"url\": \"/pages/my-content\",\n  \"body\": \"This is *my* content\",\n  \"visibility\": \"draft\",\n  \"created_at\": \"2015-06-24T10:08:20.752-04:00\",\n  \"updated_at\": \"2015-06-24T10:08:20.752-04:00\",\n  \"published_at\": \"2015-06-24T10:08:20.753-04:00\",\n  \"user_id\": \"51af47a8ef75ac5e8c000001\",\n  \"site_id\": \"51af47c1ef75acd940000002\",\n  \"parent_id\": \"51a39a57ef75ac7634000005\",\n  \"meta\": [\n\n  ]\n}\n```\n\n-\n### GET /v1/pages/:id/assets.json\n\nReturns an array of assets on the given page.\n\n#### Response\n```json\n[\n {\n   \"id\": \"51a39a57ef75ac7634000009\",\n   \"filename\": \"my-file.gif\",\n   \"url\": \"/assets/my-file.gif\",\n   \"permalink\": \"http://mysite.com/assets/my-file.gif\",\n   \"file\": {\n     \"url\": null,\n     \"thumbnail\": {\n       \"url\": null\n     }\n   },\n   \"content_type\": \"image/gif\",\n   \"filesize\": 23856,\n   \"checksum\": \"9187a6775bdce8f1f2143accea89ba6c\",\n   \"created_at\": \"2015-06-24T10:08:20.841-04:00\",\n   \"updated_at\": \"2015-06-24T10:08:20.841-04:00\",\n   \"meta\": [\n \n   ]\n }\n]\n```\n\n-\n### POST /v1/pages/:id/assets.json\n\nCreates an asset on the given page.\n\n#### Params\n* **file** *(optional)* — Asset file\n* **url** *(optional)* — Asset remote URL\n* **meta** *(optional)* — Array of Asset metadata\n\n\n#### Response\n```json\n{\n  \"id\": \"51a39a57ef75ac7634000009\",\n  \"filename\": \"my-file.gif\",\n  \"url\": \"/assets/my-file.gif\",\n  \"permalink\": \"http://mysite.com/assets/my-file.gif\",\n  \"file\": {\n    \"url\": null,\n    \"thumbnail\": {\n      \"url\": null\n    }\n  },\n  \"content_type\": \"image/gif\",\n  \"filesize\": 23856,\n  \"checksum\": \"9187a6775bdce8f1f2143accea89ba6c\",\n  \"created_at\": \"2015-06-24T10:08:20.756-04:00\",\n  \"updated_at\": \"2015-06-24T10:08:20.756-04:00\",\n  \"meta\": [\n\n  ]\n}\n```\n\n-\n### PUT /v1/pages/:id/assets.json\n\nRepositions assets on the given page.\n\n#### Params\n* **ids**  — Array of Asset IDs\n\n\n#### Response\n```json\n[\n {\n   \"id\": \"51a39a57ef75ac7634000009\",\n   \"filename\": \"my-file.gif\",\n   \"url\": \"/assets/my-file.gif\",\n   \"permalink\": \"http://mysite.com/assets/my-file.gif\",\n   \"file\": {\n     \"url\": null,\n     \"thumbnail\": {\n       \"url\": null\n     }\n   },\n   \"content_type\": \"image/gif\",\n   \"filesize\": 23856,\n   \"checksum\": \"9187a6775bdce8f1f2143accea89ba6c\",\n   \"created_at\": \"2015-06-24T10:08:20.841-04:00\",\n   \"updated_at\": \"2015-06-24T10:08:20.841-04:00\",\n   \"meta\": [\n \n   ]\n }\n]\n```\n\n-\n### POST /v1/pages/:id/meta.json\n\nCreates metadata on the given page.\n\n#### Params\n* **key**  — Metadata key\n* **value**  — Metadata value\n\n\n#### Response\n```json\n{\n  \"id\": \"51a39a57ef75ac7634000011\",\n  \"key\": \"color\",\n  \"value\": \"blue\"\n}\n```\n\n-\n### GET /v1/posts.json\n\nReturns an array of posts created by the authenticated user.\n\n#### Params\n* **include** *(optional)* — Array of entities to include (`user`, `site`, `parent`, `assets`)\n\n\n#### Response\n```json\n[\n {\n   \"id\": \"51a39a57ef75ac7634000006\",\n   \"title\": \"My Content\",\n   \"slug\": \"my-content\",\n   \"url\": \"/pages/my-content\",\n   \"body\": \"This is *my* content\",\n   \"visibility\": \"draft\",\n   \"created_at\": \"2015-06-24T10:08:20.754-04:00\",\n   \"updated_at\": \"2015-06-24T10:08:20.754-04:00\",\n   \"published_at\": \"2015-06-24T10:08:20.754-04:00\",\n   \"user_id\": \"51af47a8ef75ac5e8c000001\",\n   \"site_id\": \"51af47c1ef75acd940000002\",\n   \"parent_id\": \"51a39a57ef75ac7634000005\",\n   \"meta\": [\n \n   ]\n }\n]\n```\n\n-\n### GET /v1/posts/:id.json\n\nReturns the given post.\n\n#### Params\n* **include** *(optional)* — Array of entities to include (`user`, `site`, `parent`, `assets`)\n\n\n#### Response\n```json\n{\n  \"id\": \"51a39a57ef75ac7634000006\",\n  \"title\": \"My Content\",\n  \"slug\": \"my-content\",\n  \"url\": \"/pages/my-content\",\n  \"body\": \"This is *my* content\",\n  \"visibility\": \"draft\",\n  \"created_at\": \"2015-06-24T10:08:20.752-04:00\",\n  \"updated_at\": \"2015-06-24T10:08:20.752-04:00\",\n  \"published_at\": \"2015-06-24T10:08:20.753-04:00\",\n  \"user_id\": \"51af47a8ef75ac5e8c000001\",\n  \"site_id\": \"51af47c1ef75acd940000002\",\n  \"parent_id\": \"51a39a57ef75ac7634000005\",\n  \"meta\": [\n\n  ]\n}\n```\n\n-\n### PUT /v1/posts/:id.json\n\nUpdates the given post.\n\n#### Params\n* **title** *(optional)* — Post title\n* **body** *(optional)* — Post body\n* **custom_slug** *(optional)* — Post custom slug\n* **published_at** *(optional)* — Post published date\n* **visibility** *(optional)* — Post visibility (`draft`, `hidden`, `visible`)\n* **parent_id** *(optional)* — Post parent ID\n* **user_id** *(optional)* — Post author ID\n* **meta** *(optional)* — Array of Metadata\n* **taxonomy** *(optional)* — Array of Taxonomy\n\n\n#### Response\n```json\n{\n  \"id\": \"51a39a57ef75ac7634000006\",\n  \"title\": \"My Content\",\n  \"slug\": \"my-content\",\n  \"url\": \"/pages/my-content\",\n  \"body\": \"This is *my* content\",\n  \"visibility\": \"draft\",\n  \"created_at\": \"2015-06-24T10:08:20.752-04:00\",\n  \"updated_at\": \"2015-06-24T10:08:20.752-04:00\",\n  \"published_at\": \"2015-06-24T10:08:20.753-04:00\",\n  \"user_id\": \"51af47a8ef75ac5e8c000001\",\n  \"site_id\": \"51af47c1ef75acd940000002\",\n  \"parent_id\": \"51a39a57ef75ac7634000005\",\n  \"meta\": [\n\n  ]\n}\n```\n\n-\n### DELETE /v1/posts/:id.json\n\nDeletes the given post.\n\n-\n### POST /v1/posts/:id/taxonomy.json\n\nCreates taxonomy on the given post.\n\n#### Params\n* **key**  — Taxonomy key\n* **values**  — Array of values\n\n\n#### Response\n```json\n{\n  \"id\": \"51a39a57ef75ac7634000007\",\n  \"key\": \"Tags\",\n  \"slug\": \"tags\",\n  \"values\": [\n    {\n      \"value\": \"Announcement\",\n      \"slug\": \"announcement\",\n      \"url\": \"/blog/tags/announcement\"\n    }\n  ]\n}\n```\n\n-\n### GET /v1/posts/:id/assets.json\n\nReturns an array of assets on the given post.\n\n#### Response\n```json\n[\n {\n   \"id\": \"51a39a57ef75ac7634000009\",\n   \"filename\": \"my-file.gif\",\n   \"url\": \"/assets/my-file.gif\",\n   \"permalink\": \"http://mysite.com/assets/my-file.gif\",\n   \"file\": {\n     \"url\": null,\n     \"thumbnail\": {\n       \"url\": null\n     }\n   },\n   \"content_type\": \"image/gif\",\n   \"filesize\": 23856,\n   \"checksum\": \"9187a6775bdce8f1f2143accea89ba6c\",\n   \"created_at\": \"2015-06-24T10:08:20.841-04:00\",\n   \"updated_at\": \"2015-06-24T10:08:20.841-04:00\",\n   \"meta\": [\n \n   ]\n }\n]\n```\n\n-\n### POST /v1/posts/:id/assets.json\n\nCreates an asset on the given post.\n\n#### Params\n* **file** *(optional)* — Asset file\n* **url** *(optional)* — Asset remote URL\n* **meta** *(optional)* — Array of Asset metadata\n\n\n#### Response\n```json\n{\n  \"id\": \"51a39a57ef75ac7634000009\",\n  \"filename\": \"my-file.gif\",\n  \"url\": \"/assets/my-file.gif\",\n  \"permalink\": \"http://mysite.com/assets/my-file.gif\",\n  \"file\": {\n    \"url\": null,\n    \"thumbnail\": {\n      \"url\": null\n    }\n  },\n  \"content_type\": \"image/gif\",\n  \"filesize\": 23856,\n  \"checksum\": \"9187a6775bdce8f1f2143accea89ba6c\",\n  \"created_at\": \"2015-06-24T10:08:20.756-04:00\",\n  \"updated_at\": \"2015-06-24T10:08:20.756-04:00\",\n  \"meta\": [\n\n  ]\n}\n```\n\n-\n### PUT /v1/posts/:id/assets.json\n\nRepositions assets on the given post.\n\n#### Params\n* **ids**  — Array of Asset IDs\n\n\n#### Response\n```json\n[\n {\n   \"id\": \"51a39a57ef75ac7634000009\",\n   \"filename\": \"my-file.gif\",\n   \"url\": \"/assets/my-file.gif\",\n   \"permalink\": \"http://mysite.com/assets/my-file.gif\",\n   \"file\": {\n     \"url\": null,\n     \"thumbnail\": {\n       \"url\": null\n     }\n   },\n   \"content_type\": \"image/gif\",\n   \"filesize\": 23856,\n   \"checksum\": \"9187a6775bdce8f1f2143accea89ba6c\",\n   \"created_at\": \"2015-06-24T10:08:20.841-04:00\",\n   \"updated_at\": \"2015-06-24T10:08:20.841-04:00\",\n   \"meta\": [\n \n   ]\n }\n]\n```\n\n-\n### GET /v1/taxonomy/:id.json\n\nReturns the given taxonomy.\n\n#### Response\n```json\n{\n  \"id\": \"51a39a57ef75ac7634000007\",\n  \"key\": \"Tags\",\n  \"slug\": \"tags\",\n  \"values\": [\n    {\n      \"value\": \"Announcement\",\n      \"slug\": \"announcement\",\n      \"url\": \"/blog/tags/announcement\"\n    }\n  ]\n}\n```\n\n-\n### PUT /v1/taxonomy/:id.json\n\nUpdates the given taxonomy.\n\n#### Params\n* **key** *(optional)* — Taxonomy key\n* **values** *(optional)* — Array of values\n\n\n#### Response\n```json\n{\n  \"id\": \"51a39a57ef75ac7634000007\",\n  \"key\": \"Tags\",\n  \"slug\": \"tags\",\n  \"values\": [\n    {\n      \"value\": \"Announcement\",\n      \"slug\": \"announcement\",\n      \"url\": \"/blog/tags/announcement\"\n    }\n  ]\n}\n```\n\n-\n### DELETE /v1/taxonomy/:id.json\n\nDeletes the given taxonomy.\n\n-\n### GET /v1/assets/:id.json\n\nReturns the given asset.\n\n#### Response\n```json\n{\n  \"id\": \"51a39a57ef75ac7634000009\",\n  \"filename\": \"my-file.gif\",\n  \"url\": \"/assets/my-file.gif\",\n  \"permalink\": \"http://mysite.com/assets/my-file.gif\",\n  \"file\": {\n    \"url\": null,\n    \"thumbnail\": {\n      \"url\": null\n    }\n  },\n  \"content_type\": \"image/gif\",\n  \"filesize\": 23856,\n  \"checksum\": \"9187a6775bdce8f1f2143accea89ba6c\",\n  \"created_at\": \"2015-06-24T10:08:20.756-04:00\",\n  \"updated_at\": \"2015-06-24T10:08:20.756-04:00\",\n  \"meta\": [\n\n  ]\n}\n```\n\n-\n### PUT /v1/assets/:id.json\n\nUpdates the given asset.\n\n#### Params\n* **filename** *(optional)* — Asset filename\n* **meta** *(optional)* — Array of Metadata\n\n\n#### Response\n```json\n{\n  \"id\": \"51a39a57ef75ac7634000009\",\n  \"filename\": \"my-file.gif\",\n  \"url\": \"/assets/my-file.gif\",\n  \"permalink\": \"http://mysite.com/assets/my-file.gif\",\n  \"file\": {\n    \"url\": null,\n    \"thumbnail\": {\n      \"url\": null\n    }\n  },\n  \"content_type\": \"image/gif\",\n  \"filesize\": 23856,\n  \"checksum\": \"9187a6775bdce8f1f2143accea89ba6c\",\n  \"created_at\": \"2015-06-24T10:08:20.756-04:00\",\n  \"updated_at\": \"2015-06-24T10:08:20.756-04:00\",\n  \"meta\": [\n\n  ]\n}\n```\n\n-\n### DELETE /v1/assets/:id.json\n\nDeletes the given asset.\n\n-\n### PUT /v1/assets/:id/restore.json\n\nRestores the given deleted asset.\n\n#### Response\n```json\n{\n  \"id\": \"51a39a57ef75ac7634000009\",\n  \"filename\": \"my-file.gif\",\n  \"url\": \"/assets/my-file.gif\",\n  \"permalink\": \"http://mysite.com/assets/my-file.gif\",\n  \"file\": {\n    \"url\": null,\n    \"thumbnail\": {\n      \"url\": null\n    }\n  },\n  \"content_type\": \"image/gif\",\n  \"filesize\": 23856,\n  \"checksum\": \"9187a6775bdce8f1f2143accea89ba6c\",\n  \"created_at\": \"2015-06-24T10:08:20.756-04:00\",\n  \"updated_at\": \"2015-06-24T10:08:20.756-04:00\",\n  \"meta\": [\n\n  ]\n}\n```\n\n-\n### GET /v1/sites/:site_id/theme/assets.json\n\nReturns an array of all theme assets for the given site.\n\n#### Response\n```json\n[\n {\n   \"id\": \"51a39a57ef75ac7634000009\",\n   \"filename\": \"my-file.gif\",\n   \"url\": \"/assets/my-file.gif\",\n   \"permalink\": \"http://mysite.com/assets/my-file.gif\",\n   \"file\": {\n     \"url\": null,\n     \"thumbnail\": {\n       \"url\": null\n     }\n   },\n   \"content_type\": \"image/gif\",\n   \"filesize\": 23856,\n   \"checksum\": \"9187a6775bdce8f1f2143accea89ba6c\",\n   \"created_at\": \"2015-06-24T10:08:20.841-04:00\",\n   \"updated_at\": \"2015-06-24T10:08:20.841-04:00\",\n   \"meta\": [\n \n   ]\n }\n]\n```\n\n-\n### POST /v1/sites/:site_id/theme/assets.json\n\nCreates a theme asset on the given site.\n\n#### Params\n* **file**  — Theme asset file\n* **filename** *(optional)* — Theme asset filename\n* **replace** *(optional)* — Should file replace theme?\n\n\n#### Response\n```json\n{\n  \"id\": \"51a39a57ef75ac7634000009\",\n  \"filename\": \"my-file.gif\",\n  \"url\": \"/assets/my-file.gif\",\n  \"permalink\": \"http://mysite.com/assets/my-file.gif\",\n  \"file\": {\n    \"url\": null,\n    \"thumbnail\": {\n      \"url\": null\n    }\n  },\n  \"content_type\": \"image/gif\",\n  \"filesize\": 23856,\n  \"checksum\": \"9187a6775bdce8f1f2143accea89ba6c\",\n  \"created_at\": \"2015-06-24T10:08:20.756-04:00\",\n  \"updated_at\": \"2015-06-24T10:08:20.756-04:00\",\n  \"meta\": [\n\n  ]\n}\n```\n\n-\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsiteleaf%2Fsiteleaf-v1-api","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsiteleaf%2Fsiteleaf-v1-api","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsiteleaf%2Fsiteleaf-v1-api/lists"}