Filtering is the way the request XML packet indicates the objects to which the operation will be applied. The request XML packets filter add-on plans using a special filter node.
When created, an add-on plan is given a unique ID and a unique name. The
filter node that filters plans is presented by the
DomainAddonTemplateFilterType complex type
domain_addon_template.xsd). This node is structured as follows:
- The name node is required. It specifies the plan name. Data type: string.
- The id node is required. It specifies a unique identifier of a plan. Data type: integer.
- The guid node is required. It specifies a GUID of a plan. Data type: string
- The external-id node is required. It specifies an of a plan in the Panel components (for example, Business Manager). Data type: string
The filter node allows you to specify an add-on plan by each of the nodes within a filter. In addition, it allows you to specify multiple add-on plans within one filter.
<filter> <name>base_plan</name> <name>extra_plan</name> </filter>
<filter> <id>12</id> <id>14</id> </filter>
Finally, the filter can be left empty, which means that all add-on plans are selected:
Another important issue is the ownership of plans. When created by the Administrator, a plan gets to the Administrator’s plan list. When created for a certain reseller, plans are added to the list of this reseller.
When you send a request packet, the system will work with the requester’s plan list. Thus, if you authorized as the Administrator, you’ll get the Administrator’s list. To filter plans that belong to a certain reseller, explicitly identify the reseller in the request packet.
<packet version="22.214.171.124"> <webspace> <get> <filter> <name>base_plan</name> </filter> <owner-login>tecnhnolux</owner-login> </get> </webspace> </packet>