WordPress.org

Make WordPress Core

Opened 4 weeks ago

Closed 4 days ago

#50321 closed enhancement (fixed)

REST API: Add plugin and block directory endpoints

Reported by: TimothyBlynJacobs Owned by: TimothyBlynJacobs
Milestone: 5.5 Priority: high
Severity: normal Version: 4.7
Component: REST API Keywords: has-patch has-unit-tests
Focuses: Cc:

Description

Gutenberg is introducing REST API endpoints for installing blocks, and activating/deactivating plugins. This is a tracking ticket for handling the core merge of this feature.

https://github.com/WordPress/gutenberg/pull/22454

Change History (9)

#1 @TimothyBlynJacobs
4 weeks ago

  • Owner set to TimothyBlynJacobs
  • Status changed from new to reviewing

This ticket was mentioned in Slack in #core-restapi by timothybjacobs. View the logs.


4 weeks ago

This ticket was mentioned in PR #359 on WordPress/wordpress-develop by TimothyBJacobs.


10 days ago

  • Keywords has-patch has-unit-tests added

Original Gutenberg PR: https://github.com/WordPress/gutenberg/pull/22454

This also introduces a change in plugins_api to not perform a trigger error if this is a json request since we don't want that to break the JSON output.

Trac ticket: https://core.trac.wordpress.org/ticket/50321

#4 @TimothyBlynJacobs
10 days ago

  • Type changed from defect (bug) to enhancement

#5 @prbot
9 days ago

TimothyBJacobs commented on PR #359:

We'll also need a PR to update Gutenberg to use the wp/v2 namespace.

#6 @prbot
9 days ago

ellatrix commented on PR #359:

@TimothyBJacobs Can we keep everything experimental? Or are these APIs fully ready?

#7 @prbot
9 days ago

TimothyBJacobs commented on PR #359:

Thoughts on shipping experimental endpoints in core are [mixed](https://make.wordpress.org/core/2020/06/14/shipping-experimental-endpoints-in-core-rest-api-meeting-summary-june-11-2020/) so I'm not really sure about shipping experimental endpoints in general.

For this endpoint in particular, I don't think it needs to be shipped as experimental.

#8 @prbot
9 days ago

ryelle commented on PR #359:

Created a PR for updating the namespaces in Gutenberg: https://github.com/WordPress/gutenberg/pull/23528

I tested out the endpoints, and once I got this PR done , I was able to test out using the block directory — it all worked as expected.

#9 @TimothyBlynJacobs
4 days ago

  • Resolution set to fixed
  • Status changed from reviewing to closed

In 48242:

REST API: Introduce plugin management and block directory endpoints.

These endpoints facilitate the Block Directory Inserter feature in Gutenberg. Users can now install, activate, deactivate, and delete plugins over the REST API. The block directoryendpoint allows searching for available blocks from the WordPress.org block directory.

Props cklee, talldanwp, noisysocks, joen, soean, youknowriad, dufresnesteven, gziolo, dd32, tellyworth, ryelle, spacedmonkey, TimothyBlynJacobs.
Fixes #50321.

Note: See TracTickets for help on using tickets.