Oracle Apex Restful 服务与代码

问题描述 投票:0回答:1

我已使用链接创建了 Oracle Apex 免费帐户 https://apex.oracle.com/en/ 我已经创建了表并为表配置了restful服务。我可以从 Postman Web 和客户端版本获取对 API 端点的调用,但是当我尝试在 VS Code 中运行 python 代码时,我没有得到任何响应。

import requests

url = "https://apex.oracle.com/pls/apex/my_workspacename/sample/"

payload = {}
headers = {
  'Authorization': 'Bearer token_copied_from_postmn',
  'Cookie': 'copied_from_postman'
}

response = requests.request("GET", url, headers=headers, data=payload)

print(response.text)
oracle-apex
1个回答
0
投票

当我使用 HTTP 客户端而不是请求时,它起作用了

© www.soinside.com 2019 - 2024. All rights reserved.