docs: function CamundaClient(config) {
    if (!config) {
      throw new Error('Needs configuration');
    }
  
    if (!config.apiUri) {
      throw new Error('An apiUri is required');
    }
  
    Events.attach(this);
  
    // use 'default' engine
    config.engine = typeof config.engine !== 'undefined'
      ? config.engine
      : 'default';
  
    // mock by default.. for now
    config.mock =  typeof config.mock !== 'undefined' ? config.mock : true;
  
    config.resources = config.resources || {};
  
    this.HttpClient = config.HttpClient || CamundaClient.HttpClient;
  
    this.baseUrl = config.apiUri;
    if (config.engine) {
      this.baseUrl += (this.baseUrl.slice(-1) !== '/' ? '/' : '');
      this.baseUrl += 'engine/'+ config.engine;
    }
  
    this.config = config;
  
    this.initialize();
  }