> For the complete documentation index, see [llms.txt](https://docs.leadconverter.su/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.leadconverter.su/api-metody/voprosy-po-api/pochemu-ya-skopiroval-primer-no-on-ne-rabotaet.md).

# Почему я скопировал пример но он не работает

Если ты копируешь пример API-метода, но в результате получаешь ошибку - эта статья для тебя :)

Исходя из нашего опыта мы заметили, что чаще всего проблемы возникают из-за следующих причин:

#### Использован некорректный токен

Если вы столкнулись с этой проблемой - в процессе выполнения запроса вы получаете ошибку "404 не существует"

Проверьте, что API-токен вашей кампании существует, и написан правильно. О том, как создать API-токен можно [прочитать здесь](/api-metody/podgotavlivaemsya-k-rabote-s-api.md).

#### Для токена задан секретный ключ, но вы забыли передать его в запросе

Если вы столкнулись с этой проблемой - в процессе выполнения запроса вы получаете ошибку "403 доступ запрещен"

Обратите внимание, что если у токена есть секретный ключ - нужно передавать с каждым запросом к APi параметр `secret=значение_секретного_ключа.` Подробнее о том, что такое секретный ключ, [можно прочитать здесь](/api-metody/podgotavlivaemsya-k-rabote-s-api.md#zachem-nuzhen-sekretnyi-klyuch).

#### Вы не указали один из обязательных параметров

Если вы столкнулись с этой проблемой - вам будет возвращен JSON-ответ формата

```
{
    "status": 422,
    "error": "Описание ошибки",
}
```

Решение, думаю, очевидно. Нужно просто передать обязательные аргументы :)

Если вы проверили, но проблема всё равно осталась - [скорее пишите об этом в поддержку](/kak-zadat-vopros-v-podderzhku.md)! Мы поможем вам :)&#x20;


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.leadconverter.su/api-metody/voprosy-po-api/pochemu-ya-skopiroval-primer-no-on-ne-rabotaet.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
