FluxyAPIFluxyAPI
StorageVariables

Array Variables

What are arrays and how to use them.

In this guide, we'll show you how to use arrays.

Introduction

Before we begin, make sure you have:

What Is an Array

Arrays are extremely useful and show up in many places. We use them in several programming languages, like Python and JavaScript.

Think of an array like a list, imagine a row of boxes:

  • Each box holds one thing.
  • Each box is in order.
  • Each box can be grabbed by its number.

An example in real life is something like a shopping list, on this shopping list you might have:

  • Milk
  • Bananas
  • Apples

Each of these items is one value in the array. Each item is indexed so it's easy to refer to later: the first item is [0], the second is [1], then [2], and so on. So shopping_list[0] would be "Milk".

How to Create an Array

Navigate to the correct project by clicking it in the top left corner of the dashboard.

Now that you're on the correct project, click the "Storage" tab in the sidebar.

Click "New Variable" in the top right of the storage page.

In the first box that appears, give your variable a name. Make this descriptive, not like my_var but something like shopping_list!

Select "array" under the type options.

If you would like, you can add items that will be there from the beginning under the "Initial Value" option. Simply click "Add Item" and type in the value of the item.

Click "Create Variable" and you're done. You've now successfully made an array in your FluxyAPI project!

Summary & Notes

You've now created an array successfully on your FluxyAPI dashboard!

Limitations

You are limited to 1MB of data per array.

To use variables in endpoints, see our Using Variables guide.

If you've got any questions or encounter any issues, feel free to join our Discord server, and we'll try to fix any issues you may face!

On this page