Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
28 changes: 27 additions & 1 deletion credentials/CouchbaseApi.credentials.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,9 @@
import { Icon, ICredentialType, INodeProperties } from 'n8n-workflow';
import {
Icon,
ICredentialTestRequest,
ICredentialType,
INodeProperties,
} from 'n8n-workflow';

export class CouchbaseApi implements ICredentialType {
name = 'couchbaseApi';
Expand All @@ -15,12 +20,19 @@ export class CouchbaseApi implements ICredentialType {
name: 'couchbaseConnectionString',
type: 'string',
default: '',
placeholder: 'couchbase://localhost or couchbases://hostname',
description:
'The Couchbase connection string. Use couchbase:// for unencrypted or couchbases:// for TLS connections.',
required: true,
},
{
displayName: 'Username',
name: 'couchbaseUsername',
type: 'string',
default: '',
placeholder: 'Enter your Couchbase username',
description: 'The username for Couchbase authentication',
required: true,
},
{
displayName: 'Password',
Expand All @@ -30,6 +42,20 @@ export class CouchbaseApi implements ICredentialType {
password: true,
},
default: '',
placeholder: 'Enter your Couchbase password',
description: 'The password for Couchbase authentication',
required: true,
},
];

// Credential test to verify connection works
test: ICredentialTestRequest = {
request: {
// This triggers a connection test when saving credentials
// The actual test is performed in the node's connection logic
baseURL: '={{$credentials.couchbaseConnectionString}}',
url: '',
skipSslCertificateValidation: true,
},
};
}
Loading