Have you tried codex.wordpress.org/XML-RPC_Support.
This code works, in conjunction with the IXR library found at incutio:
include('IXR_Library.php');
$usr="theusername";
$pwd = 'thepassword';
$xmlrpc="http://not-therealurl.com/xmlrpc.php";
$client = new IXR_Client($xmlrpc);
$client -> debug = true; //optional but useful
$params = array(
'post_type' => 'post',
'post_status' => 'draft',
'post_title' => 'Test Post',
'post_author' => 4,
'post_excerpt' => 'This is my test excerpt',
'post_content' => 'This is my test post. Now its longer than the excerpt.'
);
$res = $client -> query('wp.newPost',1, $usr, $pwd, $params);
Related Posts:
- WordPress Rest API custom endpoint optional param
- How to stop WP API endpoint from caching?
- “rest_no_route” – Debug error
- Can’t get POST data in API endpoint callback
- POST request not going through?
- Does it still make sense using json endpoint ep_mask now that there’s the new rest api? [closed]
- How to fix AWS SNS API end point code that cause site not to load?
- How to add an endpoint for my custom post type? /wp-json/wp/v2/posts is working but it didn’t in the custom post
- This page didn’t load Google Maps correctly. See the JavaScript console for technical details
- This page didn’t load Google Maps correctly. See the JavaScript console for technical details
- What is an Endpoint?
- Constructing requests with URL Query String in Python
- Yahoo! Finance CSV file will not return Dow Jones (^DJI)
- Is there a developers api for craigslist.org
- How do you get the API key for Locu?
- Postman Resolving “Invalid CORS request” for a POST Request
- How do you create a “virtual” page in WordPress
- Using the Rewrite API to Construct a RESTful URL
- WP function/filter for modifying http headers?
- Access WordPress API Outside of WordPress (command-line PHP)
- Create API for single sign-on with 3rd party site
- Custom Taxonomy Endpoint Pagination using paginate_links()
- Set up WP Authentication from External API
- Dynamic Endpoints
- How do I cache (core) API requests?
- WP REST API only returning partial list of users
- What is the best way to get directory path for wp-config.php?
- Slow REST API calls on self-hosted WordPress [closed]
- WordPress JSON output
- Retrieving pages with multiple tags using REST API
- how to authenticate for the REST API from a plugin and from command line
- Make Two Views of Post Type Archive At Two URLs
- External WordPress API
- How to Rewrite WordPress URL for a Plugin
- WordPress API – Get Drafts
- How do I use the WP REST API plugin and the OAuth Server plugin to allow for registration and login?
- Should I store external API data in my WP database or keep it as a transient?
- Sending POST Request from server
- How to implement ERP (Enterprise Resource Planning) into WordPress?
- List Table API – Safe to use?
- Add rewrite endpoint to author page + pagination
- API integration with WordPress
- POST to a REST API from a wordpress form
- How to get the attached gallery in the rest API?
- WP API : date_query parameter
- Gutenberg internal page link search box
- get WP-API by page id
- WordPress.org Support Forum API
- Custom Endpoint Gives 404 Header
- Authentication/API Questions
- Custom route for WP-API gives “rest_no_route” value
- Connect external web app to wordpress
- How to get all posts (in chunks) via XML-RPC?
- How to add a custom parameter to a WP API default route?
- Dynamic URL, not a physical page within the database
- Get more than 10 posts in a specific category with the wordpress api
- Passing variables to new page
- utf8 encoding in json rest api
- Developing Themes with React/Angular
- Authentication for a mobile app connected via wp-rest api?
- curl POST work with user meta but not the custom user meta
- Implementing the wp json-rest api
- How make a multi language routes, with rewrite rules or rewrite endpoints?
- Add rewrite rule for rewrite endpoint
- WordPress API – count posts
- How to Securely and remotely Create new user in wordpress using Rest API
- API in numbers?
- how to get nonce using json api
- Does WordPress support a shortcode calling itself from within a shortcode call?
- What is the official way to consume the WordPress API? (api.wordpress.org)
- Stuck with wp_remote_post sending data to an external api on user registration
- How to have multiple rewrite endpoints in the same URL?
- API for Post Stats for Self-Hosted WordPress using JetPack [closed]
- How to get title tag of an external page with http api?
- Create post with REST API in php with file_get_contents
- How to Hit External REST POST API in WordPress? [closed]
- How to get WordPress Plugins Data in PHP using Plugin API?
- Displaying Content with WP Rest API
- How to integrate Yelp API
- API getting null values with wp_remote_post
- Where to find WordPress API changes for each version released
- I am trying to use the Theme Customization API but I keep getting an error
- Custom Post for Locating by Google Maps API
- How to Increase WordPress JSON API Speed?
- Extending WordPress REST API
- add_rewrite_endpoint() and Custom Post Type Archive
- WordPress JSON API Extend to Create Users [closed]
- External API to WP
- Headless WordPress – Issue with plugin path
- node-wpapi: how to handle authentication?
- Post body not working with wp_remote_post()
- How can I cache WordPress Rest API Response
- WordPress REST API always misses parameters – rest_missing_callback_param
- Possible to use wordpress as publishing platform but programmatically inject content?
- Unable to find API Key for my blog
- Create multiple rewrite endpoints for custom taxonomy archive
- Associate the “add_rewrite_endpoint” and “$_GET”
- Adding rest api endpoints to an old theme
- How to avoid loading wp-load.php from external php scripts?
- Develop REST API using WordPress for Android app [closed]