async function getConnectionClient(req, res) {
  const { models, params, user } = req;

  const connectionClient = models.connectionClients.getOneById(
    params.connectionClientId
  );

  if (!connectionClient) {
    return res.utils.notFound();
  }

  // Only the owner of the connection or admin can get the client
  const allowed = connectionClient.user.id === user.id || user.role === 'admin';

  if (!allowed) {
    return res.utils.forbidden();
  }

  return res.utils.data({
    id: connectionClient.id,
    name: connectionClient.connection.name,
    connectedAt: connectionClient.connectedAt,
    lastKeepAliveAt: connectionClient.lastKeepAliveAt,
  });
}
Get a connection client by id
If connection client does is not found it means it was probably disconnected, or never existed
(May want to build out a historical reference of connection clients to be able to tell the difference)
@param {Req} req
@param {Res} res