intercom / intercom-java

Java bindings for the Intercom API
https://developers.intercom.io/reference
Apache License 2.0
64 stars 68 forks source link

List for tags and contacts returns empty response (no data) #303

Open karthikrao5 opened 2 years ago

karthikrao5 commented 2 years ago

Please use the following template to submit your issue. Following this template will allow us to quickly investigate and help you with your issue. Please be aware that issues which do not conform to this template may be closed.

For feature requests please contact us at team@intercom.io

Version info

Expected behavior

I expect a list of data for tags or contacts to be returned in the iterator

Actual behavior

iterator is empty and hasNext() is always false

Steps to reproduce

  1. call Intercom.setToken("api-key") (confirmed this was correct by hitting the rest endpoint directly from postman
  2. call Tag.list()
  3. While loop iterator prints nothing
        val tags = Tag.list()
        while(tags.hasNext()) {
            println(tags.next())
        }

Debugger shows pages and page being empty.

The tag.create function works correctly and adds the tag that i can see in my workspace

val tag = Tag.create(Tag().setName("new tag from api again"))

Logs