Hi,
I would like to get some clarity on the use of the Create Connection endpoint. I created a new connection as outlined here: https://www.make.com/en/api-documentation/connections-post
Now, there are several issues:
Issue 1: The newly created connection is not listed
I cannot see it neither in the Connections tab in my organisation, nor is it listed when I call https://www.make.com/en/api-documentation/connections-get
However, I can get the connection’s detail, which brings me to the next problem.
Issue 2: OAuth fields are empty
When I obtain the connection’s detail by calling https://www.make.com/en/api-documentation/connections-connectionId-get, then the scopeCount
is 0 and the scopes
array is empty. Also, there is no clientId
or clientSecret
.
To make it clear, if I create a new connection like this:
curl -X POST \
'https://eu1.make.com/api/v2/connections?teamId=1' \
-H 'Authorization: Token abcdefab-1234-5678-abcd-112233445566' \
-H 'Content-Type: application/json' \
-H 'Accept: application/json' \
-d '{"accountName":"Slack Test","accountType":"slack","clientId":123456,"clientSecret":"secret","scopes":["chat:write"]}'
The call is successful and it immediately returns this response:
{
"connection":{
"id":764265,
"name":"Slack Test",
"accountName":"slack",
"accountLabel":"Slack",
"packageName":null,
"expire":null,
"metadata":null,
"teamId":1,
"theme":"#4a154b",
"upgradeable":false,
"scopes":0,
"scoped":true,
"accountType":"oauth",
"editable":false,
"uid":null
}
}
As you can see the defined scopes, clientId and clientSecret are lost.
When I obtain the connection details by calling:
curl -X GET 'https://eu1.make.com/api/v2/connections/764265' -H 'Authorization: Token abcdefab-1234-5678-abcd-112233445566'
I get:
{
"connection":{
"id":764265,
"name":"Slack Test",
"accountName":"slack",
"accountLabel":"Slack",
"packageName":null,
"expire":null,
"metadata":null,
"teamId":55228,
"theme":"#4a154b",
"upgradeable":false,
"scopesCnt":0,
"scoped":true,
"accountType":"oauth",
"editable":false,
"uid":null,
"scopes":[
]
}
}
Can someone pls clarify the correct use the Create connection endpoint? Thank you.