It seems like your browser didn't download the required fonts. Please revise your security settings and try again.

End-of-Sale/Renewals for Models 100 and 200

As of October 4th, 2020, new sales for models 100 and 200 of the Barracuda Email Security Gateway ceased. As of November 30, 2023, renewals for models 100 and 200 of the Barracuda Email Security Gateway have ceased. 

Config.get

  • Last updated on

Use this method to retrieve values of variables in the system configuration.

Parameters Allowed

The following variables are used with the config.get method. These variables should be provided as part of the request XML in the HTTP POST request:

  • variable – A required parameter that tells the API which variable to return.
  • password – A required parameter which the API uses to authenticate access to a page and which is set by your administrator.
  • type – A required parameter that specifies the class/scope of a variable.
  • path – A required parameter that is the qualified name of an object for which the value is required. Note that the value for path is an empty string for getting a variable under global scope.

Example 1: Get the value of a variable under global scope - System Alerts Email Address

Getting the current value of a system variable uses the config.get method. This example gets the value of the System Alerts Email Address variable, typically set from the BASIC > Administration page.

Arguments
  • type: 'global'

  • variable: alerts_email_address

Sample Request
 <?xml version="1.0" encoding="UTF8"?>
  <methodCall>
  <methodName>config.get</methodName>
    <params>   
     <param>
      <value>
        <struct>
         <member>
           <name>variable</name>
           <value><string><![CDATA[scana_subject_tag]]></string>
           </value>
         </member>    
         <member>
          <name>type</name>
           <value>
            <string><![CDATA[global]]></string> 
          </value>
         </member>
         </struct>
        </value>  
       </param>
     </params>    
  </methodCall> 
Response
OK <?XML version="1.0"?>
   <methodResponse>
    <params>
     <param>
      <value>
       <string><![CDATA[Block]]></string> 
       </value>              
      </param>    
      </params>    
  </methodResponse> 

Example 2: Get the value of a variable under global scope - Subject Tag for Spam Messages

Get the value of a variable, scana_subject_tag in this case, under global scope. This example will return the Subject Tag string to be inserted by the Barracuda Email Security Gateway in the subject of a message determined to be spam. This setting is configured from the BASIC > Spam Checking page for the global setting. Note that the path value is an empty string and can be left out, since the scope, or type, is global.

Arguments
  • type: 'global'
  • variable: scana_subject_tag
Sample Request

 

 <?xml version="1.0" encoding="UTF8"?>
  <methodCall>
  <methodName>config.get</methodName>
    <params>   
     <param>
      <value>
        <struct>
         <member>
           <name>variable</name>
           <value><string><![CDATA[scana_subject_tag]]></string>
           </value>
         </member>    
         <member>
          <name>type</name>
           <value>
            <string><![CDATA[global]]></string> 
          </value>
         </member>
         </struct>
        </value>  
       </param>
     </params>    
  </methodCall> 
Response
OK <?XML version="1.0"?>
   <methodResponse>
    <params>
     <param>
      <value>
       <string><![CDATA[Block]]></string> 
       </value>              
      </param>    
      </params>    
  </methodResponse> 

Example 3: Get the value of a per-domain setting  

This example gets the value of the Spam Scoring Limit block level, scana_pd_block_level, for domain thisdomain.net. Since this variable is in per-domain scope, the type is 'domain' and the path argument must specify a value for the domain you're working with. In the configuration, this variable is listed like this:

  • # Domain Spam Block Score
  • scana_pd_block_level = 5
Arguments
  • type: 'domain'
  • path: 'thisdomain.net'
  • variable: 'scana_pd_block_level'
Sample Request
<?XML version="1.0" encoding="UTF8"?>
   <methodCall>
  <methodName>config.get</methodName>
    <params>   
     <param>
      <value>
        <struct>
         <member>
           <name>variable</name>
           <value><string><![CDATA[scana_pd_block_level]]></string>
           </value>
         </member>    
         <member>
          <name>type</name>
           <value>
            <string><![CDATA[domain]]></string> 
          </value>
         </member>
         </struct>
        </value>  
       </param>
     </params>    
  </methodCall> 
Response
OK <?XML version="1.0" encoding="UTF8"?>
   <methodResponse>
    <params>
     <param>
      <value>
       <i4>5</i4> 
       </value>              
      </param>    
      </params>    
  </methodResponse>