CSV file

Fridgedoor uses a CSV file to generate messages for email and SMS. In Fridgedoor, a csv file is expected to be in a valid format. The first line in the csv file is read as a header and the columns (when separated by comma). The following lines are the data for those columns.

CLI preview

In the above sample CSV file, the first row is a header. The header has fields/columns Name,Company, Mobile Number and Due Date. The second and third rows has the data that are used in conjuction with a template to generate messages.

Associating header to data

Now that we have a csv file with 2 rows of data. If we were to match the header to data, we could easily associate the header with each and every line in the rows as follows.

Name Company Mobile Number Due Date
Bill Gates Microsoft +640211234567 19/04/2019
Name Company Mobile Number Due Date
Tim Cook Apple +640217654321 28/08/2019

You can see the representation of the csv file in a tabular form for every rows in the file.