Apr 17, 2019 1:03 AM
I want to the fetch blog posts based on multiple tags using blog-posts api.please guide.
I currently use this ('https://api.hubapi.com/content/api/v2/blog-posts?hapikey=demo&limit=50&topic_id=5557205548')
Secound one can i get tag slug and tag name both in tag field in custom module.Please confirm on this asps.
Apr 19, 2019 11:05 AM
Hi @jai welcome! It doesn't appear there's a way to filter by blog tags with our endpoints. When I make a get request with topic_id, it doesn't appear to have any bearing on the actual response returned. From the docs we have:
order_by Return the posts ordered by a particular field value.
Blog posts can currently only be sorted by publish_date.
Use a negative value to sort in descending order (e.g. order_by=-publish_date).
The other parameters documented will work, but it doesn't appear blog tags do.
See this post for a similar question here! https://integrate.hubspot.com/t/posts-api-is-it-possible-to-filter-by-tags-or-keyword/9341