Suche in diesem Bereich
Description
You use the ListInquire tasks to retrieve the data for several or all objects of an object type. The returned lists contain less details for the individual objects than the results of single queries.
A list query always consists of 3 elements:
- The Where (XML) or Filters (JSON) object defines search criteria. Details about the Where object for XML and Filters for JSON.
The View object defines the scope of the result. Details of the View object for XML and JSON.
The Order object determines the sorting of the result. Details of the Order object for XML and JSON.
Tasks and routes for list queries
The list queries are executed in XML with the object-specific ListInquire requests and in JSON via the corresponding routes.
These are: (List not yet complete)
XML Task | XML Code | JSON Route | Description |
---|---|---|---|
BackupMX List | 524 | POST /backupMX/_search | Inquires data of BackupMX entries. |
Certificate Job List | 400115 | JobLIst | Inquires data of zone requests. |
Certificate List | 400105 | POST /certificate/_search | Inquires data of certificates. |
ContactList | 304 | POST /contact/_search | Inquires data of domain contacts. |
Domain List | 105 | POST /domain/_search | Inquires data from domains that are in the user's inventory. |
Domain Premium List | 165 | - | Inquires data from premium domains that are in the user's inventory. |
DomainMonitoringList | 155 | - | Inquires data from multiple domain monitorings. |
JobList | - | POST/job/_search | Inquires data from multiple jobs. in XML object-specific job job types, e.g. DomainJobList, ZoneJobList, ContactJobList. |
MailProxyList | 514 | POST /mailProxy/_search | Inquires MailProxy data of multiple domains. |
Redirect List | 504 | POST /redirect/_search | Inquires data of the current redirects. |
SSLContact List | 400205 | POST /sslcontaxt/{id} | Inquires the data of SSL contacts. |
TransferOutList | 106001 | POST /transferout/_search | Inquires data from multiple running outgoing transfers. |
ZoneList | 205 | POST/zone/_search | Inquires zone data of several zones on the name servers managed by the system. |
ZoneHistoryList | 225 | POST /zone/history/_search | Inquires data from multiple zones. |
Examples for simple queries see below.
Query further details
In XML, additional details can be determined with the <key> keyword. For this, a <key> tag must be added below the <task> tag. In the description of the various list queries, the keywords that can be queried with <key> are specified in each case.
<task> <key>created</key> </task>
Similarly, further details in JSON can be queried using query parameters. Depending on the queried object specific parameters can be used. The parameters valid for the respective list query are stored in the JSON Technical Documentation.
POST /domain/_search?keys[]=$key1&keys[]=$key2
Permitted operators for a list query
Value JSON | Value XML | Meaning |
EQUAL | eq | direct comparison (=) |
NOT_EQUAL | ne | is not (!=) |
LIKE | like | Wildcard search “*”, case-sensitive |
GREATER | gt | greater then (>) |
LESS | lt | lower then (<) |
GREATER_EQUAL | ge | greater or equal (>=) |
LESS_EQUAL | le | lower or equal (<=) |
NOT_LIKE | not_like | Wildcard search with "*", is not like, case-sensitive |
ILIKE | ilike | Wildcard search with "*", case-insensitive |
Complex queries
More complex queries are possible using the Where element. Several conditions can be linked with and/or. To link several conditions, e.g. with and, an and tag must be opened below the where tag. Under this tag further and-tags are opened for each condition and the condition is defined below with key, operator and value, like in Example 3 for JSON and for XML The same is valid for pure or operations Example 4 for for JSON and for XML Both operations can be combined.
Examples for complex queries in JSON and XML
Example 1: Simple query with only one condition.
Example 2: Complex query with multiple conditions linked with "And".
Example 3: Complex query with multiple conditions linked with "OR".
JSON Example 4: Complex query with multiple conditions linked with "And" and "OR"
Example 1: Simple query with "where"
Example 2: Query with "where", limiting results with "limit" and sorting with "order"
The list should show the first 30 domains (offset = 0, limit = 30) beginning with "a" (name like a*). Additionally the field created is requested (key = created).
<request> <auth> <user>customer</user> <password>password</password> <context>4</context> </auth> <task> <code>0105</code> <view> <offset>0</offset> <limit>30</limit> <children>1</children> </view> <key>created</key> <where> <key>name</key> <operator>like</operator> <value>a*</value> </where> <order> <key>created</key> <mode>asc</mode> </order> </task> </request>