{ "namespace": "wp/v2", "methods": [ "GET", "POST", "PUT", "PATCH", "DELETE" ], "endpoints": [ { "methods": [ "GET" ], "args": { "id": { "required": false, "description": "Unique identifier for the object.", "type": "integer" }, "context": { "required": false, "default": "view", "enum": [ "view", "embed", "edit" ], "description": "Scope under which the request is made; determines fields present in response.", "type": "string" }, "password": { "required": false, "description": "The password for the post if it is password protected.", "type": "string" } } }, { "methods": [ "POST", "PUT", "PATCH" ], "args": { "id": { "required": false, "description": "Unique identifier for the object.", "type": "integer" }, "date": { "required": false, "description": "The date the object was published, in the site's timezone.", "type": "string" }, "date_gmt": { "required": false, "description": "The date the object was published, as GMT.", "type": "string" }, "slug": { "required": false, "description": "An alphanumeric identifier for the object unique to its type.", "type": "string" }, "status": { "required": false, "enum": [ "publish", "future", "draft", "pending", "private" ], "description": "A named status for the object.", "type": "string" }, "password": { "required": false, "description": "A password to protect access to the content and excerpt.", "type": "string" }, "title": { "required": false, "description": "The title for the object.", "type": "object" }, "content": { "required": false, "description": "The content for the object.", "type": "object" }, "template": { "required": false, "description": "The theme file to use to display the object.", "type": "string" } } }, { "methods": [ "DELETE" ], "args": { "id": { "required": false, "description": "Unique identifier for the object.", "type": "integer" }, "force": { "required": false, "default": false, "description": "Whether to bypass trash and force deletion.", "type": "boolean" } } } ], "schema": { "$schema": "http://json-schema.org/draft-04/schema#", "title": "wp_block", "type": "object", "properties": { "date": { "description": "The date the object was published, in the site's timezone.", "type": "string", "format": "date-time", "context": [ "view", "edit", "embed" ] }, "date_gmt": { "description": "The date the object was published, as GMT.", "type": "string", "format": "date-time", "context": [ "view", "edit" ] }, "guid": { "description": "The globally unique identifier for the object.", "type": "object", "context": [ "view", "edit" ], "readonly": true, "properties": { "raw": { "description": "GUID for the object, as it exists in the database.", "type": "string", "context": [ "edit" ], "readonly": true }, "rendered": { "description": "GUID for the object, transformed for display.", "type": "string", "context": [ "view", "edit" ], "readonly": true } } }, "id": { "description": "Unique identifier for the object.", "type": "integer", "context": [ "view", "edit", "embed" ], "readonly": true }, "link": { "description": "URL to the object.", "type": "string", "format": "uri", "context": [ "view", "edit", "embed" ], "readonly": true }, "modified": { "description": "The date the object was last modified, in the site's timezone.", "type": "string", "format": "date-time", "context": [ "view", "edit" ], "readonly": true }, "modified_gmt": { "description": "The date the object was last modified, as GMT.", "type": "string", "format": "date-time", "context": [ "view", "edit" ], "readonly": true }, "slug": { "description": "An alphanumeric identifier for the object unique to its type.", "type": "string", "context": [ "view", "edit", "embed" ] }, "status": { "description": "A named status for the object.", "type": "string", "enum": [ "publish", "future", "draft", "pending", "private" ], "context": [ "view", "edit" ] }, "type": { "description": "Type of Post for the object.", "type": "string", "context": [ "view", "edit", "embed" ], "readonly": true }, "password": { "description": "A password to protect access to the content and excerpt.", "type": "string", "context": [ "edit" ] }, "title": { "description": "The title for the object.", "type": "object", "context": [ "view", "edit", "embed" ], "properties": { "raw": { "description": "Title for the object, as it exists in the database.", "type": "string", "context": [ "view", "edit" ] } } }, "content": { "description": "The content for the object.", "type": "object", "context": [ "view", "edit" ], "properties": { "raw": { "description": "Content for the object, as it exists in the database.", "type": "string", "context": [ "view", "edit" ] }, "block_version": { "description": "Version of the content block format used by the object.", "type": "integer", "context": [ "edit" ], "readonly": true }, "protected": { "description": "Whether the content is protected with a password.", "type": "boolean", "context": [ "view", "edit", "embed" ], "readonly": true } } }, "template": { "description": "The theme file to use to display the object.", "type": "string", "context": [ "view", "edit" ] } }, "links": [ { "rel": "https://api.w.org/action-publish", "title": "The current user can publish this post.", "href": "https://demo.wp-api.org/wp-json/wp/v2/blocks/{id}", "targetSchema": { "type": "object", "properties": { "status": { "type": "string", "enum": [ "publish", "future" ] } } } }, { "rel": "https://api.w.org/action-unfiltered-html", "title": "The current user can post unfiltered HTML markup and JavaScript.", "href": "https://demo.wp-api.org/wp-json/wp/v2/blocks/{id}", "targetSchema": { "type": "object", "properties": { "content": { "raw": { "type": "string" } } } } } ] } }