Warning: file_get_contents(/data/phpspider/zhask/data//catemap/8/variables/2.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
如何在WSO2 API管理器中注册REST客户端_Wso2_Wso2 Am - Fatal编程技术网

如何在WSO2 API管理器中注册REST客户端

如何在WSO2 API管理器中注册REST客户端,wso2,wso2-am,Wso2,Wso2 Am,我一直在看wso2 apim的医生。 并找到了curl请求: curl -X POST -H "Authorization: Basic YWRtaW46YWRtaW4=" -H "Content-Type: application/json" -d @payload.json http://localhost:9763/client-registration/v0.9/register 有效载荷: { "callbackUrl": "www.google.lk", "clientName"

我一直在看wso2 apim的医生。

并找到了curl请求:

curl -X POST -H "Authorization: Basic YWRtaW46YWRtaW4=" -H "Content-Type: application/json" -d @payload.json http://localhost:9763/client-registration/v0.9/register
有效载荷:

{
"callbackUrl": "www.google.lk",
"clientName": "rest_api_store",
"tokenScope": "Production",
"owner": "admin",
"grantType": "password refresh_token",
"saasApp": true
}
但我得到了403的错误响应。 正如预期的那样,我应该得到正确的响应负载,如:

{
"callBackURL": "www.google.lk",
"jsonString":
"{
\"username\":\"admin\",
\"redirect_uris\":\"www.google.lk\",
\"tokenScope\":[Ljava.lang.String;@3a73796a,
\"client_name\":\"admin_rest_api_store\",
\"grant_types\":\"authorization_code password refresh_token iwa:ntlm
urn:ietf:params:oauth:grant-type:saml2-bearer client_credentialsimplicit\"
}",
"clientName": null,
"clientId": "HfEl1jJPdg5tbtrxhAwybN05QGoa",
"clientSecret": "l6c0aoLcWR3fwezHhc7XoGOht5Aa"
}
我不知道发生了什么,我只是按照上面的文件做了,没有任何改变。 如果有人能帮忙,我们将不胜感激。
谢谢。

看起来您的DCR呼叫被某个安全筛选器阻止。可能是因为你到达了一个错误的终点

我相信您正在使用APIM 2.0.0。如果是,您的DCR url应为。(注意版本
v0.10

试试看这是否解决了你的问题

更新:看起来此URL在上是错误的。我会联系WSO2文档团队来修复它

http://localhost:9763/client-registration/v0.10/register