wp-cli sync specific image
Is it possible to manually sync an image from CLI or code? After my pictures are uploaded I have scripts running and modifying some of the pictures, this might take several minutes, which means I would like to start the sync of the picture once this process is finished.
0
-
Hi,
This is not possible to sync a specific image using the WP-CLI. However, if you are using our auto-sync feature, you can actually request the WP Rest API media endpoint via cURL. For example, if your post_id is 12345, you can cURL the following URL: https://your_domain.com/wp-json/wp/v2/media/12345, this should trigger a sync and you can check the value of the is_cloudinary_synced from the JSON returned from the URL.
Hope that helps.
Best,
Loic
0
Post is closed for comments.
Comments
1 comment