Error 'Couldn't authenticate you' in authorization process via API
投稿日時:2022年10月03日
I have my a Zendesk Chat App that has a search request.
Here is my code:
// Init the client
const client = ZAFClient.init();
...
// Call the metadata first
client.metadata().then(function (metadata) {
...
const config = metadata.settings;
...
const myZendeskSupportSettings = {
type: "GET",
url: `https://mysomesite.zendesk.com/api/v2/search.json?query=type:user example@mail.com`,
headers: {
"Authorization": `Basic ${config.my_zendeskd_suppport_token}` },
dataType: "json"
};
...
client.request(myZendeskSupportSettings).then((data) => {
// does not reach this place, an error appears
});
});
But when I try to make this request I get an error:
{"error":"Couldn't authenticate you"
How to avoid this error?
0
2
2件のコメント
サインインしてコメントを残してください。