@@ -4,6 +4,7 @@ import z from 'zod';
44 * Zod schema for OpenAPI security schemes: https://swagger.io/docs/specification/authentication/
55 */
66export const SecuritySchemesSchema = z . record (
7+ z . string ( ) ,
78 z . union ( [
89 z . object ( { type : z . literal ( 'http' ) , scheme : z . literal ( 'basic' ) } ) ,
910 z . object ( { type : z . literal ( 'http' ) , scheme : z . literal ( 'bearer' ) , bearerFormat : z . string ( ) . optional ( ) } ) ,
@@ -20,22 +21,22 @@ export const SecuritySchemesSchema = z.record(
2021 authorizationUrl : z . string ( ) ,
2122 tokenUrl : z . string ( ) ,
2223 refreshUrl : z . string ( ) ,
23- scopes : z . record ( z . string ( ) ) ,
24+ scopes : z . record ( z . string ( ) , z . string ( ) ) ,
2425 } ) ,
2526 implicit : z . object ( {
2627 authorizationUrl : z . string ( ) ,
2728 refreshUrl : z . string ( ) ,
28- scopes : z . record ( z . string ( ) ) ,
29+ scopes : z . record ( z . string ( ) , z . string ( ) ) ,
2930 } ) ,
3031 password : z . object ( {
3132 tokenUrl : z . string ( ) ,
3233 refreshUrl : z . string ( ) ,
33- scopes : z . record ( z . string ( ) ) ,
34+ scopes : z . record ( z . string ( ) , z . string ( ) ) ,
3435 } ) ,
3536 clientCredentials : z . object ( {
3637 tokenUrl : z . string ( ) ,
3738 refreshUrl : z . string ( ) ,
38- scopes : z . record ( z . string ( ) ) ,
39+ scopes : z . record ( z . string ( ) , z . string ( ) ) ,
3940 } ) ,
4041 } ) ,
4142 } ) ,
0 commit comments