Make WordPress Core

Opened 11 years ago

Closed 11 years ago

#25090 closed feature request (duplicate)

XML-RPC API for Customization and Extensibility Needed

Reported by: kailasa's profile kailasa Owned by:
Milestone: Priority: normal
Severity: normal Version:
Component: XML-RPC Keywords:
Focuses: Cc:


I recently hit a wall with wp.getPosts because of what is, IMHO, a bad decision to put the following code into the xmlrpc server.


// Consider future posts as published

	if ( $post_fields['post_status'] === 'future' )
		$post_fields['post_status'] = 'publish';

We have other unique requirements for behaviors of the XML-RPC server, which I won't detail here for now... suffice it to say that the issue is really that this part of the framework does not follow the model of customization/extensibility.

That code that conflates "future" with "publish" should really be a developer option that we can add to our theme/functions, etc. such that it customizes the xmlrpc behaviors, is preserved on upgrade and does not require core to manage X number of unique xmlrpc requirements. Miss Sally's blog may want one thing. Macho Mainstream Online Magazine may have some serious heavy lifting to do with XML-RPC. MyShoppingCenter in Wordpress could have very unique needs. gives remote access to WP on your desktop via XML-RPC (we do this now) You don't want to be adding all these to the core.

The way themes work and should also work for xmlrpc. If someone wants "future" to equal "publish" he can make is so without touching the core. Or perhaps some plug-in that would allow us to add-subtract etc to the core XML-RPC. Many values have multi-parameter options which are now hard-wired into that one file.

Change History (1)

#1 @markoheijnen
11 years ago

  • Milestone Awaiting Review deleted
  • Resolution set to duplicate
  • Status changed from new to closed

Closing this ticket as duplicate of #25089 and being to general. The XML-RPC can be changed to whatever you want. You can use the filter xmlrpc_methods to add your own methods. You can even replace the whole class by using the filter wp_xmlrpc_server_class.

You are free to reopen it when you have use cases for specific things you want to change.

Note: See TracTickets for help on using tickets.