UNPKG

@iflow-mcp/claudeus-wp-mcp

Version:

The most comprehensive WordPress MCP server - 145 production-ready tools for complete WordPress management with AI

61 lines 2.07 kB
/** * WordPress Global Styles API Client * Handles FSE (Full Site Editing) global styles and variations */ import { BaseApiClient } from './base-client.js'; export class GlobalStylesApiClient extends BaseApiClient { // ========================================== // GLOBAL STYLES // ========================================== /** * Get global styles by ID * @param id Global styles ID (usually the theme slug or "custom") */ async getGlobalStyles(id = 'custom') { return this.get(`/global-styles/${id}`); } /** * Update global styles * @param id Global styles ID * @param data Updated styles and/or settings */ async updateGlobalStyles(id, data) { return this.put(`/global-styles/${id}`, data); } // ========================================== // THEME GLOBAL STYLES // ========================================== /** * Get global styles for a specific theme * @param stylesheet Theme stylesheet name (e.g., "twentytwentyfour") */ async getThemeGlobalStyles(stylesheet) { return this.get(`/global-styles/themes/${stylesheet}`); } /** * Get style variations for a theme * @param stylesheet Theme stylesheet name */ async getStyleVariations(stylesheet) { return this.get(`/global-styles/themes/${stylesheet}/variations`); } // ========================================== // REVISIONS // ========================================== /** * Get revisions for global styles * @param parentId Parent global styles ID */ async getGlobalStylesRevisions(parentId) { return this.getPaginated(`/global-styles/${parentId}/revisions`); } /** * Get a specific global styles revision * @param parentId Parent global styles ID * @param revisionId Revision ID */ async getGlobalStylesRevision(parentId, revisionId) { return this.get(`/global-styles/${parentId}/revisions/${revisionId}`); } } //# sourceMappingURL=global-styles.js.map