code: protected ClientVersionBean getClientVersionInternal(String organizationId, String clientId, String version,
              boolean hasPermission) {
          try {
              storage.beginTx();
              ClientVersionBean clientVersion = storage.getClientVersion(organizationId, clientId, version);
              if (clientVersion == null) {
                  throw ExceptionFactory.clientVersionNotFoundException(clientId, version);
              }
              // Hide some data if the user doesn't have the clientView permission
              if (!hasPermission) {
                  clientVersion.setApikey(null);
              }
              storage.commitTx();
              log.debug(String.format("Got new client version %s: %s", clientVersion.getClient().getName(), clientVersion)); //$NON-NLS-1$
              return clientVersion;
          } catch (AbstractRestException e) {
              storage.rollbackTx();
              throw e;
          } catch (Exception e) {
              storage.rollbackTx();
              throw new SystemErrorException(e);
          }
      }
docs: Does the same thing as getClientVersion() but accepts the 'hasPermission' param,
  which lets callers dictate whether the user has clientView permission for the org.
  @param organizationId
  @param clientId
  @param version
  @param hasPermission