Title: Sending data from Python to WordPress
Last modified: September 15, 2020

---

# Sending data from Python to WordPress

 *  [pythondude](https://wordpress.org/support/users/pythondude/)
 * (@pythondude)
 * [5 years, 9 months ago](https://wordpress.org/support/topic/sending-data-from-python-to-wordpress/)
 * Hello,
 * I developed an engine (in Python) that aggregates various news articles and run
   NLP analysis on the text. The results of the analysis must now be displayed on
   a web-interface.
 * I have been working on a scallable solution to transfer over data generated by
   my Python-based engine to WordPress, but I don’t know the best route to take 
   yet.
 * Here is what I tried so far:
 * 1- I have the most success using the Python XMLRPC library that sends the data
   over the XMLRPC line. Quite a signficant amount of information for each post 
   is stored in Custom Fields and new Tags are created dynamically in the backend,
   the API abilities to create and maintain the relational-entity in the database
   is needed.
 * 2- Using the WP REST API has proven difficult, the documentation is poor, and
   unlike the solution above, creation of a custom tag requires the Post to be sent,
   the ID to be retrieved, and the tag name to be added to the POST payload along
   with that ID into the tags table.
 * Any other solutions I should consider here? Would appreciate any input.
    Thanks

Viewing 1 replies (of 1 total)

 *  Moderator [bcworkz](https://wordpress.org/support/users/bcworkz/)
 * (@bcworkz)
 * [5 years, 8 months ago](https://wordpress.org/support/topic/sending-data-from-python-to-wordpress/#post-13419448)
 * Going forward, the REST API is strongly favored over XML-RPC. While I agree it
   is more difficult and the documentation is poor, it really is the way to go. 
   You could build you own custom API route/endpoints which would allow you to accomplish
   your needs in a single request since your API callback would be doing all the
   heavy lifting. It still needs to determine the post ID before adding tags, but
   it’s all done internally with PHP, there’s no additional API requests needed.

Viewing 1 replies (of 1 total)

The topic ‘Sending data from Python to WordPress’ is closed to new replies.

 * In: [Developing with WordPress](https://wordpress.org/support/forum/wp-advanced/)
 * 1 reply
 * 2 participants
 * Last reply from: [bcworkz](https://wordpress.org/support/users/bcworkz/)
 * Last activity: [5 years, 8 months ago](https://wordpress.org/support/topic/sending-data-from-python-to-wordpress/#post-13419448)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
