Harvest
Create and list time entries in Harvest.
On this page
Connect
Auth type: API key (secret_text). Paste the API key (or token) from the provider's settings into the connect dialog. It is encrypted at rest and only decrypted on the server when an action runs.
- In the editor: Backend panel, Integrations tab, then Connect. This connects it for the project.
- For every project in a workspace: Workspace settings, Integrations.
- Owners and admins choose which integrations members may connect in the admin panel (Integrations tab), and can attach their own OAuth app there.
Call it from a workflow
Pass the action name and its input. The call resolves with { success, output, error? }; a missing connection resolves with success false and the reason. See ctx.integrations.invoke and ctx.integrations.call.
// .workflow.js (native ctx)
export async function run(ctx) {
const res = await ctx.integrations.invoke("harvest", "get_time_entries", {});
if (!res.success) throw new Error(res.error);
ctx.log.info("Harvest answered", { output: res.output });
}// defineWorkflow module (@app/sdk ctx)
import { defineWorkflow } from "@app/sdk";
export default defineWorkflow({
id: "harvest-get-time-entries",
name: "Harvest: Get Time Entries",
description: "Calls Harvest when a row is created.",
trigger: { type: "entity_event", entity: "tickets", event: "created" },
async run(ctx, event) {
const res = await ctx.integrations.call("harvest", {
"action": "get_time_entries"
}) as { success: boolean; error?: string };
if (!res.success) throw new Error(res.error);
},
});curl -X POST "$APP_ORIGIN/__appbricx/connector-proxy/harvest/get_time_entries" \
-H "Authorization: Bearer $APP_KEY" \
-H "content-type: application/json" \
-d '{"props":{}}'Actions
get_time_entriesin catalog
Get Time Entries. Fetches Time Entries
| Input | Type | Description |
|---|---|---|
fromoptional | text | Only return time entries with an spent_date on or after the given date. (YYYY-MM-DD) |
tooptional | text | Only return time entries with an spent_date on or before the given date. (YYYY-MM-DD) |
user_idoptional | text | Only return time entries belonging to the user with the given ID. |
client_idoptional | text | Only return time entries belonging to the client with the given ID. |
project_idoptional | text | Only return time entries belonging to the project with the given ID. |
task_idoptional | text | Only return time entries belonging to the task with the given ID. |
external_reference_idoptional | text | Only return time entries with the given external reference ID. |
is_billedoptional | text | Pass `true` to only return time entries that have been invoiced and `false` to return time entries that have not been invoiced. |
is_runningoptional | text | Pass `true` to only return running time entries and `false` to return non-running time entries. |
updated_sinceoptional | text | Only return time entries that have been updated since the given date and time. |
pageoptional | text | The page number to use in pagination. |
per_pageoptional | text | The number of records to return per page. (1-2000) |
custom_api_call
Custom API Call. Make a custom API call to a specific endpoint
| Input | Type | Description |
|---|---|---|
urlrequired | object (depends on other props) | url |
methodrequired | one of "GET" | "POST" | "PATCH" | "PUT" | "DELETE" | "HEAD" | Method |
headersrequired | object | Authorization headers are injected automatically from your connection. |
queryParamsrequired | object | Query Parameters |
body_typeoptional | one of "none" | "json" | "form_data" | "raw" | Body Type |
bodyoptional | object (depends on other props) | Body |
response_is_binaryoptional | boolean | Enable for files like PDFs, images, etc. |
failsafeoptional | boolean | No Error on Failure |
timeoutoptional | number | Timeout (in seconds) |
followRedirectsoptional | boolean | Follow redirects |
get_clients
Get Clients. Fetches Clients
| Input | Type | Description |
|---|---|---|
is_activeoptional | text | Pass `true` to only return active clients and `false` to return inactive clients. |
updated_sinceoptional | text | Only return clients that have been updated since the given date and time. |
pageoptional | text | DEPRECATED: The page number to use in pagination. |
per_pageoptional | text | The number of records to return per page. (1-2000) |
get_estimates
Get Estimates. Fetches Estimates
| Input | Type | Description |
|---|---|---|
fromoptional | text | Only return estimates with an issue_date on or after the given date. (YYYY-MM-DD) |
tooptional | text | Only return estimates with an issue_date on or before the given date. (YYYY-MM-DD) |
stateoptional | text | Only return estimates with a state matching the value provided. Options: draft, open, accepted, or declined. |
updated_sinceoptional | text | Only return estimates that have been updated since the given date and time. |
client_idoptional | text | Only return estimates belonging to the client with the given ID. |
pageoptional | text | The page number to use in pagination. |
per_pageoptional | text | The number of records to return per page. (1-2000) |
get_expenses
Get Expenses. Fetches expenses
| Input | Type | Description |
|---|---|---|
fromoptional | text | Only return expenses with an spent_date on or after the given date. (YYYY-MM-DD) |
tooptional | text | Only return expenses with an spent_date on or before the given date. (YYYY-MM-DD) |
user_idoptional | text | Only return expenses belonging to the user with the given ID. |
client_idoptional | text | Only return expenses belonging to the client with the given ID. |
project_idoptional | text | Only return expenses belonging to the project with the given ID. |
is_billedoptional | text | Pass `true` to only return expenses that have been invoiced and `false` to return expenses that have not been invoiced. |
updated_sinceoptional | text | Only return expenses that have been updated since the given date and time. |
pageoptional | text | The page number to use in pagination. |
per_pageoptional | text | The number of records to return per page. (1-2000) |
get_invoices
Get Invoices. Fetches invoices
| Input | Type | Description |
|---|---|---|
fromoptional | text | Only return invoices with an issue_date on or after the given date. (YYYY-MM-DD) |
tooptional | text | Only return invoices with an issue_date on or before the given date. (YYYY-MM-DD) |
stateoptional | text | Only return invoices with a state matching the value provided. Options: draft, open, paid, or closed. |
updated_sinceoptional | text | Only return invoices that have been updated since the given date and time. |
client_idoptional | text | Only return invoices belonging to the client with the given ID. |
project_idoptional | text | Only return invoices belonging to the project with the given ID. |
pageoptional | text | The page number to use in pagination. |
per_pageoptional | text | The number of records to return per page. (1-2000) |
get_projects
Get Projects. Fetches projects
| Input | Type | Description |
|---|---|---|
is_activeoptional | text | Pass `true` to only return active projects and `false` to return inactive projects. |
updated_sinceoptional | text | Only return projects that have been updated since the given date and time. |
client_idoptional | text | Only return invoices belonging to the client with the given ID. |
pageoptional | text | DEPRECATED: The page number to use in pagination. |
per_pageoptional | text | The number of records to return per page. (1-2000) |
get_roles
Get Roles. Fetches Roles
| Input | Type | Description |
|---|---|---|
pageoptional | text | DEPRECATED: The page number to use in pagination. |
per_pageoptional | text | The number of records to return per page. (1-2000) |
get_tasks
Get Tasks. Fetches Tasks
| Input | Type | Description |
|---|---|---|
is_activeoptional | text | Pass `true` to only return active tasks and `false` to return inactive tasks. |
updated_sinceoptional | text | Only return tasks that have been updated since the given date and time. |
pageoptional | text | DEPRECATED: The page number to use in pagination. |
per_pageoptional | text | The number of records to return per page. (1-2000) |
get_users
Get Users. Fetches Users
| Input | Type | Description |
|---|---|---|
is_activeoptional | text | Pass `true` to only return active users and `false` to return inactive users. |
updated_sinceoptional | text | Only return users that have been updated since the given date and time. |
pageoptional | text | DEPRECATED: The page number to use in pagination. |
per_pageoptional | text | The number of records to return per page. (1-2000) |
reports-uninvoiced
Uninvoiced Report. Uninvoiced hours and expenses for all billable projects
| Input | Type | Description |
|---|---|---|
fromrequired | text | Only report on time entries and expenses with a spent_date on or after the given date. (YYYY-MM-DD) |
torequired | text | Only report on time entries and expenses with a spent_date on or before the given date. (YYYY-MM-DD) |
include_fixed_feeoptional | text | Whether or not to include fixed-fee projects in the response. (Default: true) |
pageoptional | text | The page number to use in pagination. |
per_pageoptional | text | The number of records to return per page. (1-2000) |
Details
- Id
harvest- Category
- Project management
- Tags
- time-tracking, invoicing, timesheets
- Package
@activepieces/piece-harvest@0.1.4- Tier
- Community