Skip to content

Commit

Permalink
Merge "REST: Improve OAS response headers"
Browse files Browse the repository at this point in the history
  • Loading branch information
jenkins-bot authored and Gerrit Code Review committed Nov 7, 2024
2 parents 95be347 + 8f29f72 commit 4141ee7
Show file tree
Hide file tree
Showing 11 changed files with 1,627 additions and 1,051 deletions.
216 changes: 105 additions & 111 deletions repo/rest-api/specs/global/responses.json

Large diffs are not rendered by default.

24 changes: 16 additions & 8 deletions repo/rest-api/specs/resources/aliases/responses.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,13 @@
"headers": {
"ETag": {
"description": "Last entity revision number",
"schema": { "type": "string" }
"schema": { "type": "string" },
"required": true
},
"Last-Modified": {
"description": "Last modified date",
"schema": { "type": "string" }
"schema": { "type": "string" },
"required": true
},
"X-Authenticated-User": {
"description": "Optional username of the user making the request",
Expand All @@ -30,11 +32,13 @@
"headers": {
"ETag": {
"description": "Last entity revision number",
"schema": { "type": "string" }
"schema": { "type": "string" },
"required": true
},
"Last-Modified": {
"description": "Last modified date",
"schema": { "type": "string" }
"schema": { "type": "string" },
"required": true
},
"X-Authenticated-User": {
"description": "Optional username of the user making the request",
Expand All @@ -56,11 +60,13 @@
"headers": {
"ETag": {
"description": "Last entity revision number",
"schema": { "type": "string" }
"schema": { "type": "string" },
"required": true
},
"Last-Modified": {
"description": "Last modified date",
"schema": { "type": "string" }
"schema": { "type": "string" },
"required": true
},
"X-Authenticated-User": {
"description": "Optional username of the user making the request",
Expand All @@ -82,11 +88,13 @@
"headers": {
"ETag": {
"description": "Last entity revision number",
"schema": { "type": "string" }
"schema": { "type": "string" },
"required": true
},
"Last-Modified": {
"description": "Last modified date",
"schema": { "type": "string" }
"schema": { "type": "string" },
"required": true
},
"X-Authenticated-User": {
"description": "Optional username of the user making the request",
Expand Down
51 changes: 30 additions & 21 deletions repo/rest-api/specs/resources/descriptions/responses.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,15 @@
"ItemDescriptions": {
"description": "Item's descriptions by language",
"headers": {
"Last-Modified": {
"description": "Last modified date",
"schema": { "type": "string" }
},
"ETag": {
"description": "Last entity revision number",
"schema": { "type": "string" }
"schema": { "type": "string" },
"required": true
},
"Last-Modified": {
"description": "Last modified date",
"schema": { "type": "string" },
"required": true
},
"X-Authenticated-User": {
"description": "Optional username of the user making the request",
Expand All @@ -28,13 +30,15 @@
"PropertyDescriptions": {
"description": "Property's descriptions by language",
"headers": {
"Last-Modified": {
"description": "Last modified date",
"schema": { "type": "string" }
},
"ETag": {
"description": "Last entity revision number",
"schema": { "type": "string" }
"schema": { "type": "string" },
"required": true
},
"Last-Modified": {
"description": "Last modified date",
"schema": { "type": "string" },
"required": true
},
"X-Authenticated-User": {
"description": "Optional username of the user making the request",
Expand All @@ -54,13 +58,15 @@
"ItemDescription": {
"description": "Item's description in a specific language",
"headers": {
"Last-Modified": {
"description": "Last modified date",
"schema": { "type": "string" }
},
"ETag": {
"description": "Last entity revision number",
"schema": { "type": "string" }
"schema": { "type": "string" },
"required": true
},
"Last-Modified": {
"description": "Last modified date",
"schema": { "type": "string" },
"required": true
},
"X-Authenticated-User": {
"description": "Optional username of the user making the request",
Expand All @@ -77,13 +83,15 @@
"PropertyDescription": {
"description": "Property's description in a specific language",
"headers": {
"Last-Modified": {
"description": "Last modified date",
"schema": { "type": "string" }
},
"ETag": {
"description": "Last entity revision number",
"schema": { "type": "string" }
"schema": { "type": "string" },
"required": true
},
"Last-Modified": {
"description": "Last modified date",
"schema": { "type": "string" },
"required": true
},
"X-Authenticated-User": {
"description": "Optional username of the user making the request",
Expand All @@ -102,7 +110,8 @@
"headers": {
"Content-Language": {
"description": "Language code of the language in which response is provided",
"schema": { "type": "string" }
"schema": { "type": "string" },
"required": true
},
"X-Authenticated-User": {
"description": "Optional username of the user making the request",
Expand Down
6 changes: 4 additions & 2 deletions repo/rest-api/specs/resources/items/responses.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,9 @@
},
"headers": {
"Content-Language": {
"description": "Language code of the language in which error message is provided",
"schema": { "type": "string" },
"description": "Language code of the language in which error message is provided"
"required": true
}
}
},
Expand All @@ -35,8 +36,9 @@
},
"headers": {
"Content-Language": {
"description": "Language code of the language in which error message is provided",
"schema": { "type": "string" },
"description": "Language code of the language in which error message is provided"
"required": true
}
}
}
Expand Down
51 changes: 30 additions & 21 deletions repo/rest-api/specs/resources/labels/responses.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,15 @@
"ItemLabels": {
"description": "Item's labels by language",
"headers": {
"Last-Modified": {
"description": "Last modified date",
"schema": { "type": "string" }
},
"ETag": {
"description": "Last entity revision number",
"schema": { "type": "string" }
"schema": { "type": "string" },
"required": true
},
"Last-Modified": {
"description": "Last modified date",
"schema": { "type": "string" },
"required": true
},
"X-Authenticated-User": {
"description": "Optional username of the user making the request",
Expand All @@ -28,13 +30,15 @@
"PropertyLabels": {
"description": "Property's labels by language",
"headers": {
"Last-Modified": {
"description": "Last modified date",
"schema": { "type": "string" }
},
"ETag": {
"description": "Last entity revision number",
"schema": { "type": "string" }
"schema": { "type": "string" },
"required": true
},
"Last-Modified": {
"description": "Last modified date",
"schema": { "type": "string" },
"required": true
},
"X-Authenticated-User": {
"description": "Optional username of the user making the request",
Expand All @@ -54,13 +58,15 @@
"ItemLabel": {
"description": "A label in a specific language",
"headers": {
"Last-Modified": {
"description": "Last modified date",
"schema": { "type": "string" }
},
"ETag": {
"description": "Last entity revision number",
"schema": { "type": "string" }
"schema": { "type": "string" },
"required": true
},
"Last-Modified": {
"description": "Last modified date",
"schema": { "type": "string" },
"required": true
},
"X-Authenticated-User": {
"description": "Optional username of the user making the request",
Expand All @@ -77,13 +83,15 @@
"PropertyLabel": {
"description": "A label in a specific language",
"headers": {
"Last-Modified": {
"description": "Last modified date",
"schema": { "type": "string" }
},
"ETag": {
"description": "Last entity revision number",
"schema": { "type": "string" }
"schema": { "type": "string" },
"required": true
},
"Last-Modified": {
"description": "Last modified date",
"schema": { "type": "string" },
"required": true
},
"X-Authenticated-User": {
"description": "Optional username of the user making the request",
Expand All @@ -102,7 +110,8 @@
"headers": {
"Content-Language": {
"description": "Language code of the language in which response is provided",
"schema": { "type": "string" }
"schema": { "type": "string" },
"required": true
},
"X-Authenticated-User": {
"description": "Optional username of the user making the request",
Expand Down
6 changes: 4 additions & 2 deletions repo/rest-api/specs/resources/properties/responses.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,9 @@
},
"headers": {
"Content-Language": {
"description": "Language code of the language in which error message is provided",
"schema": { "type": "string" },
"description": "Language code of the language in which error message is provided"
"required": true
}
}
},
Expand All @@ -35,8 +36,9 @@
},
"headers": {
"Content-Language": {
"description": "Language code of the language in which error message is provided",
"schema": { "type": "string" },
"description": "Language code of the language in which error message is provided"
"required": true
}
}
}
Expand Down
15 changes: 10 additions & 5 deletions repo/rest-api/specs/resources/sitelinks/responses.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,9 @@
},
"headers": {
"Content-Language": {
"description": "Language code of the language in which error message is provided",
"schema": { "type": "string" },
"description": "Language code of the language in which error message is provided"
"required": true
}
}
},
Expand All @@ -28,7 +29,8 @@
"headers": {
"Content-Language": {
"description": "Language code of the language in which response is provided",
"schema": { "type": "string" }
"schema": { "type": "string" },
"required": true
},
"X-Authenticated-User": {
"description": "Optional username of the user making the request",
Expand Down Expand Up @@ -58,8 +60,9 @@
},
"headers": {
"Content-Language": {
"description": "Language code of the language in which error message is provided",
"schema": { "type": "string" },
"description": "Language code of the language in which error message is provided"
"required": true
}
}
},
Expand All @@ -80,8 +83,9 @@
},
"headers": {
"Content-Language": {
"description": "Language code of the language in which error message is provided",
"schema": { "type": "string" },
"description": "Language code of the language in which error message is provided"
"required": true
}
}
},
Expand All @@ -97,8 +101,9 @@
},
"headers": {
"Content-Language": {
"description": "Language code of the language in which error message is provided",
"schema": { "type": "string" },
"description": "Language code of the language in which error message is provided"
"required": true
}
}
}
Expand Down
15 changes: 9 additions & 6 deletions repo/rest-api/specs/resources/statements/list-for-item.json
Original file line number Diff line number Diff line change
Expand Up @@ -39,18 +39,21 @@
"headers": {
"ETag": {
"description": "Last entity revision number",
"schema": { "type": "string" }
"schema": { "type": "string" },
"required": true
},
"Last-Modified": {
"description": "Last modified date",
"schema": { "type": "string" }
},
"X-Authenticated-User": {
"description": "Optional username of the user making the request",
"schema": { "type": "string" }
"schema": { "type": "string" },
"required": true
},
"Location": {
"description": "The URI of the newly created Statement",
"schema": { "type": "string" },
"required": true
},
"X-Authenticated-User": {
"description": "Optional username of the user making the request",
"schema": { "type": "string" }
}
},
Expand Down
Loading

0 comments on commit 4141ee7

Please sign in to comment.