code: function getInitialConfigWithData(method, [arg1, arg2, arg3]) {
    if (typeof arg1 === 'string') {
      const config = { ...arg3 };
      config.url = arg1;
      config.method = method || config.method || 'POST';
      return config;
    } else {
      return arg2 || arg1;
    }
  }
docs: for requests that contain data (POST, PUT)