Skip to content

Conversation

@itsmeichigo
Copy link
Contributor

@itsmeichigo itsmeichigo commented Jan 18, 2023

Closes: #8677

Description

This PR enables REST API on the site plugin fetching endpoint and updates the related mapper to parse contents without the data envelope. I'm not updating the other endpoints for site plugins since we are not handling Jetpack installation for JCP sites when logging in with WPOrg credentials.

Testing instructions

  • Enable the feature flag applicationPasswordAuthenticationForSiteCredentialLogin and build the app.
  • On the prologue screen, select Enter your site address and proceed with the address of your test store.
  • Log in with your site credentials. After the login succeeds, you should be navigated to the home screen.
  • Navigate to Menu tab and select Settings.
  • Select Plugins - all the site's plugin should be listed if your account is a shop administrator. Otherwise, the list will not be displayed.

Screenshots


  • I have considered if this change warrants user-facing release notes and have added them to RELEASE-NOTES.txt if necessary.

@itsmeichigo itsmeichigo added type: task An internally driven task. feature: REST API Authenticating requests using application password and using REST API instead of Jetpack tunnel. labels Jan 18, 2023
@itsmeichigo itsmeichigo added this to the 12.0 milestone Jan 18, 2023
@wpmobilebot
Copy link
Collaborator

You can test the changes from this Pull Request by:
  • Clicking here or scanning the QR code below to access App Center
  • Then installing the build number pr8678-b57abd9 on your iPhone

If you need access to App Center, please ask a maintainer to add you.

@jaclync jaclync self-assigned this Jan 19, 2023
Copy link
Contributor

@jaclync jaclync left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 🚀 Didn't see the plugins section in settings at first, after looking into the code it was because the user wasn't an admin.

siteID: siteID,
path: path,
parameters: nil,
availableAsRESTRequest: true)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The PR description mentioned that other endpoints aren't converted because we're not supporting Jetpack installation for REST login. I remember we implemented WooCommerce plugin installation, does that use a different endpoint? Do we plan to support Jetpack installation in the future, with a similar upsell to JCP sites?

Copy link
Contributor Author

@itsmeichigo itsmeichigo Jan 19, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We implemented Woo installation in a web view only - we want to handle that natively but haven't gotten around to doing that yet. Similarly, we want to support Jetpack installation after the first iteration of the REST API project is shipped, so we'll migrate the rest of the endpoints then.

Base automatically changed from feat/8671-shipping-label-migration to trunk January 20, 2023 02:28
@peril-woocommerce
Copy link

Warnings
⚠️ This PR is assigned to a milestone which is closing in less than 2 days Please, make sure to get it merged by then or assign it to a later expiring milestone

Generated by 🚫 dangerJS

@itsmeichigo itsmeichigo merged commit 3b55efa into trunk Jan 20, 2023
@itsmeichigo itsmeichigo deleted the feat/8677-site-plugin-migration branch January 20, 2023 02:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

feature: REST API Authenticating requests using application password and using REST API instead of Jetpack tunnel. type: task An internally driven task.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

REST API: Migrate the site plugin endpoint

4 participants