mirror of
https://github.com/gosticks/DefinitelyTyped.git
synced 2026-08-11 20:40:20 +00:00
Merge pull request #16601 from Springworks/fix/swagger-schema-official
Fix swagger-schema-official security type
This commit is contained in:
+2
-2
@@ -1,6 +1,6 @@
|
||||
// Type definitions for swagger-schema-official 2.0
|
||||
// Project: http://swagger.io/specification/
|
||||
// Definitions by: Mohsen Azimi <https://github.com/mohsen1>, Ben Southgate <https://github.com/bsouthga>
|
||||
// Definitions by: Mohsen Azimi <https://github.com/mohsen1>, Ben Southgate <https://github.com/bsouthga>, Nicholas Merritt <https://github.com/nimerritt>
|
||||
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
|
||||
|
||||
export interface Info {
|
||||
@@ -224,7 +224,7 @@ export interface Spec {
|
||||
definitions?: {[definitionsName: string]: Schema };
|
||||
parameters?: {[parameterName: string]: BodyParameter|QueryParameter};
|
||||
responses?: {[responseName: string]: Response };
|
||||
security?: Security[];
|
||||
security?: Array<{[securityDefinitionName: string]: string[]}>;
|
||||
securityDefinitions?: { [securityDefinitionName: string]: Security};
|
||||
tags?: Tag[];
|
||||
}
|
||||
|
||||
@@ -1324,3 +1324,16 @@ const uber: swagger.Spec = {
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
const basic_auth: swagger.Spec = {
|
||||
"swagger": "2.0",
|
||||
"info": { "version": "1.0.0", "title": "Minimal example with basic auth"},
|
||||
"schemes": [
|
||||
"https"
|
||||
],
|
||||
"paths": {},
|
||||
"securityDefinitions": {
|
||||
basicAuth: { type: 'basic' },
|
||||
},
|
||||
"security": [{basicAuth: []}]
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user