private static function _validate($method, $params = null, $apiKey = null)
{
if ($params && !is_array($params)) {
throw new Error("You must pass an array as the first argument to EasyPost API method calls.");
}
if ($apiKey && !is_string($apiKey)) {
throw new Error('The second argument to EasyPost API method calls is an optional per-request apiKey, which must be a string.');
}
}