category

Get a list of categories.

Request format

Note

Pagination available.

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

actionObjectID

To get data for only one category, specify its ID.

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

type

Filter by category type.

Acceptable values:

  • 0: Permanent categories.
  • 1: Temporary categories.

* Required

Response format

<response>
<status>
  <code>{integer}</code>
</status>
<result>
<data>
  <row0>
    <ID>{integer}</ID>
    <name>{string}</name>     
    <type>{integer}</type>
    <timeout>{integer}</timeout>
  </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.

row0

List item with its corresponding number.

ID

Unique ID of the category.

name

Category name.

type

Category type.

Acceptable values:

  • 0: Permanent category.
  • 1: Temporary category.

timeout

Category activity in days.

Sample request and response

Request:

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

Response:

<response>
<status>
  <code>0</code>
</status>
<result>
<data>
  <row0>
    <ID>11419</ID>
    <name>example</name>
    <type>1</type>
    <timeout>23</timeout>
  </row0>
</data>
</result>
</response>

Other actions with the object

See more actions with the category object:

Filter by category type.

Acceptable values:

  • 0: Permanent categories.

  • 1: Temporary categories.

Required

To get data for only one category, specify its ID.

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

Previous