POST
/
v1
/
s
/
connection
/
authorization
Authorize a connection (sessionToken)
const url = 'https://api.runmorph.dev/v1/s/connection/authorization';
const options = {
  method: 'POST',
  headers: {
    'x-api-key': '<api-key>',
    'x-api-secret': '<api-key>',
    'Content-Type': 'application/json'
  },
  body: '{"scopes":["<string>"],"settings":{}}'
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
{
  "object": "connectionAuthorization",
  "connectorId": "<string>",
  "ownerId": "<string>",
  "status": "<string>",
  "authorizationUrl": "<string>"
}

Authorizations

x-api-key
string
header
required
x-api-secret
string
header
required

Query Parameters

redirectUrl
string<uri>
mode
enum<string>
Available options:
connect,
direct

Body

Response

OK

The response is of type object.