Layer7 API Management

 View Only
Expand all | Collapse all

How to Define Parametric Scopes within Swagger UI ? API Portal 5.x

  • 1.  How to Define Parametric Scopes within Swagger UI ? API Portal 5.x

    Posted Jan 27, 2023 04:11 AM
    Hi All, 
    We're trying to publish a sample Swagger on API Portal 5.x and we need to pass scope as a parameter during testing through swagger.ui , 
    Do you know how to do this ?  Since user requests it's own scopes during registration ? we should pass scope as a free text during swagger-ui testin ? is it right ? Attached you can find the screen-shots, 
    Br, 
    Onur

    Attachment(s)

    zip
    test_swagger_json.zip   4 KB 1 version


  • 2.  RE: How to Define Parametric Scopes within Swagger UI ? API Portal 5.x

    Posted Mar 28, 2023 11:40 AM

    Hi @Onur Fenar ,

    I assume that you are trying to achieve that with the Layer7 developer portal's swaggerui.
    You can modify the developer portal's frontend using the customization options - modify the javascript function behind the Authorize button and inject your scope there or place an additional input field and use its value. 



    ------------------------------
    Regards,
    Mesut Yalcin - Senior Solution Engineer
    APIIDA AG - https://www.apiida.com
    ------------------------------