code: protected function convertIncludePath($path)
      {
          if (array_key_exists($path, $this->includePaths)) {
              return $this->includePaths[$path] ?: null;
          }
  
          return collect(explode('.', $path))->map(function ($segment) {
              return $this->modelRelationForField($segment);
          })->implode('.');
      }
docs: Convert a JSON API include path to a model relationship path.
  
  @param $path
  @return string|null