mirror of
https://github.com/n8n-io/n8n-nodes-starter.git
synced 2025-10-28 06:02:25 -05:00
54 lines
1.2 KiB
TypeScript
54 lines
1.2 KiB
TypeScript
import type { Icon, ICredentialType, INodeProperties } from 'n8n-workflow';
|
|
|
|
export class GithubIssuesOAuth2Api implements ICredentialType {
|
|
name = 'githubIssuesOAuth2Api';
|
|
|
|
extends = ['oAuth2Api'];
|
|
|
|
displayName = 'GitHub Issues OAuth2 API';
|
|
|
|
icon: Icon = { light: 'file:../icons/github.svg', dark: 'file:../icons/github.dark.svg' };
|
|
|
|
documentationUrl = 'https://docs.github.com/en/apps/oauth-apps';
|
|
|
|
properties: INodeProperties[] = [
|
|
{
|
|
displayName: 'Grant Type',
|
|
name: 'grantType',
|
|
type: 'hidden',
|
|
default: 'authorizationCode',
|
|
},
|
|
{
|
|
displayName: 'Authorization URL',
|
|
name: 'authUrl',
|
|
type: 'hidden',
|
|
default: 'https://github.com/login/oauth/authorize',
|
|
required: true,
|
|
},
|
|
{
|
|
displayName: 'Access Token URL',
|
|
name: 'accessTokenUrl',
|
|
type: 'hidden',
|
|
default: 'https://github.com/login/oauth/access_token',
|
|
required: true,
|
|
},
|
|
{
|
|
displayName: 'Scope',
|
|
name: 'scope',
|
|
type: 'hidden',
|
|
default: 'repo',
|
|
},
|
|
{
|
|
displayName: 'Auth URI Query Parameters',
|
|
name: 'authQueryParameters',
|
|
type: 'hidden',
|
|
default: '',
|
|
},
|
|
{
|
|
displayName: 'Authentication',
|
|
name: 'authentication',
|
|
type: 'hidden',
|
|
default: 'header',
|
|
},
|
|
];
|
|
}
|