Call your flow from other apps
A flow can answer HTTP requests, so the apps of your computer can use it. This page says at which address the app listens.
The address
LessCode listens at http://127.0.0.1:7230. If that port is taken when it starts, it uses the next one that is free, up to 7239.
To see the one in use, open AI → Connect an AI…. It is in MCP endpoint: the number after 127.0.0.1:.
If all those ports are taken, LessCode uses any other, which changes each time it starts. The same window says so.
Make an endpoint
The components Route and Response receive a request and answer it. Create a GET endpoint has an example step by step. In its last part, use the address of the app:
curl 'http://127.0.0.1:7230/api/hello/?name=Jane'You can open the address in your browser too.
On your computer only
The address works on your computer, and not from others of your network: LessCode does not listen there. To offer an endpoint to other people, put the flow on a server with LessCode. Keep and copy your flows says where its file is.
The endpoints of your flow do not ask for a password. Any program on your computer that knows the address can use them, also a web page open in your browser. If an endpoint does something that matters, check in the flow who calls it.
The designer opens only in the window of LessCode, and the MCP endpoint asks for a token.
When it does not answer
- 404: press APPLY first. Then check the method and the address in the settings of Route.
- 503: the flow is paused.
- Nothing answers: LessCode is closed, or it has another port.