Avito icon

Avito

Взаимодействие с API Авито для бизнеса

Overview

This node integrates with the Avito API to retrieve detailed profile analytics data related to user advertisements ("Объявление"). It is designed to fetch various statistical metrics over a specified time period, grouped by different intervals (day, week, month, totals, or per item). This functionality is useful for users who want to analyze the performance of their ads on Avito, such as tracking views, contacts, conversions, expenses, and other engagement indicators.

Common scenarios include:

  • Monitoring advertisement effectiveness over time.
  • Comparing performance across different ads or categories.
  • Analyzing costs and returns on promotional spending.
  • Evaluating employee or category-specific results.
  • Generating reports for marketing or sales optimization.

Practical example:
A real estate agent could use this node to pull daily statistics on how many times their rental listings were viewed, how many contacts they received, and what the conversion rates are, helping them adjust pricing or promotion strategies accordingly.

Properties

Name Meaning
ID Пользователя The Avito user ID whose profile analytics are being requested.
Дата Начала Периода Start date of the analytics period in YYYY-MM-DD format. Time is ignored. Maximum query depth is 270 days.
Дата Окончания Периода End date of the analytics period in YYYY-MM-DD format. Time is ignored. Maximum query depth is 270 days.
Группировка Данных Type of grouping for the statistical data:
- По Дням (day): daily breakdown
- По Месяцам (month): monthly breakdown
- По Неделям (week): weekly breakdown
- По Общему Значению (totals): total values for the period
- По Объявлениям (item): stats per each advertisement
Показатели Для Анализа Metrics selected for analysis. Multiple can be chosen from categories like Rental requests, Delivery orders, Advertisement stats, Basic stats (views, contacts, conversions), Expenses, and Targeted responses. Examples include:
- views (ad views)
- contacts (number of contacts)
- impressions (search impressions)
- allSpending (total expenses)
- bookingPlacedCount (rental requests placed)
and many more as listed in the property options.
Включить Пагинацию Boolean flag to enable pagination for large datasets. When enabled, multiple requests will be made to retrieve all records, respecting Avito API limits. Applicable only for groupings day, week, month, and item.
Тип Пагинации Pagination type when enabled:
- Получить Все Записи (all): automatically fetch all available records until the end.
- Лимит Запросов (limit): limit the number of pagination requests.
Максимум Запросов Maximum number of pagination requests allowed (to prevent infinite loops). Each request can fetch up to 1000 records with delays. Default is 10 requests (~11 minutes max). Only used if pagination type is "limit".
Лимит Записей Maximum number of records to retrieve in one request (max 1000). For paginated requests, this is the total limit across all requests.
Смещение Offset for pagination, starting point for record retrieval. Minimum 0.
Дополнительные Параметры Collection of additional filtering and sorting options:
- Фильтр По Объявлениям: JSON object to filter by arrays of item IDs, category IDs, and/or employee IDs.
- Сортировка: JSON object specifying metric key and order ("asc" or "desc") for sorting results. Sorting keys must be among the selected metrics.

Examples:
Filter by specific ads: {"itemIds": [1853257996, 2046391027]}
Sort by views descending: {"key": "views", "order": "desc"}
Combined filters and sorts are supported.

Quick reference examples and links to Avito category and employee APIs are provided as notices.

Output

The node outputs an array of JSON objects containing the requested analytics data structured according to the selected grouping and metrics. The exact structure depends on the grouping type:

  • Totals: Aggregated summary statistics for the entire period.
  • Day/Week/Month: Time-series data broken down by the respective interval.
  • Item: Statistics per individual advertisement.

Each output JSON includes the selected metrics as fields with their corresponding values.

No binary data output is indicated for this operation.

Dependencies

  • Requires an API authentication credential for Avito (OAuth2 or similar) configured in n8n.
  • Relies on Avito's public API endpoints for fetching analytics data.
  • The node respects Avito API limitations such as maximum records per request (1000) and rate limits (delays between requests when paginating).

Troubleshooting

  • Common issues:

    • Exceeding the maximum allowed date range (more than 270 days) may cause API errors.
    • Requesting too many records without enabling pagination might result in incomplete data.
    • Incorrectly formatted JSON in filter or sort fields can cause parsing errors.
    • Using unsupported metric keys in sorting will lead to validation errors.
    • Network or authentication failures will prevent data retrieval.
  • Error messages:

    • "Unknown resource": Occurs if the resource parameter is invalid; ensure "item" is selected.
    • API errors related to invalid parameters or exceeding limits will be returned as error messages in the output JSON if "Continue On Fail" is enabled.
    • JSON parse errors for filter/sort fields require correcting the input format.
  • Resolutions:

    • Validate date ranges and formats before running.
    • Use pagination for large datasets.
    • Double-check JSON syntax in advanced fields.
    • Confirm that the API credentials are valid and have necessary permissions.

Links and References

Discussion