question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Permit multiple externalDocs

See original GitHub issue

Documenting APIs often depend on multiple external factors - functional and non-functional aspects, change notes, governance, strategy, many more - and a single externalDocs reference is often insufficient, especially in complex scenarios where multiple parties are responsible for design/deployment/delivery of these aspects (not everyone is DevOps)

Would we want to move the single object to an array/collection of objects:

externalDocs:
- description: link 1
  url: http://link/1
- description: link
  url: http://link/2

or

externalDocs:
  link1:
    description: link 1
    url: http://link/1
  link2
    description: link
    url: http://link/2

Gong further, form 2 may also benefit from becoming a reference:

externalDocs:
  link1:
    url: http://link/1

paths:
  /path1:
    get:
      externalDocs:
      - $ref: '#/externalDocs/link1'

While some of this may overlap with (the single) externalDocs avaulable in a tag, it is not entirely overlapping, and the link should ideally reside close to where it is needed instead of tracking it back through a tag that may not be immediately apparent will contain the required link.

Issue Analytics

  • State:open
  • Created 6 years ago
  • Reactions:38
  • Comments:15 (4 by maintainers)

github_iconTop GitHub Comments

10reactions
nogatescommented, Jul 30, 2019

FWIW, I always found strange that the key was actually named externalDocs (plural) but only one link was allowed… I think it would make sense to go with the externalDocs map object

4reactions
xaviqocommented, Sep 29, 2022

Bumping this. I also think this would be useful.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Step 8: The externalDocs object (OpenAPI tutorial)
The externalDocs object lets you link to external documentation. You can also provide links to external docs in the paths object.
Read more >
Paths and Operations - Swagger
externalDocs allows referencing an external resource that contains additional documentation. Operation Parameters. Swagger supports operation parameters passed ...
Read more >
Does hyperref work between two files? - LaTeX Stack Exchange
write the following two tex file, docA.tex and docB.tex ... \usepackage{hyperref} \externaldocument[B-]{docB}[docB.pdf]% <- full or relative path ...
Read more >
OpenAPI Definition & Online Tools | Open API Standards List
Reusable components that can be used across multiple endpoints in the API, ... resource for documentation, you can do so with the externalDocs...
Read more >
OpenAPI Specification v3.0.3 | Introduction, Definitions, & More
Each new minor version of the OpenAPI Specification SHALL allow any OpenAPI document that is ... externalDocs, External Documentation Object ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found