gRPC request error

I´m trying to get a list of all registered gateways from the chirpstack server with gRPC and python.


import grpc
from chirpstack_api import api

server = "server-url:8080"
api_token = "api-token"
channel = grpc.secure_channel(server, grpc.ssl_channel_credentials())
auth_token = [("authorization", "Bearer %s" % api_token)]

def getGatewayList():

    client = api.GatewayServiceStub(channel)

    req = api.ListGatewaysRequest()

    req.limit = 1000  # mandatory if you want details

    resp = client.List(req, metadata=auth_token)

    return resp


Unfortunately I´m getting following error:

grpc._channel._InactiveRpcError: <_InactiveRpcError of RPC that terminated with:
        status = StatusCode.INTERNAL
        details = "Exception deserializing response!"
        debug_error_string = "None"

I’ve tried the same code with a local chirpstack server and an unsecure channel, which perfectly worked.

Does anyone know, what is causing this issue?

Are you sure this is correct (use this in case the API is served over TLS)? Please see the example here: