Skip to main content

Create a Record

This guide provides step-by-step instructions on how to create a record in the Layer4 web app.

You can also create records via the public API:

POST/api/v1/buckets/{bucketId}/records

Before creating a record, ensure you are signed in and that you have already created a bucket to "Store data on-chain". See create a bucket for more information.

Create a Record in the app

  1. Select your bucket: Begin by selecting the Bucket in the left sidebar for which you want to create a record. IMPORTANT: The bucket has to be a Data Storage bucket.

    Bucket selector on the dashboard

  2. Create a Record: Click the "Create a record” button on the Bucket Dashboard screen, indicated by a "+" icon on the Records card.

    Create a record card

  3. Enter Record Details: Fill in the appropriate fields for the record. The only mandatory field is the Data field. A brief overview of the other available fields:

  • Segment: A segment is a way to group records within a bucket. It can be used to categorize your records.

  • Files: You can attach one or more files to your record. Files can be referenced by their URI and/or content hash (CID) within the Data field.

  • Content Type: The content type of the data you are storing. Normally, this is plain text (text/plain), but could be JSON (application/json), SVG (image/svg+xml), etc.

  • Encrypt: Switch this on if you want to encrypt the data before storing it on-chain. This will encrypt the data using an encryption key specific to the bucket. Read more about encrypted records here.

    Create Record Modal

  1. Submit: Take note of the credits that will be used by the record. Once you're happy with the record details, click on the "Create" button to request the addition of this record to the blockchain. .

Troubleshooting

If you encounter any issues while trying to create a record, consider the following solutions:

  • Record Not Created: If you don't see the record you just created, double-check that you've saved it correctly. Ensure that you've followed all the steps and provided the required information.

If you continue to experience problems or have any questions about the record creation process, please contact our support team at [email protected] for further assistance.

Congratulations! You've successfully learned how to create a record. If you have any further questions or need assistance, feel free to reach out to our support team.

Enjoy using Layer4!