zone

Get a list of site sections.

Request format

Note

Pagination available.

https://adfox.yandex.com/api/v1
  ? object=account
  & action=list
  & actionObject=zone
  & [actionObjectID=<integer>]
  & [actionObjectID2=<integer>]

actionObjectID

To get data for only one site section, specify its ID.

Default value: 0 (display the list of all site sections).

actionObjectID2

Filter by site ID.

* Required

Response format

<response>
<status>
  <code>{integer}</code>
</status>
<result>
<data>
  <row0>
    <ID>{integer}</ID>
    <name>{string}</name>
    <siteID>{integer}</siteID>
    <siteName>{string}</siteName>
    <categoryID>{integer}</categoryID>
    <categoryName>{string}</categoryName>
    <isAutoReferer>{integer}</isAutoReferer>
    <templateTypeID>{integer}</templateTypeID>
    <dateAdded>{date}</dateAdded>
    <template>
      <template1>{string}</template1>
    </template>
  </row0>
</data>
</result>
</response>

Response parameters

code

Request processing status. If the value is 0, the request was completed successfully. For the key, see Error handling.

rows

Number of items in the response tree.

rowN

Item number in the response tree, where N is a number from 0 to rows-1 (where rows is the total number of items in the response).

ID

Unique ID of the site section.

name

Section name.

siteID

ID of the site where the section is located.

siteName

Name of the site where the section is located.

categoryID

ID of the category assigned to the section.

categoryName

Name of the category assigned to the section.

isAutoReferer

Dynamic definition of a site by referer.

templateTypeID

Referer template type.

dateAdded

Add date.

template

List of templates.

templateN

String with the referer template, where N is the string number.

Sample request and response

Request:

https://adfox.yandex.com/api/v1?object=account&action=list&actionObject=zone

Response:

<response>
<status>
  <code>0</code>
</status>
<result>
<data>
  <row0>
    <ID>60119</ID>
    <name>section 1</name>
    <siteID>27185</siteID>
    <siteName>site</siteName>
    <categoryID>0</categoryID>
    <categoryName/>
    <isAutoReferer>1</isAutoReferer>
    <templateTypeID>0</templateTypeID>
    <dateAdded>2021-11-27</dateAdded>
    <template>
      <template1>*</template1>
    </template>
  </row0>
</data>
</result>
</response>

Other actions with the object

See more actions with the zone object:

Previous