Data Types

This section consists of Database Things and fields description for every thing which is part of the template.

Introduction

To get to the Data section, click the database icon on the left side tabs in Bubble Editor.

Data Types

Note: In case you have accidentally deleted a data type - no worries! Bubble lets you restore💪the deleted data type. Clicking on 'show deleted types' or 'show deleted fields' from the Data → Data types tab will reveal the deleted items, and a 'restore' button will appear next to each deleted entry. Simply click 'restore', to restore a field or data type.
💡
Tip: Aside from the below-listed data types and fields, Bubble creates these default fields visible in each data type: Creator, Modified Date, Created Date and Slug, except for the User data type. The User data type will have the following fields: email, Modified Date, Created Date and Slug. These fields' values can be used in workflows, conditional formatting, etc. To learn more, see the Bubble manual

Conversation

The conversation datatype stores information about all the conversations (chats). It stores both private or group chats.
It comes with fields listed below:
Field Name
Type
Notes
Avatar_color
text
This data field stores information about the colour of the placeholder avatar. It is used in case user has not added the avatar. By default it is white.
Avatar_Image
image
This data type stores the avatar image of the user's opponent(s) in private or group chats.
Bio
text
This data type stores information about group conversation (chat). Bio can contain 100 symbols.
Favorite
yes / no
This data type specifies whether the conversation was pinned (favorited or added to the top) by the user or no.
Last_message
Message
This data type stores the information about the last message sent within a conversation. we show its preview in a repeating group at the side bar on the left.
Members
List of Users
This data type stores information about all the members of the chat (both private and group).
Messages
List of Messages
This data type stores all the messages within this conversation (chat).
Name_chat_partner
text
This data type stores the name of the chat partner within a private conversation (chat).
Name_creator
text
This data type contains the name of the private chat creator.
Type
Conversation type
This data type specifies whether the conversation (chat) is private or group type.
Note: The data type has a privacy rule applied. See the 💬 in the database under the privacy section for details.

Message

The message datatype contains information about the messages exchanged between the users within a chat.
It comes with fields listed below:
Field Name
Type
Notes
Conversation
Conversation
This field contains information about all the messages within a conversation (chat)
edited?
yes / no
This specifies whether the massage was edited or not (Default value is set to no)
Message_action
text
This field contains information about the user who leaves the group chat
Message_file
file
This data type stores the file sent within the conversation
Message_image
image
This field stores the image sent within the conversation
Message_reply
Message
This field stores the message containing the reply
Message_sticker
image
This field stores the sticker or gif that was sent within the conversation
Message_text
text
This field stores the text of the message(s) exchanged by the users within the conversation
Read
List of Users
This field stores the list of users who have read the certain message.When message is read, it's marked by ✓✓.Group messages are marked as read as soon as one other member sees them
Search_text
text
This field stores the information about all the messages within the conversation. It's used for search within the conversation (chat)

Sticker

The sticker data type is used to store sticker packs related information.
It comes with couple of fields listed below:
Field Name
Type
Notes
Images
image
This field contains image of sticker
Sticker_Pack
Sticker_pack
This specifies the parent sticker pack

Sticker_Pack

The sticker_pack data type stores information about the user's stickers pack.
It comes with fields listed below:
Field Name
Type
Notes
Name
text
This field stores information about stickers pack name.
Private
yes / no
This field needed to add stickers to the user (Default value is set to no)
Search_field
text
This data type stores information about sticker name and is used for stickers search
Stickers
List of Stickers
This field stores information about the list of stickers names.

User

Bubble applications have a built-in User data type that acts like any type that is created in a database. For instance, you can modify a user, delete a user, list them in a repeating group, etc.
It comes with fields listed below:
Field Name
Type
Notes
Avatar
image
This field stores information about the user's avatar
Avatar_color
text
This field stores information about the colour of the placeholder avatar. It is used in case user has not added the avatar. By default it is white
Bio
text
This field contains information about user's bio (text description). it contains 100 symbols max
Conversation
List of Conversations
This field contains information about all user's conversations (both private & group)
Current_conversation
Conversation
This field contains information about the current (last) conversation the user is in
Favorite_conversation
List of Conversations
This data type contains information about conversations pinned by the user.
Favorite_sticker
Sticker_Pack
This field contains information about the sticker used added as a favorite
First_name
text
This field contains the user first name
Gif_sent
List of Search Endpoints Gifs datas
This field contains information about the gif(s) the user has sent
Phone_number
text
This field contains information about the user's phone number
Search_field
text
This field stores the information about all the messages within the conversation. It's used for search within the conversation (chat)
Skin
Skin
Users can set different themes for individual chats. Each theme contains skins that as well customize the appearance of the chat.This field stores information about the current user's chat skin (Default value is set to Gold)
Sticker_packs
List of Sticker_Packs
This field stores information about the stickers user added
Theme
Themes
Users can set different themes for individual chats.This field stores the information about the chat color theme. It's set on the signup and can be changed later by the user
Note: The data type has a privacy rule applied. See the 💬 in the database under the privacy section for details.

Option Sets

💡
Tip: Option sets define a static list of choices for use in dropdowns, pop-ups, etc. Options inside the sets have at least a text display, but they can have additional attributes defined in the Data tab. To learn more, see Bubble Manual.
Below you can find the list of option set attributes and options.

Colors

This option set is used for setting a color for the placeholder avatar in case the user has not added an image as an avatar. It's set on signup.
It does not have any additional fields. It uses a built-in attribute to display the values.
The options for this set are:
Option
Notes
#320E3B
This contains mainly BLUE color
#2B2D42
This contains mainly BLUE color
#B56576
This contains mainly RED color.
#CE84AD
This contains mainly RED color.
#3D2B56
This contains mainly BLUE color.
#EEA243
This contains mainly RED color
#283D3B
This contains mainly Gable Green color

Conversation type

This option set contains information about the types of conversations: private or group type. It does not have any additional fields. It uses a built-in attribute to display the values. The options for this set are:
Option
Notes
private
This attribute is for chat (conversation) containing 2 members
group
This attribute is for chat (conversation) containing more than 2 members

Group Menu

This option set contains chat menu items.
It does not have any additional fields. It uses a built-in attribute to display the values.
The options for this set are:
Option
Notes
Manage group
This item is for managing private or group chat
Delete
This item is for deleting the group conversation (chat) if you created it. If user is not a creator, he can either leave the group or delete all the messages he sent

Packs Menu

This option set is used Gifs & Emojis menu.
It comes with just one field:
Attribute
Type
Notes
icon
text
This is for the Stickers menu icon
The options for this set are:
Option
Notes
Stickers
This contains Stickers menu item
GIF
This contains GIf menu item
Emoji
This contains Emoji menu item
Add_stickers
This contains Add Stickers menu item

Skin

Users can set different themes for individual chats. Each theme contains skins that as well customize the appearance of the chat. This option set contains information on chat skins.
It comes with fields listed below:
Attribute
Type
Notes
action_message_color
text
This is used for action messages colour (when somebody leaves the group)
Color_primary
text
This is a primary colour applied to the text & icons
Hovered
text
This is used for the text colour of the messages on hover
Mess_current_user_bg
text
This is used for the background colour for current user messages
mess_font_color_current_user
text
This is used for text colour of current user messages
The options for this set are:
Option
Notes
Blue
This is used for blue skin
Purple
This is used for purple skin colour
Navy
This is used for navy skin colour
Gold
This is used for gold skin colour

Themes

This options set is used to store themes.
It comes with fields listed below:
Attribute
Type
Notes
Answer_bg
text
This is for background of user's answer
Answer_text_color
text
This is for text colour used in user's answer
Chat_bg
text
This is for chat background colour
Cover
text
Sidebar_bg
text
This is for sidebar background colour
Skin
Skin
This is for default skin colour
The options for this set are:
Option
Notes
Day
This is used for day mode
Night
This is used for night mode

Embedded Notes in Bubble Editor

This template comes with explicit Notes for Database fields, Option sets and their fields, and Privacy rules, which will guide you through the modification process. In order to preview a Note of any data type or field, click on the 💬 icon.
Image without caption