我有一个有效的REST API链接http://192.168.1.5:8080/SpringRestHibernate/student/1
我已经在同一台计算机上下载了WSO2 API管理器工具包,并且wso2server.sh正在运行,我正在尝试通过api管理器URL来访问上面提到的其余api。
即使我在API控制台中提供了正确的令牌,也会收到以下响应。未提供必需的OAuth凭据。确保您的API调用调用具有标头:“授权:承载ACCESS_TOKEN”
任何人都可以帮助我,如何删除通过UI设置的身份验证。
在编辑API的api发布器中,转到“设计”标签(第一个标签),然后在“ API定义”下单击“编辑源”。在源代码中,API的每个资源都将具有x-auth-type属性,将该值更改为none,并且该API将不再需要身份验证。
之前:
/CheckPhoneNumber:
get:
responses:
'200':
description: ''
x-auth-type: Application & Application User
x-throttling-tier: Unlimited
post:
responses:
'200':
description: ''
x-auth-type: Application & Application User
x-throttling-tier: Unlimited
禁用身份验证后:
/CheckPhoneNumber:
get:
responses:
'200':
description: ''
x-auth-type: None
x-throttling-tier: Unlimited
post:
responses:
'200':
description: ''
x-auth-type: None
x-throttling-tier: Unlimited