azureazure-functions

Azure portal not showing Azure functions


When I deploy the Azure Function project from VSCode to a new Function App, I get the Create Function App "name" Succeeded notification.

enter image description here

However, Funtion is not visible in both the VSCode directory and Azure Portal. enter image description here

enter image description here

Function Code:

import azure.functions as func
import logging

app = func.FunctionApp(http_auth_level=func.AuthLevel.FUNCTION)

@app.route(route="http_trigger")
def http_trigger(req: func.HttpRequest) -> func.HttpResponse:
    logging.info('Python HTTP trigger function processed a request.')

    name = req.params.get('name')
    if not name:
        try:
            req_body = req.get_json()
        except ValueError:
            pass
        else:
            name = req_body.get('name')

    if name:
        return func.HttpResponse(f"Hello, {name}. This HTTP triggered function executed successfully.")
    else:
        return func.HttpResponse(
             "This HTTP triggered function executed successfully. Pass a name in the query string or in the request body for a personalized response.",
             status_code=200
        )

Solution

  • enter image description here

    enter image description here

    Deployment status:

    enter image description here

    Refresh the Resources and check the deployed functions in your function app.

    enter image description here

    Portal:

    enter image description here

    enter image description here