Clockify

Clockify is a time tracking service that lets you track teams activity and work hours across projects.

Data integration: Skyvia supports importing data to and from Clockify, exporting Clockify data to CSV files, and replicating Clockify data to relational databases.

Backup: Skyvia Backup does not support Clockify.

Query: Skyvia Query supports Clockify.

Establishing Connection

To create a connection to Clockify, specify the API Key.

Getting Credentials

API Key

To locate the API key, do the following.

  1. Go to Clockify.
  2. Click the user icon and choose Preferences.
  3. Switch to the Advanced tab and click Generate.

    clockify-api-menu

  4. Click Generate again and copy the API key.

    clockify-apikey

The API key is available only once when you generate it. Store it in a safe place to access it later. If you generate a new API key instead of an old one, the old API key becomes invalid.

Creating Connection

To connect to Clockify, enter the obtained API key into the API Key box in the connection editor.

clockify-connection

Additional Connection Parameters

Suppress Extended Requests

Clockify API returns only part of the fields for some objects when querying multiple records. Skyvia performs additional extended requests to query values of missing fields. Skyvia performs such API requests for each record of such an object. However, this can decrease performance and significantly increase the number of API calls used.

The additional fields are the following:

OBJECT FIELD
Invoices BillFrom, ClientAddress, CompanyId, ContainsImportedExpenses, ContainsImportedTimes, Discount, DiscountAmount, Items, Note, Subject, Subtotal, Tax, Tax2, Tax2Amount, TaxAmount, UserId, VisibleZeroFields
Expenses File

You can select the Suppress Extended Requests checkbox to reduce the number of API calls.

Customized Workspace Objects

Use this parameter to enable custom fields specific for each workspace.

Connector Specifics

Object Peculiarities

Assignments

When you query this object, the result includes data from 01.01.2024 00:00:00 to the current moment by default. To query data for another period, use filters by the Start and End fields. If you filter by the Start field only, query will return data from the Start data till now. If you filter by the End field only, query will return data from 01.01.2024 00:00:00 till the date specified in the filter.

Holidays

To insert records to this object, map the UserGroupIds or UserIds in array format. If you mapped the UserIds, also map the UserContains and UserStatus fields. If you mapped the UserGroupIds, also map the UserGroupContains and UserGroupStatus fields.

There are valid values for the fields to consider when importing data to this object:

Object Operation Value
UserContains, UserGroupContains INSERT Contains, Does_Not_Contain
UserContains, UserGroupContains UPDATE Contains, Does_Not_Contain, Contains_Only
UserStatus, UserGroupStatus INSERT ALL, ACTIVE, INACTIVE
UserStatus, UserGroupStatus UPDATE ALL, ACTIVE, INACTIVE, PENDING, DECLINED

Policies

You can get only records with an active status when querying this object. To get the archived records, use filter by the Status field. Set Status = ARCHIVED, to get the archived records, set Status = ALL to get all existing records. When you query specific recods using filter by the Id, you can get only active records. If you query the archived record by its Id, the query will return no records.

The INSERT operation requires mapping the UserGroupIds or UserIds fields in array format, for example ["66963721c855372fa3918cc0"]. If you mapped the UserIds, also map the UserContains and UserStatus fields. If you mapped the UserGroupIds, also map the UserGroupContains and UserGroupStatus fields.

There are valid values for the fields to consider when importing data to this object:

Object Operation Value
UserContains, UserGroupContains INSERT Contains, Does_Not_Contain
UserContains, UserGroupContains UPDATE Contains, Does_Not_Contain, Contains_Only
UserStatus, UserGroupStatus INSERT ALL, ACTIVE, INACTIVE
UserStatus, UserGroupStatus UPDATE ALL, ACTIVE, INACTIVE, PENDING, DECLINED

TotalCapacityForUser

The TotalhoursPerDay field stores complex structured data in JSON format. You can use our Nested Objects mapping feature in the Import integrations to insert or update the nested values in such fields. Select the Separate Tables for the Unwind Nested Objects option when using the new replication runtime to replicate the nested data into separate tables.

When you query this object, the result includes data from 01.01.2024 00:00:00 to the current moment by default. To query data for another period, use filters by the Start and End fields. If you filter by the Start field only, query will return data from the Start data till now. If you filter by the End field only, query will return data from 01.01.2024 00:00:00 till the date specified in the filter.

Custom Fields

Custom fields are available for the Projects, Users, TimeEntryForUsers, and TimeEntryInProgress. Clockify supports the following custom field types:

Clockify DbType
Text String
Number Double
Link String
Switch Boolean
Select String
Select Multiple String

Every Clockify workspace may have separate set of custom fields. If you have custom fields, Skyvia adds an additional object with Clockify workspace name as a prefix. For example, there are Text and Checkbox fields in the Projects object in Client Workspace. Skyvia creates the additional Client Workspace Projects object which repeats the Projects object content also containing the Text and Checkbox custom fields.

The Projects custom fields are read-only. If you use them in the Returning operation, Skyvia performs additional API call to get their values due to Clockify API specifics.

The Users custom fields are read-only.

Incremental Replication and Synchronization

Skyvia doesn’t support Replication with Incremental Updates and Synchronization for the Clockify objects. They don’t have the CreatedDate and UpdatedDate fields.

DML Operations Support

Clockify objects support the following operations.

Operation Object
INSERT, UPDATE, DELETE Clients, ExpenseCategories, Expenses, Holidays, Invoices, Policies, Projects, <WorkspaceName>Projects, Tags, Tasks, TimeEntryForUsers, <Workspace Name> TimeEntryForUsers, TimeEntryInProgress, <Workspace Name>TimeEntryInProgress, UserGroups
INSERT, DELETE Policies
INSERT Assignments, Payments, Users, Workspaces
UPDATE MemberProfile

Stored Procedures

Skyvia represents part of the supported Clockify features as stored procedures. You can call a stored procedure, for example, as a text of the command in the ExecuteCommand action in a Target component of a Data Flow or in Query.

UpdateWorkspaceCostRate

To update the workspace cost rate, use the command:

call UpdateWorkspaceCostRate(:workspaceId,:amount,:since)

PARAMETER NAME DESCRIPTION
WorkspaceId Workspace identifier across the system
Amount Integer cost rate amount
Since Date and time in yyyy-MM-ddThh:mm:ssZ format

UpdateWorkspaceBillableRate

To update the workspace billable rate, use the command:

call UpdateWorkspaceBillableRate(:workspaceId,:amount,:currency,:since)

PARAMETER NAME DESCRIPTION
WorkspaceId Workspace identifier across the system
Amount Integer cost rate amount
Currency Currency code. Default value is USD
Since Date and time in yyyy-MM-ddThh:mm:ssZ format

ArchiveExpenseCategory

To archive the expense category, use the command:

call ArchiveExpenseCategory(:workspaceId,:categoryId,:archived)

PARAMETER NAME DESCRIPTION
WorkspaceId Workspace identifier across the system
CategoryId Category identifier across the system
Archived True or False flag whether to archive the expense category or not

AddUserToGroup

To add a specific user to a group, use the following command.

call AddUserToGroup(:workspaceId,:userGroupId,:userId)

RemoveUserFromGroup

To remove a specific user from the group, use the command:

call RemoveUserFromGroup(:workspaceId,:userGroupId,:userId)

Supported Actions

Skyvia supports all the common actions for Clockify.