The Developer Hub

Welcome to the Apperyio developer hub. You'll find comprehensive guides and documentation to help you start working with apperyio as quickly as possible, as well as support if you get stuck. Let's jump right in!



Using collections to organize app data.

A database is organized into a number of collections. The database has two types of collections:

  • Predefined collections - automatically created with every new database
  • Custom collections - any custom collections you create to hold app data


Collection vs. Table

The term collection in database corresponds to the term table in SQL databases.

Predefined collection

Predefined collections are automatically created with every new database. The predefined collections are:

  • Users
  • Files
  • Devices


The Users collection is for storing and managing users in your app. For example, you can provide user registration, user login services in your app.

The collection has the following default columns:

Column nameDescription
_idThe id of the user.
usernameThe username of the user.
passwordThe password of the user.
aclAccess Control List. Permissions for this object (user).
_createdAtDate and time this user was created.
_updatedAtDate and time the user’s data was last updated.


The Files collection is for storing files such as images, PDFs, or text files. The Files collection has the following columns:

Column nameDescription
File NameFile name under which the file is stored in the database. The format is: id.originafilename.ext.
Original File nameThe original file name uploaded to the database.
SizeFile size.
Content-TypeThe file content type. This information is based on the file format.
_createdAtDate and time this file was uploaded.
OwnerDisplayed only when the file was created directly from a POST request. This field has also an Info icon. Upon clicking the icon, a popup appears with information about the file owner.
aclAccess Control List. Permissions for this object


The Devices collection holds registrations from push-enabled apps. The information in this collection allows sending targeted Push Notification messages. The collection has the following columns:

Column nameDescription
_idThe id of this registration object. Auto-generated during device registration in the collection.
deviceIDUnique id of this device. Auto-inserted during device registration.
tokenUnique token from the Push Notifications service. Auto-inserted during device registration.
typeDevice type. A for Android. I for iOS.
channelsOne or more channels for which this device has subscribed. Channels are used to send targeted Push Notification messages.
timeZoneThe time zone in which this device registered.
aclAccess Control List. Permissions for this object .
_createdAtDate and time when device registered.
_updatedAtDate and time when device registered was updated.

Custom collection

If needed, custom database collections can be created.
To do it, under the database Collections tab, click Create new collection, provide a name and confirm the operation.
You are free to define the collection structure (add/delete/edit rows and/or columns).

Security and Permissions

To access a collection you need to provide the database API key (id). You can also add additional security and permissions.

Requiring user login

By default, the Secure collection option is disabled. The data in this collection can be retrieved via REST services, without the need to provide a session token. By turning on the Secure collection option, any action with the collection via REST API services should be done with the provided session token parameter. This means that only logged-in users can access the collection. The session token is added as header parameter: X-Appery-Session-Token.


Login API

Link to login API.

Read/write Permission

In addition to making a collection secure, you can also set whether a collection has read and/or write access.

  • Read access - allows to read data in the collection.
  • Write access - allows data to be inserted or updated in the collection.

For example, to make a collection read-only, turn off the Write permission.


If you have a large number of columns in the database and perform a search on certain columns, an index on those columns can make the search operation a lot faster.

ACL (Access Control List)

ACL (Access Control List) allows to define access (permission) for a particular object in a collection.

The most basic ACL is the following:


This example means that user with id = 573e3bf0975a12724790effc has read and write access to a particular object. No other user will be able to read or write to this object. Only a user who signed in with the Master key will be able to overwrite the ACL.

The most common case is hen the user who is currently logged in creates an object and has read/write permission to this object.

It is also possible to give permission to additional users. For example, this example shows two users have read/write access to an object:


If a user has only read access, then the ACL would look like this:


The ACL can be set in two ways:

  • Default (when the object is created)
  • In runtime


Default ACL means that every time a new object is created the default ACL will be applied to that object. We recommend to use this approach unless you have a special case where you need to determine ACL in runtime.

To set default ACL, click Change default ACL button. A visual ACL editor will open. When you start typing in the input field, you will see the following options:

  • *All users ** - all users will have access to this object.
  • @Creator - the object creator (currently signed in user) will have access to this object.
  • username - if you have any users currently in the Users collection, they will be listed here.

Once you set a default ACL, every new object created will have the default ACL set.

To view or edit an ACL for an object, click on the blue icon in the ACL field. There you can view and edit the current ACL for this object.

In runtime

You can also set the ACL in runtime. This is a more advanced usage. Check the database API to learn how to set ACL in runtime.

Importing Collections

Importing New Collection

You can import a collection if you have a .json or .csv file. To import a collection, click Import a collection, enter the collection name and select the file to be imported. Please see the sample files format below.

    "data": [{
        "_id": "561ffc09e4b0335a64ab4486",
        "Author": "George Orwell",
        "Title": "1984",
        "Year": "1949"
    }, {
        "_id": "561ffc2ee4b0335a64ab4488",
        "Author": "Stephen King",
        "Title": "The Shining",
        "Year": "1977"
    }, {
        "_id": "561ffc53e4b0335a64ab4489",
        "Author": "Antoine de Saint-Exupéry",
        "Title": "The Little Prince",
        "Year": "1943"
    }, {
        "_id": "561ffc84e4b0335a64ab448d",
        "Author": "Mikhail Bulgakov",
        "Title": "The Master and Margarita",
        "Year": "1966"
    }, {
        "_id": "561ffcece4b0335a64ab448e",
        "Author": "Ray Bradbury",
        "Title": "Dandelion Wine",
        "Year": "1957"
    }, {
        "_id": "561ffd11e4b0335a64ab448f",
        "Author": "Jane Austen",
        "Title": "Pride and Prejudice",
        "Year": "1813"
"561ffc09e4b0335a64ab4486","","George Orwell","1984","1949","56fbb69ee4b0f82184d4d3b9"
"561ffc2ee4b0335a64ab4488","","Stephen King","The Shining","1977","56fbb69ee4b0f82184d4d3b9"
"561ffc53e4b0335a64ab4489","","Antoine de Saint-Exupéry","The Little Prince","1943","56fbb69ee4b0f82184d4d3b9"
"561ffc84e4b0335a64ab448d","","Mikhail Bulgakov","The Master and Margarita","1966","56fbb69ee4b0f82184d4d3b9"
"561ffcece4b0335a64ab448e","","Ray Bradbury","Dandelion Wine","1957","56fbb69ee4b0f82184d4d3b9"
"561ffd11e4b0335a64ab448f","","Jane Austen","Pride and Prejudice","1813","56fbb69ee4b0f82184d4d3b9"


Import file format

If you are not sure about the file format, create a sample collection with the data types that you need. Export the collection and use this file as a starting point.

Importing Data Into an Existing Collection

You can also import data into an existing collection. Importing data into the existing collection is supported only for:

  • Users collection
  • Custom collection

Importing Data Into Users Collection

To import data into Users collection, click Import.


Importing users

Please be aware that when you import data into the Users collection, all existing data (users) will be removed.

Importing Data Into Custom Collection

To import data into a custom collection, click Import Data. Then select from one of the following options:

  • Add (rows will be added to the end)
  • Replace (old data will be cleared)

REST API (curl)

The REST API (curl) section displays the curl command to connect to the Database. A curl command is invoked from a command line and can be a good way to test the API. A curl is the most basic way to test an API. If you are not familiar with curl, here is a good resource to learn more.

Select a different tab to see curl command for a different operation.


Here, you can also run where-queries for a quick test. To do this click the toggle right to the Query label, and you’ll see an input field and the Run query button. Clicking the Run query button will execute the GET service to the selected collection (which is opened right now). For testing purposes only, the first 10 records will be displayed. The entered text will be added to a where clause. In other words, you don't need to enter where, just the actual query.

For example, if you have a collection with a name, you can run this query to return all users whose name is Alexa: {"name":"Alexa"}.

The Statistics page displays the number of API requests for your databases by month and by day, stored data amount, and the number of existing versions. Switching to the Reports page allows you to review the reports of your collection usage. Apply filters to receive specific reports.

Updated 2 months ago


Using collections to organize app data.

Suggested Edits are limited on API Reference Pages

You can only suggest edits to Markdown body content, but not to the API spec.