Title: INVALID_TYPE error when running papi-client channel get
Last modified: August 18, 2022

---

# INVALID_TYPE error when running papi-client channel get

 *  [psm9640](https://wordpress.org/support/users/psm9640/)
 * (@psm9640)
 * [3 years, 9 months ago](https://wordpress.org/support/topic/invalid_type-error-when-running-papi-client-channel-get/)
 * Hey everybody –
 * I’m trying to follow the steps in the Apple News API Client Utility README.md
   file and hitting a wall.
 * I’ve successfully installed the Ruby CLI and created the .papi configuration 
   file.
 * I’ve placed this file in the home folder on my local machine (when I run a open
   ~/.papi in terminal the file launches without issue). However, when I proceed
   to the next step of running papi-client channel get, I get the following response:
 * > 400 Bad Request: INVALID_TYPE
   >  Message: Key path: Article ID: <CHANNEL ID APPEARS
   > HERE BACK HERE>
 * My .papi file looks like this (with my values swapped for the placeholders):
 * > #<SiteName>
   >  endpoint: [https://news-api.apple.com](https://news-api.apple.com)
   > channel_id: <channel_id> key: <key> secret: <secret>
 * Not seeing a lot of (recent) documentation around this error so I’m just not 
   sure where to proceed from here. Any insight would be extremely helpful.
    -  This topic was modified 3 years, 9 months ago by [psm9640](https://wordpress.org/support/users/psm9640/).
    -  This topic was modified 3 years, 9 months ago by [psm9640](https://wordpress.org/support/users/psm9640/).

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

 *  Plugin Author [Kevin Fodness](https://wordpress.org/support/users/kevinfodness/)
 * (@kevinfodness)
 * [3 years, 9 months ago](https://wordpress.org/support/topic/invalid_type-error-when-running-papi-client-channel-get/#post-15929390)
 * Hi [@psm9640](https://wordpress.org/support/users/psm9640/) –
 * I’m sorry that you’re having trouble getting the Apple News API Client Utility
   to work. However, that software is developed and maintained by Apple, so you’ll
   need to follow up with Apple if it’s not working correctly for you. Once you 
   have verified your channel credentials, if you have any issues configuring the
   Publish to Apple News WordPress plugin, please let me know.
 * Thanks!
 *  Plugin Author [Kevin Fodness](https://wordpress.org/support/users/kevinfodness/)
 * (@kevinfodness)
 * [3 years, 9 months ago](https://wordpress.org/support/topic/invalid_type-error-when-running-papi-client-channel-get/#post-15929407)
 * This document seems to indicate that you might have a typo in your channel ID:
   [https://developer.apple.com/documentation/apple_news/apple_news_api/about_apple_news_api_error_messages?changes=_1_4](https://developer.apple.com/documentation/apple_news/apple_news_api/about_apple_news_api_error_messages?changes=_1_4)
 *  Thread Starter [psm9640](https://wordpress.org/support/users/psm9640/)
 * (@psm9640)
 * [3 years, 9 months ago](https://wordpress.org/support/topic/invalid_type-error-when-running-papi-client-channel-get/#post-15929580)
 * Thank you, Kevin! I appreciate it!
 *  Thread Starter [psm9640](https://wordpress.org/support/users/psm9640/)
 * (@psm9640)
 * [3 years, 9 months ago](https://wordpress.org/support/topic/invalid_type-error-when-running-papi-client-channel-get/#post-15987577)
 * Hi Kevin – Back again. I have not been able to resolve issue but wanted to pick
   your brain…
 * I’m seeing the following message in our in the wp-admin under Apple News > Sections:
 * **Unable to fetch a list of sections.**
 * Aside from the obvious (incorrect .papi info), could inability to retrieve sections
   from our Apple News account be to blame? Thank you again — I know this is not
   the plugin’s issue but I have very little recent experience with Apple News so
   just trying to gather as much info as possible.
 *  Plugin Author [Kevin Fodness](https://wordpress.org/support/users/kevinfodness/)
 * (@kevinfodness)
 * [3 years, 8 months ago](https://wordpress.org/support/topic/invalid_type-error-when-running-papi-client-channel-get/#post-16072903)
 * Retrieving a list of settings depends on a valid API connection, so if you can’t
   get your `.papi` file working correctly via the CLI and uploaded to your WordPress
   site, then it won’t be able to communicate with the Apple News API at all, including
   fetching a list of sections. An error message indicating that a list of sections
   could not be fetched is usually a clear indicator to me that the API credentials
   are incorrect.
 *  Thread Starter [psm9640](https://wordpress.org/support/users/psm9640/)
 * (@psm9640)
 * [3 years, 6 months ago](https://wordpress.org/support/topic/invalid_type-error-when-running-papi-client-channel-get/#post-16242314)
 * Hi Kevin – I ran the CLI and it was successful. New theory we’re working with
   is that our host is somehow blocking the request. To confirm, should we be seeing
   a post request in our server logs when we publish to Apple News (we are not currently—
   just getting the INVALID_TYPE error mentioned earlier).
 * Thank you!

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

The topic ‘INVALID_TYPE error when running papi-client channel get’ 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/)

 * 6 replies
 * 2 participants
 * Last reply from: [psm9640](https://wordpress.org/support/users/psm9640/)
 * Last activity: [3 years, 6 months ago](https://wordpress.org/support/topic/invalid_type-error-when-running-papi-client-channel-get/#post-16242314)
 * Status: not resolved