# Equivalent Complete Bots: Helper PHP and Plain PHP

> Two complete text bots with the same behavior and clear prerequisites.

**Category:** Getting Started  
**URL:** https://docs.botlify.cloud/php-bot-recipes  
**Platform:** Botlify Cloud (https://botlify.cloud)  

---

Choose ONE example as your test bot's index.php. Both handle /start, /help and text replies. They use plain text responses, bound the echoed input and ignore other update types. They are small demonstrations, not a production retry/state system.

Both examples need PHP mbstring. The plain PHP example also needs cURL and a configured BOT_TOKEN environment variable. Botlify's hosted runtime supplies that variable; standalone PHP needs its own environment setup. Never paste a real token into shared example code.

## Botlify helper version

Call tg_all_fun before the first helper. The platform resolves the active bot token. No file include is needed.

```php

```

## Plain PHP/cURL version

This uses no tg_* function and no loader. You own the HTTP configuration, TLS checks, JSON encoding, timeout and error handling.

```php

```

## What differs?

The helper version delegates request transport to Botlify; the plain version constructs it locally. The helper may apply shared retry/fallback behavior, while the plain example makes one attempt. Both still depend on Telegram and network latency. Neither version claims guaranteed delivery or a fixed response time.

Deploy in the Botlify test bot editor, check the webhook is active, then send /start, /help and a short message. Review new error.log entries if a reply is missing. Do not replace the platform root entrypoint with either example.

## Add features deliberately

For buttons and callbacks, use the [update/state guide](/bot-update-state-guide). For media, rich messages, custom emoji and effects, use the [complete helper reference](/tg-native-helpers). For scheduling and deployment, use the [operations guide](/bot-operations-guide).
