{
    "customfieldId": "customfield_11207",
    "isCustomFieldMissing": false,
    "name": "Deepl - Translate summary",
    "fieldType": "UNPLUGGED",
    "datasource": {
        "name": "Deepl",
        "category": "URL",
        "responseContentType": "JSON",
        "datasourceDefinitionId": "default:conf:24",
        "rootUrl": "https://api.deepl.com/v2"
    },
    "datasourceDefinitionId": "default:conf:24",
    "customFieldMissing": false,
    "editView": {
        "widgetType": "READONLY",
        "fieldRequestConfiguration": {
            "query": "## Set your Deepl auth key - see https://www.deepl.com/en/docs-api.html\n#set($AUTH_KEY = 'your-deepl-auth-key')\n\n## Translate the description only if longer than 10 chars and if target language is selected\n#if($issue.description.length() < 10 || !$issue.customfield_11308)\n  $query.abort()\n#end\n\n## Set target languages based on the value selected in the \"Translate to\" custom field\n## this part can be removed if the target language is static\n#if($issue.customfield_11308.getOptionName() == \"Dutch\")\n  #set($lang = \"NL\")\n#elseif($issue.customfield_11308.getOptionName() == \"English\")\n  #set($lang = \"EN\")\n#elseif($issue.customfield_11308.getOptionName() == \"French\")\n  #set($lang = \"FR\")\n#elseif($issue.customfield_11308.getOptionName() == \"German\")\n  #set($lang = \"DE\")\n#elseif($issue.customfield_11308.getOptionName() == \"Italian\")\n  #set($lang = \"IT\")\n#elseif($issue.customfield_11308.getOptionName() == \"Polish\")\n  #set($lang = \"PL\")\n#elseif($issue.customfield_11308.getOptionName() == \"Portuguese\")\n  #set($lang = \"PT\")\n#elseif($issue.customfield_11308.getOptionName() == \"Russian\")\n  #set($lang = \"RU\")\n#elseif($issue.customfield_11308.getOptionName() == \"Spanish\")\n  #set($lang = \"ES\")\n#end\n\n\ntranslate?\nauth_key=$AUTH_KEY\n&text=$util.encodeURI($issue.description)\n&target_lang=$lang\n&preserve_formatting=1",
            "dateFormat": "TIMESTAMP_S",
            "jsonRootPath": "$.translations[0]",
            "jsonColumns": [
                {
                    "name": "text",
                    "path": "$.text"
                }
            ]
        },
        "fieldWidgetConfiguration": {
            "isMultiple": false,
            "isDisplayUnique": false,
            "noResultLabel": "Set a description and select a target language",
            "maxSuggestions": 1500,
            "editFirstDisplay": false,
            "nbLinesDefault": 0,
            "autoSelectUnique": false,
            "autoSelectAll": false,
            "alphaSort": false,
            "templateConfiguration": {
                "displayTemplateMode": "CUSTOM",
                "displayTemplate": "{0}"
            }
        }
    },
    "displayView": {},
    "advancedView": {
        "debuggerActive": false,
        "cacheActive": true,
        "cacheDuration": 2592000000,
        "bypassJqlSecurity": false
    }
}
