Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
dd041aefde |
@@ -1,48 +1,59 @@
|
|||||||
import type {
|
import type {
|
||||||
IAuthenticateGeneric,
|
IAuthenticateGeneric,
|
||||||
Icon,
|
Icon,
|
||||||
ICredentialType,
|
ICredentialType,
|
||||||
INodeProperties,
|
INodeProperties,
|
||||||
} from 'n8n-workflow';
|
} from 'n8n-workflow';
|
||||||
|
|
||||||
export class BillbeeApi implements ICredentialType {
|
export class BillbeeApi implements ICredentialType {
|
||||||
name = 'N8nDevBillbeeApi';
|
name = 'N8nDevBillbeeApi';
|
||||||
|
displayName = 'Billbee API';
|
||||||
|
icon: Icon = { light: 'file:../nodes/Billbee/billbee.png', dark: 'file:../nodes/Billbee/billbee.dark.png' };
|
||||||
|
documentationUrl = '';
|
||||||
|
|
||||||
displayName = 'Billbee API';
|
properties: INodeProperties[] = [
|
||||||
|
{
|
||||||
|
displayName: 'Base URL',
|
||||||
|
name: 'url',
|
||||||
|
type: 'string',
|
||||||
|
default: 'https://app.billbee.io',
|
||||||
|
required: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
displayName: 'API Key',
|
||||||
|
name: 'apiKey',
|
||||||
|
type: 'string',
|
||||||
|
typeOptions: { password: true },
|
||||||
|
default: '',
|
||||||
|
required: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
displayName: 'Billbee Benutzername / E-Mail',
|
||||||
|
name: 'username',
|
||||||
|
type: 'string',
|
||||||
|
default: '',
|
||||||
|
required: true,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
displayName: 'API-Passwort',
|
||||||
|
name: 'password',
|
||||||
|
type: 'string',
|
||||||
|
typeOptions: { password: true },
|
||||||
|
default: '',
|
||||||
|
required: true,
|
||||||
|
},
|
||||||
|
];
|
||||||
|
|
||||||
icon: Icon = { light: 'file:../nodes/Billbee/billbee.png', dark: 'file:../nodes/Billbee/billbee.dark.png' };
|
authenticate: IAuthenticateGeneric = {
|
||||||
|
type: 'generic',
|
||||||
documentationUrl = '';
|
properties: {
|
||||||
|
headers: {
|
||||||
properties: INodeProperties[] = [
|
'X-Billbee-Api-Key': '={{$credentials.apiKey}}',
|
||||||
{
|
},
|
||||||
displayName: 'Base URL',
|
auth: {
|
||||||
name: 'url',
|
username: '={{$credentials.username}}',
|
||||||
type: 'string',
|
password: '={{$credentials.password}}',
|
||||||
default: 'https://app.billbee.io',
|
},
|
||||||
required: true,
|
},
|
||||||
placeholder: 'https://app.billbee.io',
|
};
|
||||||
description: 'The base URL of your Billbee API server',
|
}
|
||||||
},
|
|
||||||
{
|
|
||||||
displayName: 'API Key',
|
|
||||||
name: 'apiKey',
|
|
||||||
type: 'string',
|
|
||||||
typeOptions: { password: true },
|
|
||||||
default: '',
|
|
||||||
required: false,
|
|
||||||
},
|
|
||||||
|
|
||||||
];
|
|
||||||
|
|
||||||
authenticate: IAuthenticateGeneric = {
|
|
||||||
type: 'generic',
|
|
||||||
properties: {
|
|
||||||
headers: {
|
|
||||||
'X-Billbee-Api-Key': '={{$credentials.apiKey}}',
|
|
||||||
},
|
|
||||||
},
|
|
||||||
};
|
|
||||||
|
|
||||||
|
|
||||||
}
|
|
||||||
Reference in New Issue
Block a user