voceconnect/thermal-api

Custom Post Type endpoint returning attachments

astralmedia opened this issue · 2 comments

Hey there! Great work on the plugin, this thing is wonderful.

Had a question:

I am hitting this endpoint:

[ ..mysite.. ] /wp_api/v1/posts/?post_type:product

and the response I am getting seems to be including the post_type of attachment too. It seems that the attachments are children of the actual product posts I am querying, but I can't seem to figure out how to JUST get the product post type posts.

I'm sure I'm just missing something obvious, and thanks in advance for any help in figuring out what that is.

`Scott

It looks like your query string is malformed.

Try /wp_api/v1/posts/?post_type=product.

Ohh man, for some reason I thought the plug-in was expecting something different (I think it was the docs).

Thank you so!