We have with timrLink an executable program with which tasks can be imported from a csv/Excel file.
1. Structure of csv file
The file encoding must be UTF-8 in both cases.
1.1. tasks import from csv file
The csv file must have the following structure:
Task;Bookable;Billable;Internal Remarks;Start;End
Example:
> CustomerA
> Project1
TaskA1
TaskA2
The file then contains...
Customer A|Project1|TaskA1;true;true;;;
Customer A|Project1|TaskA2;true;true;;;
Details:
The Tasks TaskA1 and TaskA2 are created with Billable=True. Furthermore, based on this import file, only TaskA1 and A2 will be created with Bookable=true.
Note: Under 3.1 you will find further possibilities to import e.g. fixed subtasks or customer specific fields.
1.2 Project times import from csv file
The csv file for the import of project times requires the following structure:
User;Task;StartDateTime;EndDateTime;Break;Notes;Billable
User references a user via the reference stored in timr as "ExternalID" (see 2.3).
Task references a timr task by name and structure.
Example:
User;Task;StartDateTime;EndDateTime;Break;Notes;Billable
John1;Customer A|Project1|TaskA1;01.12.15 8:00;01.12.15 16:30;0:30;;false
In timr a user must be entered as ExternalID=John1. The project time will be imported for this user. If no user with ExternalID=John1 exists, the project time will not be imported.
The project time is posted in timr to the following task:
Customer A
Project 1
TaskA1
Attention: If the task does not exist in timr it will be created.
2. Use timrLink:
2.1 download timrLink
You can download the current version of timrLink for different platforms (Windows, Mac, Linux):
https://github.com/troii/timrlink.net/releases.
2.2 After the download you have to unpack the zip file.
2.3 Create Sync Token:
The import of the tasks from timrLink is done via the timrAPI. For this you need an access token for your account. You can generate this token in timr under Administration/Settings/General/API:
Attention: do not share this token, it allows access to all data in your account!
Here you can also show an "External ID". This allows you, for example, to store an ID for a user with which this user is managed in your system, e.g. employee number.
As soon as you select "Show external ID" = Yes, an additional field "External ID" is displayed in the user properties (and also tasks):
2.4 Customize timrLink configuration file:
In the timrLink directory unzipped in 2.2. you will find the configuration file config.json with the following content:
{
"timrSync": {
"identifier": "<identifier>",
"token":"<authentication token>"
}
}
For the <identifier>, use your timr URL. For the token, use the API token you created in 2.3.
Example:
You own the account samplecompany.timr.com:
{
"timrSync": {
"identifier": "samplecompany",
"token": "abce123332abc"
}
}
2.5 Execute import
You can now execute the timrlink file in the unpacked directory as follows:
2.5.1 Import tasks:
timrlink t <file>
2.5.2 Project times import:
timrlink pt <file>
3. Further information
3.1 Extended structure for tasks csv file
During the import it is also possible to import customer specific fields for the tasks. To do this, use the following import format:
Task;Bookable;Billable;Description;Start;End;CustomField1;CustomField2;CustomField3.
Example:
Customer A|Project1|Task1;True;False;Awesome;;Field1;Field2;Field3
Customer A|Project1;True;True;;;;;;
Customer A|Project2;false;true;;2019-05-16;;;;
It is also possible to import fixed subtasks during import. This is useful if you want to read customers from a CRM and then simply create a fixed task list under each customer:
Task;Bookable;Billable;Description;Start;End;Subtasks.
Example:
Customer A;True;False;Awesome;;;Support,Sales.
Customer B;True;True;;;;Support,Sales
Customer C;false;true;;2019-05-16;;Development,Testing
This creates e.g:
CustomerA
Support
Sales
...
Comments
0 comments
Article is closed for comments.