2023-01-27 03:22:44 -08:00
|
|
|
import type { ICredentialType, INodeProperties } from 'n8n-workflow';
|
2021-03-03 16:09:31 -08:00
|
|
|
|
|
|
|
export class BubbleApi implements ICredentialType {
|
|
|
|
name = 'bubbleApi';
|
2022-12-02 12:54:28 -08:00
|
|
|
|
2021-03-03 16:09:31 -08:00
|
|
|
displayName = 'Bubble API';
|
2022-12-02 12:54:28 -08:00
|
|
|
|
2021-03-03 16:09:31 -08:00
|
|
|
documentationUrl = 'bubble';
|
2022-12-02 12:54:28 -08:00
|
|
|
|
2021-06-12 09:39:55 -07:00
|
|
|
properties: INodeProperties[] = [
|
2021-03-03 16:09:31 -08:00
|
|
|
{
|
|
|
|
displayName: 'API Token',
|
|
|
|
name: 'apiToken',
|
2021-06-12 09:39:55 -07:00
|
|
|
type: 'string',
|
2023-08-01 04:08:25 -07:00
|
|
|
typeOptions: { password: true },
|
2021-03-03 16:09:31 -08:00
|
|
|
default: '',
|
|
|
|
},
|
|
|
|
{
|
|
|
|
displayName: 'App Name',
|
|
|
|
name: 'appName',
|
2021-06-12 09:39:55 -07:00
|
|
|
type: 'string',
|
2021-03-03 16:09:31 -08:00
|
|
|
default: '',
|
|
|
|
},
|
|
|
|
{
|
|
|
|
displayName: 'Environment',
|
|
|
|
name: 'environment',
|
2021-06-12 09:39:55 -07:00
|
|
|
type: 'options',
|
2021-03-03 16:09:31 -08:00
|
|
|
default: 'live',
|
|
|
|
options: [
|
|
|
|
{
|
|
|
|
name: 'Development',
|
|
|
|
value: 'development',
|
|
|
|
},
|
|
|
|
{
|
|
|
|
name: 'Live',
|
|
|
|
value: 'live',
|
|
|
|
},
|
|
|
|
],
|
|
|
|
},
|
|
|
|
{
|
|
|
|
displayName: 'Hosting',
|
|
|
|
name: 'hosting',
|
2021-06-12 09:39:55 -07:00
|
|
|
type: 'options',
|
2021-03-03 16:09:31 -08:00
|
|
|
default: 'bubbleHosted',
|
|
|
|
options: [
|
|
|
|
{
|
2022-04-13 23:32:27 -07:00
|
|
|
name: 'Bubble-Hosted',
|
2021-03-03 16:09:31 -08:00
|
|
|
value: 'bubbleHosted',
|
|
|
|
},
|
|
|
|
{
|
2022-04-13 23:32:27 -07:00
|
|
|
name: 'Self-Hosted',
|
2021-03-03 16:09:31 -08:00
|
|
|
value: 'selfHosted',
|
|
|
|
},
|
|
|
|
],
|
|
|
|
},
|
|
|
|
{
|
|
|
|
displayName: 'Domain',
|
|
|
|
name: 'domain',
|
2021-06-12 09:39:55 -07:00
|
|
|
type: 'string',
|
2021-03-03 16:09:31 -08:00
|
|
|
placeholder: 'mydomain.com',
|
|
|
|
default: '',
|
|
|
|
displayOptions: {
|
|
|
|
show: {
|
2022-07-24 08:36:17 -07:00
|
|
|
hosting: ['selfHosted'],
|
2021-03-03 16:09:31 -08:00
|
|
|
},
|
|
|
|
},
|
|
|
|
},
|
|
|
|
];
|
|
|
|
}
|