在python hug中访问HTTP PUT数据

2024-05-13 19:10:02 发布

您现在位置:Python中文网/ 问答频道 /正文

import hug

something = {'foo': 'bar'}

@hug.put('/')
def update_something():
    something['foo'] = <value_of_bar_from_http_put_request>

如何访问put数据以便更新something?我查找了this和{a2},但什么也没找到。在


Tags: of数据fromimporthttpfooputvalue