feat: Add DeepL integration with translate text action

This commit is contained in:
Faruk AYDIN
2022-11-07 18:28:20 +01:00
parent d681d06de1
commit 527dfe6971
9 changed files with 242 additions and 0 deletions

View File

@@ -0,0 +1,69 @@
import verifyCredentials from './verify-credentials';
import isStillVerified from './is-still-verified';
export default {
fields: [
{
key: 'screenName',
label: 'Screen Name',
type: 'string' as const,
required: true,
readOnly: false,
value: null,
placeholder: null,
description:
'Screen name of your connection to be used on Automatisch UI.',
clickToCopy: false,
},
{
key: 'authenticationKey',
label: 'Authenticatin Key',
type: 'string' as const,
required: true,
readOnly: false,
value: null,
placeholder: null,
description: 'DeepL authentication key of your account.',
clickToCopy: false,
},
],
authenticationSteps: [
{
type: 'mutation' as const,
name: 'createConnection',
arguments: [
{
name: 'key',
value: '{key}',
},
{
name: 'formattedData',
value: null,
properties: [
{
name: 'screenName',
value: '{fields.screenName}',
},
{
name: 'authenticationKey',
value: '{fields.authenticationKey}',
},
],
},
],
},
{
type: 'mutation' as const,
name: 'verifyConnection',
arguments: [
{
name: 'id',
value: '{createConnection.id}',
},
],
},
],
verifyCredentials,
isStillVerified,
};