Python SDK get_users method not returning the output in a valid json format

Hello Team,

I am running a python program to fetch the list of users in the genesys cloud for my organization and i am using the PureCloudPlatformClientV2 library and I have attached the python script which i am executing, somehow the response of the below method call doesn't return a valid json. I have attached the output of this method call to this ticket.

api_instance.get_users(id=id)

Somehow for other method calls i get a valid json response (list or dict) for example get_systempresences()

Could you please guide me on why we are not seeing a valid json response and please suggest ways to convert this method output to valid json.

Appreciate your response on this.
get-users-python.yml (990 Bytes)
get-users-output.json (2.4 KB)

Hi Hari,

Our python SDK is returning a Python class and not JSON. All of our Python classes are generated using our Swagger API. If you want to convert one of our classes to JSON, I suggest you look at:

This method takes an object and converts it to JSON.

Thanks,
John Carnell

thanks @John_Carnell . your inputs helped me to resolve this problem.

This topic was automatically closed 31 days after the last reply. New replies are no longer allowed.