mirror of
https://github.com/Abdulazizzn/n8n-enterprise-unlocked.git
synced 2025-12-17 01:56:46 +00:00
fix(Action Network Node): Fix pagination issue and add credential test (#3011)
* fix(Action Network Node): Pagination * Fixed lint issue * Added credential test * ⚡ Move credentials verification and injection to the credentials file Co-authored-by: Jonathan Bennetts <jonathan.bennetts@gmail.com> Co-authored-by: ricardo <ricardoespinoza105@gmail.com>
This commit is contained in:
@@ -1,5 +1,8 @@
|
||||
import {
|
||||
ICredentialDataDecryptedObject,
|
||||
ICredentialTestRequest,
|
||||
ICredentialType,
|
||||
IHttpRequestOptions,
|
||||
INodeProperties,
|
||||
} from 'n8n-workflow';
|
||||
|
||||
@@ -15,4 +18,14 @@ export class ActionNetworkApi implements ICredentialType {
|
||||
default: '',
|
||||
},
|
||||
];
|
||||
test: ICredentialTestRequest = {
|
||||
request: {
|
||||
baseURL: 'https://actionnetwork.org/api/v2',
|
||||
url: '/events?per_page=1',
|
||||
},
|
||||
};
|
||||
async authenticate(credentials: ICredentialDataDecryptedObject, requestOptions: IHttpRequestOptions): Promise<IHttpRequestOptions> {
|
||||
requestOptions.headers = { 'OSDI-API-Token': credentials.apiKey };
|
||||
return requestOptions;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user