Title: Reliable Create/Note delivery when scripting
Last modified: October 12, 2024

---

# Reliable Create/Note delivery when scripting

 *  [johannes.ernst](https://wordpress.org/support/users/johannesernst/)
 * (@johannesernst)
 * [1 year, 7 months ago](https://wordpress.org/support/topic/reliable-create-note-delivery-when-scripting/)
 * For FediTest, one of the tests is:
    1. Mastodon account follows WordPress account
    2. WordPress account posts something
    3. test that Mastodon account receives it
 * We use the Mastodon API both for Mastodon and WordPress. The WordPress side has
   this plugin, the ActivityPub plugin and the friends plugin.
 * It appears that on the WordPress side, the ActivityPub HTTP POST of the Create/
   Note activity triggered by step 2 runs with `wp-cron` (which I don’t really understand,
   except that I think it has some kind of queue that is worked down as a side effect
   of incoming HTTP requests).
 * If I suspend the automated test run after step 2, and use a browser to access
   the WordPress instance, it appears the HTTP POST to the Mastodon inbox is performed.
   If it runs in unattended mode, the POST is not performed.
 * I tried to `curl https://wordpress/wp-cron.php` and `curl https://wordpress/wp-
   cron.php?doing_wp_cron` but that doesn’t seem to trigger it. Is there some kind
   of time delay (In one experiment, it worked after about 15 seconds) Or how do
   I get WordPress to reliably deliver that POST as part of my script?

The topic ‘Reliable Create/Note delivery when scripting’ is closed to new replies.

 * ![](https://ps.w.org/enable-mastodon-apps/assets/icon-256x256.png?rev=3244261)
 * [Enable Mastodon Apps](https://wordpress.org/plugins/enable-mastodon-apps/)
 * [Support Threads](https://wordpress.org/support/plugin/enable-mastodon-apps/)
 * [Active Topics](https://wordpress.org/support/plugin/enable-mastodon-apps/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/enable-mastodon-apps/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/enable-mastodon-apps/reviews/)

 * 0 replies
 * 1 participant
 * Last reply from: [johannes.ernst](https://wordpress.org/support/users/johannesernst/)
 * Last activity: [1 year, 7 months ago](https://wordpress.org/support/topic/reliable-create-note-delivery-when-scripting/)
 * Status: not resolved