Azure-docs: Importing API having OAuth section does not get the API binded with existing oauth instance

Created on 14 Aug 2019  Â·  4Comments  Â·  Source: MicrosoftDocs/azure-docs

Importing API having OAuth section() does not get the API binded with existing oauth instance, still need operating manually on Azure portal or via scripting to get it done.

I also refered to the this document: authorize developer accounts using OAuth 2.0 and API import restrictions and known issues

Simple Swagger API template with security section.

{
    "swagger": "2.0",
    "info": {
        "title": "",
        "version": "",
        "description": ""
    },
    "host": "",
    "basePath": "",
    "schemes": ["https"],
    "securityDefinitions": {
        "apiKeyHeader": {
            "type": "apiKey",
            "name": "Ocp-Apim-Subscription-Key",
            "in": "header"
        },
        "apiKeyQuery": {
            "type": "apiKey",
            "name": "subscription-key",
            "in": "query"
        },
        "oauth2XXXXAzureADOAuthServer": {
            "type": "oauth2",
            "scopes": {},
            "flow": "accessCode",
            "authorizationUrl": "https://login.microsoftonline.com/XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX/oauth2/authorize",
            "tokenUrl": "https://login.microsoftonline.com/XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX/oauth2/token"
        }
    },
    "security": [{
        "apiKeyHeader": [],
        "oauth2XXXXAzureADOAuthServer": []
    }, {
        "apiKeyQuery": [],
        "oauth2XXXXAzureADOAuthServer": []
    }],
    "paths": {},
    "definitions": {},
    "tags": []
}

Document Details

⚠ Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.

Pri2 api-managemensvc cxp product-question triaged

Most helpful comment

@mikebudzynski thanks for your updates!

API Management does not handle the security definition of OpenAPI document in any way.

If so, it should be a good idea to indicate this restriction in this document --> API import restrictions and known issues, how do you think?

All 4 comments

@ToMakeSense Thank you for your feedback! We will review and provide an update as appropriate.

@vladvino Can you confirm if this is a know restriction from product side?

@KetanChawda-MSFT Yes, API Management does not handle the security definition of OpenAPI document in any way.

In future, please open an Azure support ticket or post your question on Stack Overflow: http://aka.ms/apimso

please-close

@mikebudzynski thanks for your updates!

API Management does not handle the security definition of OpenAPI document in any way.

If so, it should be a good idea to indicate this restriction in this document --> API import restrictions and known issues, how do you think?

Was this page helpful?
0 / 5 - 0 ratings

Related issues

spottedmahn picture spottedmahn  Â·  3Comments

paulmarshall picture paulmarshall  Â·  3Comments

DeepPuddles picture DeepPuddles  Â·  3Comments

bdcoder2 picture bdcoder2  Â·  3Comments

AronT-TLV picture AronT-TLV  Â·  3Comments