2021-04-24 13:48:22 -03:00
|
|
|
import logging
|
|
|
|
|
|
|
|
|
|
import azure.functions as func
|
2021-05-06 19:14:04 -03:00
|
|
|
#set STORAGE_BLOB_URL='https://pythonazurestorage12345.blob.core.windows.net'
|
2021-04-24 13:48:22 -03:00
|
|
|
|
|
|
|
|
def main(req: func.HttpRequest) -> func.HttpResponse:
|
2021-05-06 19:14:04 -03:00
|
|
|
# https://docs.microsoft.com/pt-br/azure/developer/python/azure-sdk-example-storage-use?tabs=cmd
|
2021-04-24 13:48:22 -03:00
|
|
|
logging.info('Python HTTP trigger function processed a request.')
|
|
|
|
|
|
2021-05-06 19:14:04 -03:00
|
|
|
age = req.params.get('age')
|
|
|
|
|
income = req.params.get('income')
|
|
|
|
|
employeeTime = req.params.get('employeeTime')
|
|
|
|
|
|
|
|
|
|
# Code here.
|
|
|
|
|
|
|
|
|
|
returnedTax = 1;
|
2021-04-24 13:48:22 -03:00
|
|
|
|
|
|
|
|
if name:
|
2021-05-06 19:14:04 -03:00
|
|
|
return func.HttpResponse(returnedTax)
|
2021-04-24 13:48:22 -03:00
|
|
|
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
|
|
|
|
|
)
|