public CustomMetricsPoster(string apiKey, string instanceId = null, IFailureCallback failureCallback = null) { if (String.IsNullOrWhiteSpace(apiKey)) { throw new ArgumentNullException("apiKey"); } _apiKey = apiKey; _failureCallback = failureCallback ?? new ConsoleFailureCallback(); InstanceId = instanceId; }