The Bitrix24 workflow designer has a "PHP code" action that runs arbitrary code inside a process. It's available only in the self-hosted edition — cloud Bitrix24 has no such action on any plan. Yet the typical tasks PHP gets added to a process for — a call to an external API, parsing the response, extracting data from text, a compound condition — can all be assembled in the cloud from ready-made robots. Let's map out where the line runs and what replaces each scenario.

Where is the "PHP code" action available, and why isn't it in the cloud?

"PHP code" is a self-hosted-edition action: you write arbitrary code inside a template that runs on the portal's server with access to the core API. In the cloud the portal runs on Bitrix24's shared infrastructure, and executing user code there is locked down — an architectural limitation, not a matter of plan or some hidden setting. So forum advice along the lines of "paste this PHP into a business process" applies only to the self-hosted edition. If you look at what the code in such templates actually does, it's almost always one of four things: reach out to an external system, parse its response, pull a fragment out of a string, decide based on several conditions. Each cluster is covered in the cloud by its own robot — one per scenario below.

How do I reach an external API without PHP?

The HTTP request GET/POST robot makes a request right from the business process: the GET, POST, PUT, PATCH, DELETE and HEAD methods, an arbitrary body, headers in JSON — Authorization for a token, for example — and a timeout from 1 to 60 seconds. It returns the response body, the HTTP status code and a success flag of Y/N (a 2xx code). Redirects are checked at every hop, requests to internal network addresses are blocked, and the response body is capped at 1 MB; the robot is available on paid Bitrix24 plans. That's enough for integrations at the level of "push deal data into the accounting system and pull back the order status". Receiving data the other way, from outside into the portal, goes through webhooks.

How do I parse an API response without json_decode?

An external system's response is almost always JSON, and in self-hosted PHP the next thing was a couple of lines with json_decode. In the cloud the Extract value from JSON by path robot does the same: it takes a JSON string and a dot-separated path — data.user.email, items.0.name — and returns the value as a string, objects and arrays as JSON for further parsing, plus a "Path found" flag (Y/N). If the JSON is invalid or the path doesn't exist, the robot returns N — and the process routes the error to a separate branch instead of writing an empty value into a deal field. The "HTTP request → extract value → write to field" chain covers most integration scenarios that used to require code.

How do I extract data from text without preg_match?

The second PHP-in-processes classic is regular expressions: pull an order number out of an email subject, find links in a comment, check a SKU format. The Extract by regular expression robot applies a pattern to the source string: the pattern is specified without delimiters, Cyrillic and Unicode are handled correctly, and a capture-group number lets you return not the whole match but a specific part — the value inside parentheses, for instance. It returns the first match, a list of all matches, and a "Found" flag (Y/N). A typical case: a lead is created from an email titled "Order ORD-12345: question about delivery" — the pattern ORD-\d+ pulls out the number, and the process finds the related deal.

How do I replace an if with several conditions?

The designer's built-in "Condition" compares values, but a combination of three or four checks turns a template into a ladder of nested branches — exactly what the self-hosted edition hid in three lines of code. The Compound condition (AND / OR / NOT) robot assembles the check into a single step: up to four "value — operator — value" triples with AND or OR logic; the operators include equality, numeric comparison, contains and is_empty. For arbitrary nesting there's a JSON mode with and, or and not groups. The output is a single Y/N flag the process branches on with an ordinary condition — the logic reads in the designer, not in code that only its author understood.

When can't you do without the self-hosted edition?

The honest line: robots cover integration and logic scenarios, but not everything. If the code has to work with the server's file system, core events or your own modules — that's the self-hosted edition and a developer. But if PHP was needed for "request, parse, decide", a cloud portal covers it with a chain of two to four robots that any administrator can read and adjust. Start with an inventory: which steps of your current procedures hit the lack of code — and assemble them from ready-made actions, as described in the business process overview.

Conclusion

"PHP code" is self-hosted only; the cloud doesn't execute arbitrary code. The per-scenario replacements: an API call — "HTTP request GET/POST", parsing the response — "Extract value from JSON by path", text — "Extract by regular expression", compound checks — "Compound condition". All four are in the Roboteka catalog: free install from the Bitrix24.Market, and they work in both the cloud and the self-hosted edition. Missing the action you need? Describe the task and we'll build the robot for free.