mirror of
https://github.com/n8n-io/n8n.git
synced 2025-01-12 13:27:31 -08:00
Changed subdomain for domain
This commit is contained in:
parent
8751694680
commit
ccbf80bce2
|
@ -21,11 +21,10 @@ export class RocketchatApi implements ICredentialType {
|
||||||
default: '',
|
default: '',
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
displayName: 'Sub Domain',
|
displayName: 'Domain',
|
||||||
name: 'subdomain',
|
name: 'domain',
|
||||||
type: 'string' as NodePropertyTypes,
|
type: 'string' as NodePropertyTypes,
|
||||||
default: '',
|
default: '',
|
||||||
placeholder: 'n8n'
|
|
||||||
},
|
},
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
|
|
|
@ -16,13 +16,11 @@ export async function rocketchatApiRequest(this: IHookFunctions | IExecuteFuncti
|
||||||
const headerWithAuthentication = Object.assign({}, headers,
|
const headerWithAuthentication = Object.assign({}, headers,
|
||||||
{ 'X-Auth-Token': credentials.authKey, 'X-User-Id': credentials.userId });
|
{ 'X-Auth-Token': credentials.authKey, 'X-User-Id': credentials.userId });
|
||||||
|
|
||||||
const endpoint = 'rocket.chat/api/v1';
|
|
||||||
|
|
||||||
const options: OptionsWithUri = {
|
const options: OptionsWithUri = {
|
||||||
headers: headerWithAuthentication,
|
headers: headerWithAuthentication,
|
||||||
method,
|
method,
|
||||||
body,
|
body,
|
||||||
uri: `https://${credentials.subdomain}.${endpoint}${resource}.${operation}`,
|
uri: `${credentials.endpoint}${resource}.${operation}`,
|
||||||
json: true
|
json: true
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue