API Module Email Templates searchEmailTemplateRequest

From Openprovider API documentation

Jump to: navigation, search

Contents

Module Email Templates > Search

Module Email Templates
Command name searchEmailTemplateRequest
Use Returns a list of email templates matching search criteria
Input
Output
  • id

Examples

Using PHP class

$request = new OP_Request;
$request->setCommand('searchEmailTemplateRequest')
  ->setAuth(array('username' => 'username', 'password' => 'password'))
  ->setArgs([
       'group' => 'ive',
    ]);

Raw XML

Please note that newlines and leading spaces are added only for readability. Those whitespaces should be excluded from your XML command before sending it to Openprovider.

<?xml version="1.0" encoding="UTF-8"?>
<openXML>
  <credentials>
    <username>username</username>
    <password>password</password>
  </credentials>
  <searchEmailTemplateRequest>
    <group>ive</group>
    <limit>1</limit>
    <offset>0</offset>
  </searchEmailTemplateRequest>
</openXML>
<?xml version="1.0" encoding="UTF-8"?>
  <openXML>
    <reply>
      <code>0</code>
      <desc></desc>
      <data>
        <results>
          <array>
            <item>
              <id>733</id>
              <name>Custom Template (en_GB)</name>
              <group>ive</group>
              <isDefault></isDefault>
              <isActive>1</isActive>
              <tags/>
              <fields>
                <array>
                  <item>
                    <name>body</name>
                    <value>Body of the email</value>
                  </item>
                  <item>
                    <name>reminderBody</name>
                    <value>Body of reminder email</value>
                  </item>
                  <item>
                    <name>subject</name>
                    <value>Request for e-mail address verification</value>
                  </item>
                  <item>
                    <name>reminderSubject</name>
                    <value>[REMINDER] Request for e-mail address verification</value>
                  </item>
                  <item>
                    <name>confirmUrl</name>
                    <value>http://icann-verification.registrar.eu/?email=%%email%%&authCode=%%authCode%%</value>
                  </item>
                  <item>
                    <name>resellerName</name>
                    <value>MyCompany</value>
                  </item>
                  <item>
                    <name>senderEmail</name>
                    <value>support@mycompany.net</value>
                  </item>
                </array>
              </fields>
              <locale>
                <array>
                  <item>en_GB</item>
                </array>
              </locale>
            </item>
          </array>
        </results>
        <total>5</total>
      </data>
    </reply>
  </openXML>
Views
Personal tools