From d500c436c6fdf63161f935b1acee579a162523a3 Mon Sep 17 00:00:00 2001 From: Blake Erickson Date: Tue, 7 Sep 2021 10:35:56 -0600 Subject: [PATCH] DEV: Add license field to api docs info section (#14248) One of the fields that should be present for openapi docs is the "license" field. https://spec.openapis.org/oas/latest.html#infoObject Our API docs already had a license, so this commit just specifies that and provides a link to it. --- spec/swagger_helper.rb | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/spec/swagger_helper.rb b/spec/swagger_helper.rb index 13821cde957..85cec5a9788 100644 --- a/spec/swagger_helper.rb +++ b/spec/swagger_helper.rb @@ -95,7 +95,11 @@ RSpec.configure do |config| url: 'https://discourse-meta.s3-us-west-1.amazonaws.com/optimized/3X/9/d/9d543e92b15b06924249654667a81441a55867eb_1_690x184.png', }, version: 'latest', - description: api_docs_description + description: api_docs_description, + license: { + name: 'MIT', + url: 'https://docs.discourse.org/LICENSE.txt' + } }, paths: {}, servers: [