<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Documentation | Nerdpress.org</title>
	<atom:link href="https://nerdpress.org/category/api/documentation/feed/" rel="self" type="application/rss+xml" />
	<link>https://nerdpress.org</link>
	<description>...dev, tech problems and solutions.</description>
	<lastBuildDate>Mon, 02 Oct 2017 05:49:15 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=6.9.4</generator>
	<item>
		<title>Splitting Swagger API Documentation yaml files</title>
		<link>https://nerdpress.org/2017/10/01/splitting-swagger-api-documentation-yaml-files/</link>
					<comments>https://nerdpress.org/2017/10/01/splitting-swagger-api-documentation-yaml-files/#comments</comments>
		
		<dc:creator><![CDATA[Max Girkens]]></dc:creator>
		<pubDate>Sun, 01 Oct 2017 06:00:22 +0000</pubDate>
				<category><![CDATA[API]]></category>
		<category><![CDATA[Documentation]]></category>
		<category><![CDATA[swagger]]></category>
		<guid isPermaLink="false">https://nerdpress.org/?p=2777</guid>

					<description><![CDATA[<p>When documenting your API with Swagger/Swagger-UI, one really cool feature to use is the $ref syntax. As Swagger documentation files tend to get real large und hard too read, splitting the config across multiple files might be a good idea. With $ref you could do this quite easily. For example you could reference a single &#8230; </p>
<p class="link-more"><a href="https://nerdpress.org/2017/10/01/splitting-swagger-api-documentation-yaml-files/" class="more-link">Continue reading<span class="screen-reader-text"> "Splitting Swagger API Documentation yaml files"</span></a></p>
The post <a href="https://nerdpress.org/2017/10/01/splitting-swagger-api-documentation-yaml-files/">Splitting Swagger API Documentation yaml files</a> first appeared on <a href="https://nerdpress.org">Nerdpress.org</a>.]]></description>
										<content:encoded><![CDATA[<p>When documenting your API with <a href="https://swagger.io/swagger-ui/">Swagger/Swagger-UI</a>, one really cool feature to use is the <em>$ref</em> syntax.</p>
<p>As Swagger documentation files tend to get real large und hard too read, splitting the config across multiple files might be a good idea.<br />
With <em>$ref</em> you could do this quite easily.<br />
<span id="more-2777"></span><br />
For example you could reference a single config file per path like so:</p>
<pre class="brush: yaml; title: ; notranslate">
swagger: &quot;2.0&quot;
basePath: &quot;my-api/v1/&quot;
info:
  version: &quot;0.0.1&quot;
  title: &quot;my API&quot;
tags:
  - name: &quot;section1&quot;
    description: &quot;Some Section&quot;
  - name: &quot;section2&quot;
    description: &quot;Some other Section&quot;

paths:

  ##section 1

  /section1/some/path:
    $ref: 'paths/section1_some_path.yml'

  /section1/some-other-path:
    $ref: 'paths/section1_some_other_path.yml'
</pre>
<p>Then have all actions for this path defined in a dedicated file like this:</p>
<p><strong>paths/section1_some_path.yml:</strong></p>
<pre class="brush: yaml; title: ; notranslate">
post:
  tags:
  - &quot;section1&quot;
  parameters:
    ...
</pre>
<p>This really helped me managing larger documentation files, which otherwise tend to get quite hard to read.</p>The post <a href="https://nerdpress.org/2017/10/01/splitting-swagger-api-documentation-yaml-files/">Splitting Swagger API Documentation yaml files</a> first appeared on <a href="https://nerdpress.org">Nerdpress.org</a>.]]></content:encoded>
					
					<wfw:commentRss>https://nerdpress.org/2017/10/01/splitting-swagger-api-documentation-yaml-files/feed/</wfw:commentRss>
			<slash:comments>1</slash:comments>
		
		
			</item>
	</channel>
</rss>
