diff --git a/apispec/core.py b/apispec/core.py
index 029d311..fbb3cc3 100644
--- a/apispec/core.py
+++ b/apispec/core.py
@@ -136,11 +136,21 @@ class APISpec(object):
         """Add a new path object to the spec.
 
         https://github.com/swagger-api/swagger-spec/blob/master/versions/2.0.md#paths-object-
+
+        :param str|Path|None path: URL Path component or Path instance
+        :param dict|None operations: describes the http methods and options for `path`
+        :param dict kwargs: parameters used by any path helpers see :meth:`register_path_helper`
         """
-        if path and 'basePath' in self.options:
+        p = path
+        if isinstance(path, Path):
+            p = path.path
+        if p and 'basePath' in self.options:
             pattern = '^{0}'.format(re.escape(self.options['basePath']))
-            path = re.sub(pattern, '', path)
-        path = Path(path=path, operations=operations)
+            p = re.sub(pattern, '', p)
+        if isinstance(path, Path):
+            path.path = p
+        else:
+            path = Path(path=p, operations=operations)
         # Execute plugins' helpers
         for func in self._path_helpers:
             try:

How should I add an existing Path instance to an APISpec instance
I tried to do something like:

```python
spec = APISpec(**kwargs)
spec.add_path(Path(**kwargs))
```
And I received the following error (as I should have)
```
File "/Users/Josh/Developer/Kaplan/AWS-Lambda-APIGateway-POC/env/lib/python2.7/site-packages/apispec/core.py", line 169, in add_path
    self._paths.setdefault(path.path, path).update(path)
TypeError: unhashable type: 'Path'
```

Is there an easy way to add an existing `Path` object or do I need to duplicate the logic of `self._paths.setdefault(path.path, path).update(path)`?

If this functionality seems worthwhile, I can submit a PR to update `APISpec.add_path` to accept `Path` objects.
diff --git a/tests/test_core.py b/tests/test_core.py
index 7efe15b..07dbf47 100644
--- a/tests/test_core.py
+++ b/tests/test_core.py
@@ -179,6 +179,24 @@ class TestPath:
         assert '/pets' in spec._paths
         assert '/v1/pets' not in spec._paths
 
+    def test_add_path_accepts_path(self, spec):
+        route = '/pet/{petId}'
+        route_spec = self.paths[route]
+        path = Path(path=route, operations={'get': route_spec['get']})
+        spec.add_path(path)
+
+        p = spec._paths[path.path]
+        assert path.path == p.path
+        assert 'get' in p
+
+    def test_add_path_strips_path_base_path(self, spec):
+        spec.options['basePath'] = '/v1'
+        path = Path(path='/v1/pets')
+        spec.add_path(path)
+        assert '/pets' in spec._paths
+        assert '/v1/pets' not in spec._paths
+
+
     def test_add_parameters(self, spec):
         route_spec = self.paths['/pet/{petId}']['get']
 

pip install -e .
parse_log_pytest
requirements.txt
pytest
3.9
dev-requirements.txt
pytest --no-header -rA --tb=line --color=no -p no:cacheprovider -W ignore::DeprecationWarning
-e git+https://github.com/marshmallow-code/apispec.git@684da986e6c77232cc3e8618a51e271e9cd474f8#egg=apispec
backports.tarfile==1.2.0
blinker==1.9.0
cachetools==5.5.2
certifi==2025.1.31
cffi==1.17.1
chardet==5.2.0
charset-normalizer==3.4.1
click==8.1.8
colorama==0.4.6
cryptography==44.0.2
distlib==0.3.9
docutils==0.21.2
exceptiongroup==1.2.2
filelock==3.18.0
flake8==2.4.1
Flask==3.1.0
id==1.5.0
idna==3.10
importlib_metadata==8.6.1
iniconfig==2.1.0
invoke==2.2.0
itsdangerous==2.2.0
jaraco.classes==3.4.0
jaraco.context==6.0.1
jaraco.functools==4.1.0
jeepney==0.9.0
Jinja2==3.1.6
keyring==25.6.0
markdown-it-py==3.0.0
MarkupSafe==3.0.2
marshmallow==3.26.1
mccabe==0.3.1
mdurl==0.1.2
mock==5.2.0
more-itertools==10.6.0
nh3==0.2.21
packaging==24.2
pep8==1.7.1
platformdirs==4.3.7
pluggy==1.5.0
pycparser==2.22
pyflakes==0.8.1
Pygments==2.19.1
pyproject-api==1.9.0
pytest==8.3.5
PyYAML==6.0.2
readme_renderer==44.0
requests==2.32.3
requests-toolbelt==1.0.0
rfc3986==2.0.0
rich==14.0.0
SecretStorage==3.3.3
tomli==2.2.1
tox==4.25.0
twine==6.1.0
typing_extensions==4.13.0
urllib3==2.3.0
virtualenv==20.29.3
webargs==8.6.0
Werkzeug==3.1.3
zipp==3.21.0

name: apispec
channels:
  - defaults
  - https://repo.anaconda.com/pkgs/main
  - https://repo.anaconda.com/pkgs/r
  - conda-forge
dependencies:
  - _libgcc_mutex=0.1=main
  - _openmp_mutex=5.1=1_gnu
  - ca-certificates=2025.2.25=h06a4308_0
  - ld_impl_linux-64=2.40=h12ee557_0
  - libffi=3.4.4=h6a678d5_1
  - libgcc-ng=11.2.0=h1234567_1
  - libgomp=11.2.0=h1234567_1
  - libstdcxx-ng=11.2.0=h1234567_1
  - ncurses=6.4=h6a678d5_0
  - openssl=3.0.16=h5eee18b_0
  - pip=25.0=py39h06a4308_0
  - python=3.9.21=he870216_1
  - readline=8.2=h5eee18b_0
  - setuptools=75.8.0=py39h06a4308_0
  - sqlite=3.45.3=h5eee18b_0
  - tk=8.6.14=h39e8969_0
  - tzdata=2025a=h04d1e81_0
  - wheel=0.45.1=py39h06a4308_0
  - xz=5.6.4=h5eee18b_1
  - zlib=1.2.13=h5eee18b_1
  - pip:
      - backports-tarfile==1.2.0
      - blinker==1.9.0
      - cachetools==5.5.2
      - certifi==2025.1.31
      - cffi==1.17.1
      - chardet==5.2.0
      - charset-normalizer==3.4.1
      - click==8.1.8
      - colorama==0.4.6
      - cryptography==44.0.2
      - distlib==0.3.9
      - docutils==0.21.2
      - exceptiongroup==1.2.2
      - filelock==3.18.0
      - flake8==2.4.1
      - flask==3.1.0
      - id==1.5.0
      - idna==3.10
      - importlib-metadata==8.6.1
      - iniconfig==2.1.0
      - invoke==2.2.0
      - itsdangerous==2.2.0
      - jaraco-classes==3.4.0
      - jaraco-context==6.0.1
      - jaraco-functools==4.1.0
      - jeepney==0.9.0
      - jinja2==3.1.6
      - keyring==25.6.0
      - markdown-it-py==3.0.0
      - markupsafe==3.0.2
      - marshmallow==3.26.1
      - mccabe==0.3.1
      - mdurl==0.1.2
      - mock==5.2.0
      - more-itertools==10.6.0
      - nh3==0.2.21
      - packaging==24.2
      - pep8==1.7.1
      - platformdirs==4.3.7
      - pluggy==1.5.0
      - pycparser==2.22
      - pyflakes==0.8.1
      - pygments==2.19.1
      - pyproject-api==1.9.0
      - pytest==8.3.5
      - pyyaml==6.0.2
      - readme-renderer==44.0
      - requests==2.32.3
      - requests-toolbelt==1.0.0
      - rfc3986==2.0.0
      - rich==14.0.0
      - secretstorage==3.3.3
      - tomli==2.2.1
      - tox==4.25.0
      - twine==6.1.0
      - typing-extensions==4.13.0
      - urllib3==2.3.0
      - virtualenv==20.29.3
      - webargs==8.6.0
      - werkzeug==3.1.3
      - zipp==3.21.0
prefix: /opt/conda/envs/apispec

tests/test_core.py::TestPath::test_add_path_accepts_path tests/test_core.py::TestPath::test_add_path_strips_path_base_path
tests/test_core.py::TestMetadata::test_swagger_version tests/test_core.py::TestMetadata::test_swagger_metadata tests/test_core.py::TestDefinitions::test_definition tests/test_core.py::TestDefinitions::test_definition_stores_enum tests/test_core.py::TestPath::test_add_path tests/test_core.py::TestPath::test_add_path_merges_paths tests/test_core.py::TestPath::test_add_path_ensures_path_parameters_required tests/test_core.py::TestPath::test_add_path_with_no_path_raises_error tests/test_core.py::TestPath::test_add_path_strips_base_path tests/test_core.py::TestPath::test_add_parameters tests/test_core.py::TestExtensions::test_setup_plugin tests/test_core.py::TestExtensions::test_setup_plugin_doesnt_exist tests/test_core.py::TestExtensions::test_register_definition_helper tests/test_core.py::TestExtensions::test_register_path_helper tests/test_core.py::TestExtensions::test_multiple_path_helpers_w_different_signatures tests/test_core.py::TestExtensions::test_multiple_definition_helpers_w_different_signatures tests/test_core.py::TestDefinitionHelpers::test_definition_helpers_are_used tests/test_core.py::TestDefinitionHelpers::test_multiple_definition_helpers tests/test_core.py::TestPathHelpers::test_path_helper_is_used tests/test_core.py::TestResponseHelpers::test_response_helper_is_used
apispec/core.py
apispec/core.py