2023-07-31 01:26:38 -07:00
|
|
|
import type { IAuthenticateGeneric, ICredentialType, INodeProperties } from 'n8n-workflow';
|
|
|
|
|
|
|
|
export class FortiGateApi implements ICredentialType {
|
|
|
|
name = 'fortiGateApi';
|
|
|
|
|
|
|
|
displayName = 'Fortinet FortiGate API';
|
|
|
|
|
2023-08-09 06:16:11 -07:00
|
|
|
documentationUrl = 'fortigate';
|
|
|
|
|
2023-07-31 01:26:38 -07:00
|
|
|
icon = 'file:icons/Fortinet.svg';
|
|
|
|
|
|
|
|
properties: INodeProperties[] = [
|
|
|
|
{
|
|
|
|
displayName: 'Access Token',
|
|
|
|
name: 'accessToken',
|
|
|
|
type: 'string',
|
|
|
|
typeOptions: { password: true },
|
|
|
|
default: '',
|
|
|
|
required: true,
|
|
|
|
},
|
|
|
|
];
|
|
|
|
|
|
|
|
authenticate: IAuthenticateGeneric = {
|
|
|
|
type: 'generic',
|
|
|
|
properties: {
|
|
|
|
qs: {
|
|
|
|
access_token: '={{$credentials.accessToken}}',
|
|
|
|
},
|
|
|
|
},
|
|
|
|
};
|
|
|
|
}
|