{"id":11138,"date":"2026-05-27T00:29:50","date_gmt":"2026-05-26T16:29:50","guid":{"rendered":"https:\/\/aeosub.com\/sticklight\/"},"modified":"2026-05-27T00:29:50","modified_gmt":"2026-05-26T16:29:50","slug":"sticklight","status":"publish","type":"post","link":"https:\/\/aeosub.com\/zh\/sticklight\/","title":{"rendered":"Sticklight"},"content":{"rendered":"<div class=\"plugin-info-card\" style=\"border: 1px solid #e2e8f0;border-radius: 10px;overflow: hidden;margin-bottom: 30px;font-family: -apple-system, system-ui, sans-serif;background: #fff\">\n<table style=\"width: 100%;border-collapse: collapse;font-size: 14px\">\n<tr style=\"border-bottom: 1px solid #edf2f7\">\n<th style=\"padding: 15px 20px;text-align: left;width: 35%;color: #4a5568;background: #fcfcfc\"><img decoding=\"async\" src=\"https:\/\/ps.w.org\/sticklight\/assets\/icon.svg?rev=3549373\" style=\"width: 40px;height: 40px;border-radius: 6px;margin-right: 12px;vertical-align: middle\"> Developer<\/th>\n<td style=\"padding: 15px 20px;font-weight: 500\"><a href=\"https:\/\/profiles.wordpress.org\/elemntor\/\" target=\"_blank\" rel=\"noopener\">Elementor<\/a><\/td>\n<\/tr>\n<tr style=\"border-bottom: 1px solid #edf2f7\">\n<th style=\"padding: 12px 20px;text-align: left;color: #4a5568;background: #fcfcfc\">Version<\/th>\n<td style=\"padding: 12px 20px\">v1.0.0<\/td>\n<\/tr>\n<tr style=\"border-bottom: 1px solid #edf2f7\">\n<th style=\"padding: 12px 20px;text-align: left;color: #4a5568;background: #fcfcfc\">Active Installs<\/th>\n<td style=\"padding: 12px 20px\">0 +<\/td>\n<\/tr>\n<tr style=\"border-bottom: 1px solid #edf2f7\">\n<th style=\"padding: 12px 20px;text-align: left;color: #4a5568;background: #fcfcfc\">Requires \/ Tested<\/th>\n<td style=\"padding: 12px 20px\">6.8 \/ 7.0<\/td>\n<\/tr>\n<tr style=\"border-bottom: 1px solid #edf2f7\">\n<th style=\"padding: 12px 20px;text-align: left;color: #4a5568;background: #fcfcfc\">Last Updated<\/th>\n<td style=\"padding: 12px 20px\">2026-05-26 3:30pm GMT<\/td>\n<\/tr>\n<tr>\n<th style=\"padding: 12px 20px;text-align: left;color: #4a5568;background: #fcfcfc\">Official Link<\/th>\n<td style=\"padding: 12px 20px\"><a href=\"https:\/\/wordpress.org\/plugins\/sticklight\/\" target=\"_blank\" style=\"text-decoration: none;color: #4a3bca;font-weight: bold\" rel=\"noopener\">View Details \u2192<\/a><\/td>\n<\/tr>\n<\/table><\/div>\n<div class=\"plugin-short-desc\" style=\"margin: 20px 0;padding: 12px 15px;background: #f9fafb;border-left: 4px solid #4a3bca;border-radius: 6px;font-style: italic;color: #4a5568\">Use WordPress authentication and permissions in external React applications via secure REST API endpoints.<\/div>\n<p>Sticklight Connector provides a structured way to use the WordPress user system in external or React-based applications.<\/p>\n<p>The plugin extends the WordPress REST API with additional endpoints that allow authenticated clients to retrieve user context and interact with WordPress data, while fully respecting core authentication methods, roles, and capability checks.<\/p>\n<p>Sticklight does not replace WordPress authentication. It relies on <code>wp_authenticate<\/code> for credential validation and WordPress Application Passwords for API access, and follows standard permission checks (<code>current_user_can<\/code>) for all requests.<\/p>\n<h4>Typical use cases<\/h4>\n<ul>\n<li>React applications connected to a WordPress site<\/li>\n<li>Headless or hybrid WordPress setups<\/li>\n<li>Admin or user dashboards built outside wp-admin<\/li>\n<li>External tools that require authenticated access to WordPress data<\/li>\n<\/ul>\n<h4>Features<\/h4>\n<ul>\n<li>Authenticates via <code>wp_authenticate<\/code> and issues Application Passwords for API access<\/li>\n<li>Adds REST endpoints for login, logout, and retrieving current user context<\/li>\n<li>Enforces WordPress capability checks on all requests<\/li>\n<li>Supports cross-origin headless setups<\/li>\n<li>Extensible via WordPress hooks and filters<\/li>\n<\/ul>\n<h3>Usage<\/h3>\n<h4>Login<\/h4>\n<p>Authenticate with username (or email) and password:<\/p>\n<pre><code>POST \/wp-json\/sticklight\/v1\/auth\/login\n<\/code><\/pre>\n<p>On success the response includes an Application Password for subsequent API requests and the authenticated user:<\/p>\n<pre><code>{\n  \"app_password\": \"XXXX XXXX XXXX XXXX XXXX XXXX\",\n  \"user\": {\n    \"user_id\": 1,\n    \"username\": \"admin\",\n    \"display_name\": \"Admin\",\n    \"email\": \"admin@example.com\",\n    \"roles\": [\"administrator\"]\n  }\n}\n<\/code><\/pre>\n<p>Use the returned <code>app_password<\/code> with HTTP Basic Authentication for all further requests.<\/p>\n<h4>Current user<\/h4>\n<p>Retrieve the current authenticated user:<\/p>\n<pre><code>GET \/wp-json\/sticklight\/v1\/auth\/me\n<\/code><\/pre>\n<h4>Logout<\/h4>\n<p>Revoke the current Application Password session:<\/p>\n<pre><code>POST \/wp-json\/sticklight\/v1\/auth\/logout\n<\/code><\/pre>\n<h4>User registration<\/h4>\n<p>User creation is handled through the built-in WordPress REST API (<code>POST \/wp-json\/wp\/v2\/users<\/code>) and requires administrator authentication.<\/p>\n<h4>Accessing protected data<\/h4>\n<p>Requests to any endpoint must pass standard WordPress permission checks. Sticklight does not bypass or override these checks.<\/p>\n<h3>Security<\/h3>\n<p>Sticklight follows WordPress security practices:<\/p>\n<ul>\n<li>Authenticates via <code>wp_authenticate<\/code>, which respects all security plugin hooks (rate limiting, two-factor authentication, brute-force protection)<\/li>\n<li>Issues Application Passwords scoped to individual sessions<\/li>\n<li>Does not provide user registration \u2014 accounts must be created by an administrator<\/li>\n<li>Applies capability checks (<code>current_user_can<\/code>) on all endpoints<\/li>\n<li>Does not expose private data without proper permissions<\/li>\n<\/ul>\n<p>For external applications, it is recommended to:<\/p>\n<ul>\n<li>Use HTTPS<\/li>\n<li>Restrict allowed origins<\/li>\n<li>Avoid exposing sensitive endpoints unnecessarily<\/li>\n<\/ul>\n","protected":false},"excerpt":{"rendered":"<p>Use WordPress authentication and permissions in external React applications via secure REST API endpoints.<\/p>","protected":false},"author":1,"featured_media":9317,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"inline_featured_image":false,"footnotes":""},"categories":[252],"tags":[716,2181,1291,2182,1085,555],"class_list":["post-11138","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-trends","tag-api","tag-authentication","tag-headless","tag-react","tag-rest-api","tag-wordpress-plugin"],"_links":{"self":[{"href":"https:\/\/aeosub.com\/zh\/wp-json\/wp\/v2\/posts\/11138","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/aeosub.com\/zh\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/aeosub.com\/zh\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/aeosub.com\/zh\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/aeosub.com\/zh\/wp-json\/wp\/v2\/comments?post=11138"}],"version-history":[{"count":0,"href":"https:\/\/aeosub.com\/zh\/wp-json\/wp\/v2\/posts\/11138\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/aeosub.com\/zh\/wp-json\/wp\/v2\/media\/9317"}],"wp:attachment":[{"href":"https:\/\/aeosub.com\/zh\/wp-json\/wp\/v2\/media?parent=11138"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/aeosub.com\/zh\/wp-json\/wp\/v2\/categories?post=11138"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/aeosub.com\/zh\/wp-json\/wp\/v2\/tags?post=11138"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}