Title: error with the API: INVALID_DOCUMENT &#8211; &#8220;text&#8221; was null&#8230;
Last modified: August 13, 2017

---

# error with the API: INVALID_DOCUMENT – “text” was null…

 *  Resolved [PPNSteve](https://wordpress.org/support/users/ppnsteve/)
 * (@ppnsteve)
 * [8 years, 9 months ago](https://wordpress.org/support/topic/error-with-the-api-invalid_document-text-was-null/)
 * when updatinga previously published post I’m getting this error:
    `There has 
   been an error with the API: INVALID_DOCUMENT - "text" was null should be not (
   null or an empty string) (keyPath components->2->components->8->text)`
 * the edit was just adding a you tube video to the post and save.. got that error.
 * The page I need help with: _[[log in](https://login.wordpress.org/?redirect_to=https%3A%2F%2Fwordpress.org%2Fsupport%2Ftopic%2Ferror-with-the-api-invalid_document-text-was-null%2F%3Foutput_format%3Dmd&locale=en_US)
   to see the link]_

Viewing 2 replies - 1 through 2 (of 2 total)

 *  Plugin Author [Kevin Fodness](https://wordpress.org/support/users/kevinfodness/)
 * (@kevinfodness)
 * [8 years, 8 months ago](https://wordpress.org/support/topic/error-with-the-api-invalid_document-text-was-null/#post-9469616)
 * Hi [@ppnsteve](https://wordpress.org/support/users/ppnsteve/)—
 * We have an open issue related to this: [https://github.com/alleyinteractive/apple-news/issues/365](https://github.com/alleyinteractive/apple-news/issues/365)
 * Did you hit enter twice in the editor before pasting the YouTube video link? 
   If so, it would cause a blank line to be added, which Apple News Format doesn’t
   support. We’re working on identifying these cases and filtering them out, but
   in the meantime, if you have blank lines in your content, you should remove them
   in order for publishing to work properly.
 *  Plugin Author [Kevin Fodness](https://wordpress.org/support/users/kevinfodness/)
 * (@kevinfodness)
 * [8 years, 7 months ago](https://wordpress.org/support/topic/error-with-the-api-invalid_document-text-was-null/#post-9573912)
 * Closing due to inactivity.

Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘error with the API: INVALID_DOCUMENT – “text” was null…’ is closed to
new replies.

 * ![](https://ps.w.org/publish-to-apple-news/assets/icon-256x256.png?rev=3017580)
 * [Publish To Apple News](https://wordpress.org/plugins/publish-to-apple-news/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/publish-to-apple-news/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/publish-to-apple-news/)
 * [Active Topics](https://wordpress.org/support/plugin/publish-to-apple-news/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/publish-to-apple-news/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/publish-to-apple-news/reviews/)

## Tags

 * [api](https://wordpress.org/support/topic-tag/api/)

 * 2 replies
 * 2 participants
 * Last reply from: [Kevin Fodness](https://wordpress.org/support/users/kevinfodness/)
 * Last activity: [8 years, 7 months ago](https://wordpress.org/support/topic/error-with-the-api-invalid_document-text-was-null/#post-9573912)
 * Status: resolved