Variables
Think of variables as the placeholders or building blocks of your logic. They store values (like numbers, text, or JSON objects) that can be reused throughout your Function Stack.
Variables let you dynamically pass and manipulate data—whether that’s a user’s ID, a timestamp, or a calculated total.
You’ll encounter variables everywhere in Xano, from inputs in APIs to outputs in database queries. They’re the key to making your logic flexible and adaptable to real-world scenarios.
Functions
Functions are the tools that do the heavy lifting in your backend. They perform specific actions, like querying your database, calling an external API, or applying transformations to your data.
Functions are pre-built by Xano to handle common tasks, making it easy to create complex logic without starting from scratch.
Think of them as the "verbs" in your backend—they’re what make things happen.
Custom Functions
When the built-in functions don’t quite fit your needs, Custom Functions let you take things a step further. These are reusable logic blocks you can create and tailor to your application’s specific requirements.
Custom Functions allow you to centralize and simplify your workflows. Instead of writing the same logic multiple times, you can build it once and call it wherever it’s needed. This makes your backend cleaner, more efficient, and easier to maintain.
Scopes
Scopes define where your logic applies and how it interacts with the rest of your backend. In Xano, scopes are like the boundaries or contexts in which your variables and functions operate.
For example, a variable defined in one scope might only be available within that specific function or logic block, while others may apply globally. Understanding scopes is essential for managing complexity and avoiding conflicts as your application grows.
Each of these terms plays a critical role in building powerful and dynamic backends in Xano. By mastering Variables, Functions, Custom Functions, and Scopes, you’ll be able to create logic that’s both efficient and easy to maintain. Ready to dive deeper? Explore our documentation for more insights!