ylletjs / wp-rest-api-routes

Exposing rewrite rules through the REST API

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Routes endpoint

Build Status

Exposing rewrite rules through the REST API.

New endpoint:

/wp-json/wp/v2/routes

Example response:

[
  {
	  "path": "^wp-json\/?$",
	  "type": "unknown"
  },
  {
	  "path": "^wp-json\/(.*)?",
	  "type": "unknown"
  },
  {
	  "path": "^index.php\/wp-json\/?$",
	  "type": "unknown"
  },
  {
	  "path": "^index.php\/wp-json\/(.*)?",
	  "type": "unknown"
  },
  {
	  "path": "blog\/category\/(.+?)\/feed\/(feed|rdf|rss|rss2|atom)\/?$",
	  "type": "category"
  },
  {
	  "path": "blog\/category\/(.+?)\/(feed|rdf|rss|rss2|atom)\/?$",
	  "type": "category"
  }
]

Installation

composer require ylletjs/wp-rest-api-routes

License

MIT © Fredrik Forsmo

About

Exposing rewrite rules through the REST API

License:MIT License


Languages

Language:PHP 98.0%Language:Makefile 2.0%