UNPKG

@iflow-mcp/claudeus-wp-mcp

Version:

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

35 lines 1.24 kB
import { BaseApiClient } from './base-client.js'; export class BlocksApiClient extends BaseApiClient { async getBlocks(filters) { return this.getPaginated('/blocks', filters); } async createBlock(data) { return this.post('/blocks', data); } async updateBlock(id, data) { return this.put(`/blocks/${id}`, data); } async deleteBlock(id) { return this.delete(`/blocks/${id}`); } async getBlockRevisions(id) { return this.getPaginated(`/blocks/${id}/revisions`); } async getBlockRevision(blockId, revisionId) { return this.get(`/blocks/${blockId}/revisions/${revisionId}`); } async deleteBlockRevision(blockId, revisionId) { // Revisions require force=true (they don't support trash) return this.delete(`/blocks/${blockId}/revisions/${revisionId}?force=true`); } async getBlockAutosaves(id) { return this.get(`/blocks/${id}/autosaves`); } async getBlockAutosave(blockId, autosaveId) { return this.get(`/blocks/${blockId}/autosaves/${autosaveId}`); } async createBlockAutosave(id, data) { return this.post(`/blocks/${id}/autosaves`, data); } } //# sourceMappingURL=blocks.js.map