The Black Mesa

Report a typo

Write a program that contains only one view function for the main page and can handle POST, GET, PUT, and CREATE. The latter is the new request type that we came up with for this task. Remember, there are no boundaries. For each request type, display the corresponding message:

request

message

POST

Successfully authorized!

GET

Welcome there!

PUT

Successfully published!

CREATE

Created a new web page!

Use the root URL (/) for this challenge.

Write a program in Python 3
from flask import Flask, request

app = Flask('main')

@app.route('URL, METHODS')
def main_view():
pass # your code here
___

Create a free account to access the full topic