diff --git a/packages/nodes-base/credentials/MiroOAuth2Api.credentials.ts b/packages/nodes-base/credentials/MiroOAuth2Api.credentials.ts new file mode 100644 index 0000000000..16e5a0bb7a --- /dev/null +++ b/packages/nodes-base/credentials/MiroOAuth2Api.credentials.ts @@ -0,0 +1,61 @@ +import type { Icon, ICredentialType, INodeProperties } from 'n8n-workflow'; + +export class MiroOAuth2Api implements ICredentialType { + name = 'miroOAuth2Api'; + + extends = ['oAuth2Api']; + + displayName = 'Miro OAuth2 API'; + + documentationUrl = 'miro'; + + icon: Icon = 'file:icons/Miro.svg'; + + httpRequestNode = { + name: 'Miro', + docsUrl: 'https://developers.miro.com/reference/overview', + apiBaseUrl: 'https://api.miro.com/v2/', + }; + + properties: INodeProperties[] = [ + { + displayName: 'Grant Type', + name: 'grantType', + type: 'hidden', + default: 'authorizationCode', + }, + { + displayName: 'Authorization URL', + name: 'authUrl', + type: 'hidden', + default: 'https://miro.com/oauth/authorize', + required: true, + }, + { + displayName: 'Access Token URL', + name: 'accessTokenUrl', + type: 'hidden', + default: 'https://api.miro.com/v1/oauth/token', + required: true, + }, + { + displayName: 'Scope', + name: 'scope', + type: 'hidden', + default: '', + required: true, + }, + { + displayName: 'Auth URI Query Parameters', + name: 'authQueryParameters', + type: 'hidden', + default: '', + }, + { + displayName: 'Authentication', + name: 'authentication', + type: 'hidden', + default: 'body', + }, + ]; +} diff --git a/packages/nodes-base/credentials/icons/Miro.svg b/packages/nodes-base/credentials/icons/Miro.svg new file mode 100644 index 0000000000..b5c804f467 --- /dev/null +++ b/packages/nodes-base/credentials/icons/Miro.svg @@ -0,0 +1,22 @@ + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/packages/nodes-base/package.json b/packages/nodes-base/package.json index 309d93c310..0f67a3657f 100644 --- a/packages/nodes-base/package.json +++ b/packages/nodes-base/package.json @@ -231,6 +231,7 @@ "dist/credentials/MicrosoftToDoOAuth2Api.credentials.js", "dist/credentials/MindeeInvoiceApi.credentials.js", "dist/credentials/MindeeReceiptApi.credentials.js", + "dist/credentials/MiroOAuth2Api.credentials.js", "dist/credentials/MispApi.credentials.js", "dist/credentials/MistApi.credentials.js", "dist/credentials/MoceanApi.credentials.js",