hmLoadTopic({
hmKeywords:"",
hmTitle:"Configura ESET PROTECT On-Prem REST API",
hmDescription:"Segui i passaggi sottostanti per configurare ESET PROTECT On-Prem REST API:",
hmPrevLink:"how_api_works.html",
hmNextLink:"api.html",
hmParentLink:"rest_api.html",
hmBreadCrumbs:"<a href=\"rest_api.html\">ESET PROTECT On-Prem REST API<\/a>",
hmTitlePath:"ESET PROTECT On-Prem REST API > Configura ESET PROTECT On-Prem REST API",
hmHeader:"<h1 class=\"p_Heading1\"><span class=\"f_Heading1\">Configura ESET PROTECT On-Prem REST API<\/span><\/h1>\n\r",
hmBody:"<p class=\"p_Normal\">Segui i passaggi sottostanti per configurare ESET PROTECT On-Prem REST API:<\/p>\n\r<p class=\"p_Normal\" style=\"text-indent: 0; padding-left: 20px; margin-left: 0;\"><span class=\"f_Normal\" style=\"display:inline-block;width:20px;margin-left:-20px\">1.<\/span>Abilita REST API in <span class=\"f_UI\">Più<\/span> &gt; <a href=\"admin_server_settings.html#api\" class=\"topiclink\">Impostazioni<\/a>.<\/p>\n\r<div style=\"text-align: left; text-indent: 0; padding: 0 0 0 0; margin: 0 0 10px 0;\"><table class=\"Table_important\" >\n\r<tr class=\"Table_important\">\n\r<td class=\"Table_important\" style=\"width:4px; background-color:#E9A514;\"><br \/>\n\r<\/td>\n\r<td class=\"Table_important\" style=\"width:20px;\"><p class=\"p_Normal\"><img alt=\"IMPORTANTE\" title=\"IMPORTANTE\" width=\"20\" height=\"20\" style=\"margin:2px 0 0 0;width:20px;height:20px;border:none\" src=\".\/images\/important.svg\"\/><\/p>\n\r<\/td>\n\r<td class=\"Table_important\"><p class=\"p_Normal\" style=\"text-indent: 0; padding-left: 13px; margin-left: 0;\"><span class=\"f_Normal\" style=\"font-family: Arial,\'Lucida Sans Unicode\',\'Lucida Grande\',\'Lucida Sans\';display:inline-block;width:13px;margin-left:-13px\">&#8226;<\/span>Assicurati di aprire le porte API nel firewall locale.<\/p>\n\r<p class=\"p_Normal\" style=\"text-indent: 0; padding-left: 13px; margin-left: 0;\"><span class=\"f_Normal\" style=\"font-family: Arial,\'Lucida Sans Unicode\',\'Lucida Grande\',\'Lucida Sans\';display:inline-block;width:13px;margin-left:-13px\">&#8226;<\/span>Per utilizzare REST API, il certificato del computer per ESET PROTECT Server (utilizzato o meno come certificato di REST Server) deve contenere <span class=\"f_CodeHighlighted\">localhost<\/span> nel campo <span class=\"f_UI\">Nome comune<\/span>\/<span class=\"f_UI\">Host<\/span>. Se il certificato del computer (Server) non soddisfa questo requisito, <a href=\"certificates_certificate_era.html\" class=\"topiclink\">creare un nuovo certificato<\/a> e <a href=\"set_new_era_server_certificate.html\" class=\"topiclink\">modificare il certificato del server<\/a>.<\/p><\/td>\n\r<\/tr>\n\r<\/table>\n\r<\/div>\n\r<p class=\"p_Normal\" style=\"text-indent: 0; padding-left: 20px; margin-left: 0;\"><span class=\"f_Normal\" style=\"display:inline-block;width:20px;margin-left:-20px\">2.<\/span>Assegna agli utenti API il <span class=\"f_UI\">set di autorizzazioni API<\/span><a href=\"admin_ar_permissions_list.html\" class=\"topiclink\">***<\/a>.<\/p>\n\r<div style=\"text-align: left; text-indent: 0; padding: 0 0 0 0; margin: 0 0 10px 0;\"><table class=\"Table_important\" >\n\r<tr class=\"Table_important\">\n\r<td class=\"Table_important\" style=\"width:4px; background-color:#E9A514;\"><br \/>\n\r<\/td>\n\r<td class=\"Table_important\" style=\"width:20px;\"><p class=\"p_Normal\"><img alt=\"IMPORTANTE\" title=\"IMPORTANTE\" width=\"20\" height=\"20\" style=\"margin:2px 0 0 0;width:20px;height:20px;border:none\" src=\".\/images\/important.svg\"\/><\/p>\n\r<\/td>\n\r<td class=\"Table_important\"><p class=\"p_Normal\">L’account Amministratore non può utilizzare le API.<\/p>\n\r<\/td>\n\r<\/tr>\n\r<\/table>\n\r<\/div>\n\r<p class=\"p_Normal\" style=\"text-indent: 0; padding-left: 20px; margin-left: 0;\"><span class=\"f_Normal\" style=\"display:inline-block;width:20px;margin-left:-20px\">3.<\/span>Per automatizzare le interazioni con ESET PROTECT On-Prem API, è possibile utilizzare <a href=\"admin_server_settings.html#api\" class=\"topiclink\">il modulo integrato Swagger UI<\/a> (disponibile a partire da ESET PROTECT On-Prem versione 13.1).<\/p>\n\r<p class=\"p_Normal\" style=\"text-indent: -42px; margin: 0 0 10px 55px;\"><img id=\"toggle0186a1_ICON\" class=\"dropdown-toggle-icon\" alt=\"arrow_down_business\" width=\"21\" height=\"21\" style=\"margin:0;width:21px;height:21px;border:none\" src=\".\/images\/arrow_down_business.svg\"\/> <a id=\"toggle0186a1_LINK\" class=\"dropdown-toggle\" href=\"javascript:void(0)\" data-type=\"dropdown\" data-state=\"0\" data-icon=\"toggle0186a1_ICON\" data-src0=\".\/images\/arrow_down_business.svg\" data-src1=\".\/images\/arrow_up_business.svg\">Cos’è Swagger UI?<\/a><\/p>\n\r<div id=\"toggle0186a1\" class=\"dropdown-toggle-body\" style=\"text-align: left; padding: 0 0 0 0; margin: 0 0 10px 38px;display:none\"><table style=\"border:none; border-spacing:0;\" role=\"presentation\">\n\r<tr>\n\r<td style=\"vertical-align:top; padding:0; border:none\"><p class=\"p_Normal\"><a href=\"https:\/\/swagger.io\/\" target=\"_blank\" onclick=\"return HMTrackTopiclink(this);\" class=\"weblink\">Swagger UI<\/a> è un framework open-source che aiuta gli sviluppatori a progettare, creare, documentare e utilizzare servizi web RESTful. Utilizzando il modulo Swagger UI, è possibile testare le chiamate API tramite una pagina web:<\/p>\n\r<p class=\"p_Normal\" style=\"text-indent: 0; padding-left: 20px; margin-left: 0;\"><span class=\"f_Normal\" style=\"display:inline-block;width:20px;margin-left:-20px\">1.<\/span>Abilitare Swagger UI nelle <a href=\"admin_server_settings.html#api\" class=\"topiclink\">Impostazioni<\/a> di ESET PROTECT Server.<\/p>\n\r<p class=\"p_Normal\" style=\"text-indent: 0; padding-left: 20px; margin-left: 0;\"><span class=\"f_Normal\" style=\"display:inline-block;width:20px;margin-left:-20px\">2.<\/span>Il modulo integrato abilitato Swagger UI è accessibile all’indirizzo <a href=\"https:\/\/localhost:9443\/swagger\" target=\"_blank\" onclick=\"return HMTrackTopiclink(this);\" class=\"weblink\">https:\/\/localhost:9443\/swagger<\/a>. Sostituire <span class=\"f_CodeHighlighted\">localhost<\/span> con il nome del server o l’indirizzo IP, se necessario.<\/p>\n\r<p class=\"p_Normal\">Swagger UI fornisce <a href=\"api.html\" class=\"topiclink\"> chiamate API pronte all’uso complete.<\/a> È sufficiente modificare i valori dei parametri nelle chiamate.<\/p>\n\r<div style=\"text-align: left; text-indent: 0; padding: 0 0 0 0; margin: 0 0 10px 0;\"><table class=\"Table_note\" >\n\r<tr class=\"Table_note\">\n\r<td class=\"Table_note\" style=\"width:4px; background-color:#3DAAE1;\"><br \/>\n\r<\/td>\n\r<td class=\"Table_note\" style=\"width:20px;\"><p class=\"p_Normal\"><img alt=\"Nota\" title=\"Nota\" width=\"20\" height=\"20\" style=\"margin:2px 0 0 0;width:20px;height:20px;border:none\" src=\".\/images\/note.svg\"\/><\/p>\n\r<\/td>\n\r<td class=\"Table_note\"><p class=\"p_Normal\">Swagger UI è disponibile solo in lingua inglese.<\/p>\n\r<\/td>\n\r<\/tr>\n\r<\/table>\n\r<\/div>\n\r<\/td>\n\r<\/tr>\n\r<\/table>\n\r<\/div>\n\r<p class=\"p_Normal\">In alternativa, è possibile implementare le chiamate API nell’applicazione REST Client (ad esempio, <a href=\"https:\/\/www.postman.com\/\" target=\"_blank\" onclick=\"return HMTrackTopiclink(this);\" class=\"weblink\">Postman<\/a>) oppure utilizzare la riga di comando (<a href=\"https:\/\/curl.se\/\" target=\"_blank\" onclick=\"return HMTrackTopiclink(this);\" class=\"weblink\">curl<\/a>).<\/p>\n\r<div style=\"text-align: left; text-indent: 0; padding: 0 0 0 0; margin: 0 0 10px 0;\"><table class=\"Table_note\" >\n\r<tr class=\"Table_note\">\n\r<td class=\"Table_note\" style=\"width:4px; background-color:#3DAAE1;\"><br \/>\n\r<\/td>\n\r<td class=\"Table_note\" style=\"width:20px;\"><p class=\"p_Normal\"><img alt=\"Nota\" title=\"Nota\" width=\"20\" height=\"20\" style=\"margin:2px 0 0 0;width:20px;height:20px;border:none\" src=\".\/images\/note.svg\"\/><\/p>\n\r<\/td>\n\r<td class=\"Table_note\"><p class=\"p_Normal\">REST Server è in esecuzione localmente su ESET PROTECT Server. Non puoi utilizzare ESET Connect con ESET PROTECT On-Prem REST API.<\/p>\n\r<\/td>\n\r<\/tr>\n\r<\/table>\n\r<\/div>\n\r<p class=\"p_Normal\" style=\"text-indent: 0; padding-left: 20px; margin-left: 0;\"><span class=\"f_Normal\" style=\"display:inline-block;width:20px;margin-left:-20px\">4.<\/span>Esegui la richiesta <span class=\"f_CodeHighlighted\"><a href=\"https:\/\/help.eset.com\/getHelp?product=protect_admin&amp;version=13.1&amp;lang=it-IT&amp;topic=api_GetTokens_post\" onclick=\"return HMTrackTopiclink(this);\" class=\"weblink\">GetTokens<\/a><\/span> per effettuare l’autenticazione a REST Server: Nel modulo Swagger UI espandere <span class=\"f_CodeHighlighted\">GetTokens<\/span> &gt; fare clic su <span class=\"f_UI\">Prova<\/span> &gt; fornire i dati corretti nel corpo della richiesta e fare clic su <span class=\"f_UI\">Esegui<\/span>.<\/p>\n\r<div style=\"text-align: left; text-indent: 0; padding: 0 0 0 0; margin: 0 0 10px 0;\"><table class=\"Table_small_no_header\" >\n\r<tr class=\"Table_small_no_header\">\n\r<td class=\"Table_small_no_header\"><p class=\"p_NormalTable\" style=\"page-break-inside: avoid; page-break-after: avoid;\"><span class=\"f_NormalTable\">Metodo<\/span><\/p>\n\r<\/td>\n\r<td class=\"Table_small_no_header\"><p class=\"p_NormalTable\" style=\"page-break-inside: avoid; page-break-after: avoid;\"><span class=\"f_NormalTable\">POST<\/span><\/p>\n\r<\/td>\n\r<\/tr>\n\r<tr class=\"Table_small_no_header\">\n\r<td class=\"Table_small_no_header\" style=\"background-color:#F4F5F4;\"><p class=\"p_NormalTable\" style=\"page-break-inside: avoid; page-break-after: avoid;\"><span class=\"f_NormalTable\">Funzione<\/span><\/p>\n\r<\/td>\n\r<td class=\"Table_small_no_header\" style=\"background-color:#F4F5F4;\"><p class=\"p_NormalTable\" style=\"page-break-inside: avoid; page-break-after: avoid;\"><span class=\"f_NormalTable\">getTokens<\/span><\/p>\n\r<\/td>\n\r<\/tr>\n\r<tr class=\"Table_small_no_header\">\n\r<td class=\"Table_small_no_header\"><p class=\"p_NormalTable\" style=\"page-break-inside: avoid; page-break-after: avoid;\"><span class=\"f_NormalTable\">URL<\/span><\/p>\n\r<\/td>\n\r<td class=\"Table_small_no_header\"><p class=\"p_NormalTable\" style=\"page-break-inside: avoid; page-break-after: avoid;\"><span class=\"f_NormalTable\">https:\/\/protect_server:9443\/GetTokens<\/span><\/p>\n\r<\/td>\n\r<\/tr>\n\r<tr class=\"Table_small_no_header\">\n\r<td class=\"Table_small_no_header\" style=\"background-color:#F4F5F4;\"><p class=\"p_NormalTable\" style=\"page-break-inside: avoid; page-break-after: avoid;\"><span class=\"f_NormalTable\">Corpo<\/span><\/p>\n\r<\/td>\n\r<td class=\"Table_small_no_header\" style=\"background-color:#F4F5F4;\"><p class=\"p_NormalTableCode\" style=\"page-break-inside: avoid; page-break-after: avoid;\"><span class=\"f_NormalTableCode\">{<\/span><\/p>\n\r<p class=\"p_NormalTableCode\" style=\"page-break-inside: avoid; page-break-after: avoid; margin: 0 6px 0 34px;\"><span class=\"f_NormalTableCode\">&quot;username&quot; : &quot;api&quot;,<\/span><\/p>\n\r<p class=\"p_NormalTableCode\" style=\"page-break-inside: avoid; page-break-after: avoid; margin: 0 6px 0 34px;\"><span class=\"f_NormalTableCode\">&quot;password&quot; : &quot;Admin.12345678&quot;,<\/span><\/p>\n\r<p class=\"p_NormalTableCode\" style=\"page-break-inside: avoid; page-break-after: avoid; margin: 0 6px 0 34px;\"><span class=\"f_NormalTableCode\">&quot;grant_type&quot; : &quot;password&quot;<\/span><\/p>\n\r<p class=\"p_NormalTableCode\" style=\"page-break-inside: avoid; page-break-after: avoid;\"><span class=\"f_NormalTableCode\">}<\/span><\/p>\n\r<\/td>\n\r<\/tr>\n\r<\/table>\n\r<\/div>\n\r<p class=\"p_Normal\" style=\"text-indent: 0; padding-left: 20px; margin-left: 0;\"><span class=\"f_Normal\" style=\"display:inline-block;width:20px;margin-left:-20px\">5.<\/span>La risposta restituisce il valore <span class=\"f_CodeHighlighted\">accessToken<\/span>. Successivamente puoi usare <span class=\"f_CodeHighlighted\">accessToken<\/span> in altre richieste API come token di connessione (<span class=\"f_CodeHighlighted\">Authorization: Bearer<\/span>). Nel modulo Swagger UI fare clic su <span class=\"f_UI\">Autorizza<\/span> &gt; incollare <span class=\"f_CodeHighlighted\">accessToken<\/span> &gt; fare clic su <span class=\"f_UI\">Autorizza<\/span>. È possibile eseguire altre chiamate; il modulo Swagger UI include automaticamente il token di autorizzazione in ognuna di esse.<\/p>\n\r<div style=\"text-align: left; text-indent: 0; padding: 0 0 0 0; margin: 0 0 10px 0;\"><table class=\"Table_note\" >\n\r<tr class=\"Table_note\">\n\r<td class=\"Table_note\" style=\"width:4px; background-color:#3DAAE1;\"><br \/>\n\r<\/td>\n\r<td class=\"Table_note\" style=\"width:20px;\"><p class=\"p_Normal\"><img alt=\"Nota\" title=\"Nota\" width=\"20\" height=\"20\" style=\"margin:2px 0 0 0;width:20px;height:20px;border:none\" src=\".\/images\/note.svg\"\/><\/p>\n\r<\/td>\n\r<td class=\"Table_note\"><p class=\"p_Normal\">Vedi anche gli <a href=\"how_api_works.html#examples\" class=\"topiclink\">esempi di chiamate API<\/a> e l’<a href=\"api.html\" class=\"topiclink\">elenco di tutte le chiamate API<\/a> disponibili in ESET PROTECT On-Prem.<\/p>\n\r<\/td>\n\r<\/tr>\n\r<\/table>\n\r<\/div>\n\r"
})
