github.com/thetreep/go-swagger@v0.0.0-20240223100711-35af64f14f01/fixtures/bugs/2919/edge-api/management/auth-policies.yml (about)

     1  ---
     2  
     3  paths:
     4    auth-policies:
     5      get:
     6        summary: List Auth Policies
     7        description: Retrieves a list of Auth Policies
     8        security:
     9          - ztSession: [ ]
    10        tags:
    11          - Auth Policy
    12        operationId: listAuthPolicies
    13        parameters:
    14          - $ref: '../shared/parameters.yml#/limit'
    15          - $ref: '../shared/parameters.yml#/offset'
    16          - $ref: '../shared/parameters.yml#/filter'
    17        responses:
    18          '200':
    19            $ref: '#/responses/listAuthPolicies'
    20          '401':
    21            $ref: '../shared/standard-responses.yml#/responses/unauthorizedResponse'
    22          '400':
    23            $ref: '../shared/standard-responses.yml#/responses/badRequestResponse'
    24      post:
    25        summary: Creates an Auth Policy
    26        description: Creates an Auth Policy. Requires admin access.
    27        security:
    28          - ztSession: [ ]
    29        tags:
    30          - Auth Policy
    31        operationId: createAuthPolicy
    32        parameters:
    33          - name: authPolicy
    34            in: body
    35            required: true
    36            description: An Auth Policy to create
    37            schema:
    38              $ref: '#/definitions/authPolicyCreate'
    39        responses:
    40          '201':
    41            $ref: '../shared/standard-responses.yml#/responses/createResponse'
    42          '400':
    43            $ref: '../shared/standard-responses.yml#/responses/badRequestResponse'
    44          '401':
    45            $ref: '../shared/standard-responses.yml#/responses/unauthorizedResponse'
    46    auth-policies-id:
    47      parameters:
    48        - $ref: '../shared/parameters.yml#/id'
    49      get:
    50        summary: Retrieves a single Auth Policy
    51        description: Retrieves a single Auth Policy by id. Requires admin access.
    52        security:
    53          - ztSession: [ ]
    54        tags:
    55          - Auth Policy
    56        operationId: detailAuthPolicy
    57        responses:
    58          '200':
    59            $ref: '#/responses/detailAuthPolicy'
    60          '404':
    61            $ref: '../shared/standard-responses.yml#/responses/notFoundResponse'
    62          '401':
    63            $ref: '../shared/standard-responses.yml#/responses/unauthorizedResponse'
    64      put:
    65        summary: Update all fields on an Auth Policy
    66        description: Update all fields on an Auth Policy by id. Requires admin access.
    67        security:
    68          - ztSession: [ ]
    69        tags:
    70          - Auth Policy
    71        operationId: updateAuthPolicy
    72        parameters:
    73          - name: authPolicy
    74            in: body
    75            required: true
    76            description: An Auth Policy update object
    77            schema:
    78              $ref: '#/definitions/authPolicyUpdate'
    79        responses:
    80          '200':
    81            $ref: '../shared/standard-responses.yml#/responses/updateResponse'
    82          '400':
    83            $ref: '../shared/standard-responses.yml#/responses/badRequestResponse'
    84          '404':
    85            $ref: '../shared/standard-responses.yml#/responses/notFoundResponse'
    86          '401':
    87            $ref: '../shared/standard-responses.yml#/responses/unauthorizedResponse'
    88      patch:
    89        summary: Update the supplied fields on an Auth Policy
    90        description: Update only the supplied fields on an Auth Policy by id. Requires admin access.
    91        security:
    92          - ztSession: [ ]
    93        tags:
    94          - Auth Policy
    95        operationId: patchAuthPolicy
    96        parameters:
    97          - name: authPolicy
    98            in: body
    99            required: true
   100            description: An Auth Policy patch object
   101            schema:
   102              $ref: '#/definitions/authPolicyPatch'
   103        responses:
   104          '200':
   105            $ref: '../shared/standard-responses.yml#/responses/patchResponse'
   106          '400':
   107            $ref: '../shared/standard-responses.yml#/responses/badRequestResponse'
   108          '404':
   109            $ref: '../shared/standard-responses.yml#/responses/notFoundResponse'
   110          '401':
   111            $ref: '../shared/standard-responses.yml#/responses/unauthorizedResponse'
   112      delete:
   113        summary: Delete an Auth Policy
   114        description: |
   115          Delete an Auth Policy by id. Requires admin access.
   116        security:
   117          - ztSession: [ ]
   118        tags:
   119          - Auth Policy
   120        operationId: deleteAuthPolicy
   121        responses:
   122          '200':
   123            $ref: '../shared/standard-responses.yml#/responses/deleteResponse'
   124          '400':
   125            $ref: '../shared/standard-responses.yml#/responses/badRequestResponse'
   126          '401':
   127            $ref: '../shared/standard-responses.yml#/responses/unauthorizedResponse'
   128  responses:
   129    listAuthPolicies:
   130      description: A list of Auth Policies
   131      schema:
   132        $ref: '#/definitions/listAuthPoliciesEnvelope'
   133    detailAuthPolicy:
   134      description: A singular Auth Policy resource
   135      schema:
   136        $ref: '#/definitions/detailAuthPolicyEnvelope'
   137  
   138  definitions:
   139    listAuthPoliciesEnvelope:
   140      type: object
   141      required:
   142        - meta
   143        - data
   144      properties:
   145        meta:
   146          $ref: '../shared/standard-responses.yml#/definitions/meta'
   147        data:
   148          $ref: '#/definitions/authPolicyList'
   149    detailAuthPolicyEnvelope:
   150      type: object
   151      required:
   152        - meta
   153        - data
   154      properties:
   155        meta:
   156          $ref: '../shared/standard-responses.yml#/definitions/meta'
   157        data:
   158          $ref: '#/definitions/authPolicyDetail'
   159    authPolicyList:
   160      description: An array of Auth Policies resources
   161      type: array
   162      items:
   163        $ref: '#/definitions/authPolicyDetail'
   164    authPolicyPrimary:
   165      type: object
   166      required:
   167        - updb
   168        - cert
   169        - extJwt
   170      properties:
   171        updb:
   172          $ref: '#/definitions/authPolicyPrimaryUpdb'
   173        cert:
   174          $ref: '#/definitions/authPolicyPrimaryCert'
   175        extJwt:
   176          $ref: '#/definitions/authPolicyPrimaryExtJwt'
   177    authPolicyPrimaryUpdb:
   178      type: object
   179      required:
   180        - allowed
   181        - minPasswordLength
   182        - requireSpecialChar
   183        - requireNumberChar
   184        - requireMixedCase
   185        - maxAttempts
   186        - lockoutDurationMinutes
   187      properties:
   188        allowed:
   189          type: boolean
   190        minPasswordLength:
   191          type: integer
   192        requireSpecialChar:
   193          type: boolean
   194        requireNumberChar:
   195          type: boolean
   196        requireMixedCase:
   197          type: boolean
   198        maxAttempts:
   199          type: integer
   200        lockoutDurationMinutes:
   201          type: integer
   202    authPolicyPrimaryCert:
   203      type: object
   204      required:
   205        - allowed
   206        - allowExpiredCerts
   207      properties:
   208        allowed:
   209          type: boolean
   210        allowExpiredCerts:
   211          type: boolean
   212    authPolicyPrimaryExtJwt:
   213      type: object
   214      required:
   215        - allowed
   216        - allowedSigners
   217      properties:
   218        allowed:
   219          type: boolean
   220        allowedSigners:
   221          type: array
   222          items:
   223            type: string
   224    authPolicySecondary:
   225      type: object
   226      required:
   227        - requireTotp
   228      properties:
   229        requireTotp:
   230          type: boolean
   231        requireExtJwtSigner:
   232          type: string
   233          x-omit-empty: false
   234          x-nullable: true
   235  
   236    authPolicyPrimaryPatch:
   237      type: object
   238      properties:
   239        updb:
   240          $ref: '#/definitions/authPolicyPrimaryUpdbPatch'
   241        cert:
   242          $ref: '#/definitions/authPolicyPrimaryCertPatch'
   243        extJwt:
   244          $ref: '#/definitions/authPolicyPrimaryExtJwtPatch'
   245    authPolicyPrimaryUpdbPatch:
   246      type: object
   247      x-nullable: true
   248      properties:
   249        allowed:
   250          type: boolean
   251          x-nullable: true
   252        minPasswordLength:
   253          type: integer
   254          x-nullable: true
   255        requireSpecialChar:
   256          type: boolean
   257          x-nullable: true
   258        requireNumberChar:
   259          type: boolean
   260          x-nullable: true
   261        requireMixedCase:
   262          type: boolean
   263          x-nullable: true
   264        maxAttempts:
   265          type: integer
   266          x-nullable: true
   267        lockoutDurationMinutes:
   268          type: integer
   269          x-nullable: true
   270    authPolicyPrimaryCertPatch:
   271      type: object
   272      x-nullable: true
   273      properties:
   274        allowed:
   275          type: boolean
   276          x-nullable: true
   277        allowExpiredCerts:
   278          type: boolean
   279          x-nullable: true
   280    authPolicyPrimaryExtJwtPatch:
   281      type: object
   282      x-nullable: true
   283      properties:
   284        allowed:
   285          type: boolean
   286          x-nullable: true
   287        allowedSigners:
   288          type: array
   289          items:
   290            type: string
   291          x-nullable: true
   292    authPolicySecondaryPatch:
   293      type: object
   294      x-nullable: true
   295      properties:
   296        requireTotp:
   297          type: boolean
   298          x-nullable: true
   299        requireExtJwtSigner:
   300          type: string
   301          x-nullable: true
   302  
   303    authPolicyDetail:
   304      description: A Auth Policy resource
   305      type: object
   306      allOf:
   307        - $ref: '../shared/base-entity.yml#/definitions/baseEntity'
   308        - type: object
   309          required:
   310            - name
   311            - primary
   312            - secondary
   313          properties:
   314            name:
   315              type: string
   316            primary:
   317              $ref: '#/definitions/authPolicyPrimary'
   318            secondary:
   319              $ref: '#/definitions/authPolicySecondary'
   320    authPolicyCreate:
   321      description: A Auth Policy resource
   322      type: object
   323      required:
   324        - name
   325        - primary
   326        - secondary
   327      properties:
   328        name:
   329          type: string
   330        primary:
   331          $ref: '#/definitions/authPolicyPrimary'
   332        secondary:
   333          $ref: '#/definitions/authPolicySecondary'
   334        tags:
   335          $ref: '../shared/base-entity.yml#/definitions/tags'
   336    authPolicyUpdate:
   337      $ref: '#/definitions/authPolicyCreate'
   338    authPolicyPatch:
   339      description: A Auth Policy resource
   340      type: object
   341      properties:
   342        name:
   343          type: string
   344          x-nullable: true
   345        primary:
   346          $ref: '#/definitions/authPolicyPrimaryPatch'
   347        secondary:
   348          $ref: '#/definitions/authPolicySecondaryPatch'
   349        tags:
   350          $ref: '../shared/base-entity.yml#/definitions/tags'