openapi: 3.2.0 info: title: Karbonhq Work Items API version: v3 contact: name: API Support url: https://developers.karbonhq.com/issues/ license: name: Apache 2.0 url: http://www.apache.org/licenses/LICENSE-2.0.html termsOfService: https://karbonhq.com/terms-of-use/ description: 'Operations tagged Work Items across 2 of this provider''s published API definitions: KarbonAPI.json, karbonhq-openapi.yml. Each path carries the servers of the definition it was published in.' servers: - url: https://api.karbonhq.com description: The production API server security: - ApiKeyAuth: [] BearerAuth: [] tags: - name: Work Items description: Manage a Work Item to best fit your workflow, including timelines, tasks and work teams. Read more paths: /v3/WorkItems: get: tags: - Work Items summary: Gets a list of Work Items parameters: - in: query name: $filter schema: type: string examples: AssigneeEmailAddress: value: AssigneeEmailAddress eq 'karbon@example.com' summary: Returns only the Work Items where the Assignee Email is 'karbonhq@example.com' ClientKey: value: ClientKey eq '2nvhdM1TmZk3' summary: Returns only the Work Items where the unqiue key of the Client Group, Contact, Organization or User is '2nvhdM1TmZk3' PrimaryStatus: value: PrimaryStatus eq 'In Progress' summary: Returns only the Work Items where the Work Primary Status is 'In Progress', a complete list of Primary Status values can be retrieved the TenantSettings endpoint StartDate: value: StartDate ge 2024-01-01 summary: Return only the Work Items where the Start Date is on or after January 1, 2024 Title: value: contains(ContactType, 'Client') summary: Return only the WorkItems which have a Title that contains the word 'Tax' WorkScheduleKey: value: WorkScheduleKey eq 'FXcWYY9xZfd' summary: Return only the Work Items that are part of the Work Schedule with the unique key 'FXcWYY9xZfd' WorkTemplateKey: value: WorkTemplateKey eq '2vBsCfGk9hJD' summary: Return only the Work Items that were created from the Work Template with the unique key '2vBsCfGk9hJD' WorkStatus: value: WorkStatus eq 'InProgress' summary: Return only the Work Items with the Work Status 'In progress' WorkType: value: WorkType eq 'Payroll' summary: Return only the Work Items with the Work Type 'Payroll' description: 'When this parameter is combined with the URI, this endpoint will return a subset of the Work Items that satisfy the `$filter` expression. ' - in: query name: $orderby schema: type: string enum: - StartDate - StartDate desc - DeadlineDate - DeadlineDate desc default: WorkItemKey example: StartDate description: 'When this parameter is combined with the URI, this endpoint will return a list of Work Items, sorted by the available properties. Using the `desc` variant will return items in most to least recent order. ' - $ref: '#/components/parameters/SkipRecords' - $ref: '#/components/parameters/TopRecords' description: 'Use the `GET` method on this endpoint to receive a paginated list of Work Items from your tenant. Using the query parameters available to this endpoint, you can also filter the list of Work Items by their AssigneeEmailAddress, ClientKey, PrimaryStatus, StartDate, Title, WorkScheduleKey, WorkStatus, WorkTemplateKey, and WorkType. **Notes** * This endpoint returns a maximum of 100 Work Items at once. * If the query results in more than 100 Work Items, a link to the next set of the results will be given in the `@odata.nextLink` field of the response. * The `$filter` query parameter supports multiple logical operators and 7 properties to help you form an expression. They are listed below with examples of usage. ### $filter operators for StartDate property OperatorsPurposeStartDate geGreater than and equals/v3/WorkItems?$filter=StartDate ge 2021-04-27T00:00:00Z leLesser than and equals/v3/WorkItems?$filter=StartDate le 2021-04-27T00:00:00Z andCombines properties/v3/WorkItems?$filter=StartDate ge 2021-04-27T00:00:00Z and PrimaryStatus eq ''Planned'' ### $filter operators for rest of the properties Propertyeq [For full-text search]and [For combined-property search]contains [For partial-text search] AssigneeEmailAddress/v3/WorkItems?$filter=AssigneeEmailAddress eq ''joe@samplecompany.com''/v3/WorkItems?$filter=AssigneeEmailAddress eq ''joe@samplecompany.com'' and PrimaryStatus eq ''Planned''/v3/WorkItems?$filter=(contains(AssigneeEmailAddress , ''joe'')) ClientKey/v3/WorkItems?$filter=ClientKey eq ''2nvhdM1TmZk3''/v3/WorkItems?$filter=ClientKey eq ''2nvhdM1TmZk3'' and contains(AssigneeEmailAddress , ''joe'')N/A PrimaryStatus/v3/WorkItems?$filter=PrimaryStatus eq ''Planned''/v3/WorkItems?$filter=AssigneeEmailAddress eq ''joe@samplecompany.com'' and PrimaryStatus eq ''Planned''N/A Title/v3/WorkItems?$filter=Title eq ''Payroll 31 Aug - 15 Sep 2022''/v3/WorkItems?$filter=Title eq ''Payroll 31 Aug - 15 Sep 2022'' and PrimaryStatus eq ''Planned''/v3/WorkItems?$filter=(contains(Title, ''pay'')) WorkScheduleKey/v3/WorkItems?$filter=WorkScheduleKey eq ''FXcWYY9xZfd''/v3/WorkItems?$filter=WorkScheduleKey eq ''FXcWYY9xZfd'' and PrimaryStatus eq ''Planned''N/A WorkStatus/v3/WorkItems?$filter=WorkStatus eq ''Ready To Start''/v3/WorkItems?$filter=WorkStatus eq ''Ready To Start'' and (contains(Title, ''Pay''))/v3/WorkItems?$filter=(contains(WorkStatus , ''joe'')) WorkType/v3/WorkItems?$filter=WorkType eq ''Payroll''/v3/WorkItems?$filter=WorkType eq ''Payroll'' and PrimaryStatus eq ''Planned''/v3/WorkItems?$filter=(contains(WorkType , ''pay''))' operationId: getAllWorkItems responses: '200': description: Successful operation content: application/json: schema: $ref: '#/components/schemas/GetWorkItems' '400': description: Bad Request content: application/json: schema: $ref: '#/components/schemas/ErrorMessages' examples: Unsupported Property: $ref: '#/components/examples/Unsupported_Property_Filter' Unsupported Orderby Property: $ref: '#/components/examples/Orderby_Unsupported_Property' $top limit exceeded: $ref: '#/components/examples/Limit_Exceeded_Top' Unsupported Option: $ref: '#/components/examples/Unsupported_option' '401': description: Unauthorized content: application/json: schema: $ref: '#/components/schemas/ResourceNotFound' examples: Unauthorized Access: $ref: '#/components/examples/UnauthorizedAccess' '429': description: Rate Limit Exceeded content: application/json: schema: $ref: '#/components/schemas/RateLimitErrorMessage' '500': description: Internal Server Error content: application/json: schema: $ref: '#/components/schemas/ErrorMessages' examples: Undefined Error: $ref: '#/components/examples/elongated_5001' post: tags: - Work Items summary: Creates a new Work Item description: Use the `POST` method on this endpoint to create a new Work Item in your tenant. operationId: createWorkItem responses: '201': description: Created content: application/json: schema: allOf: - type: object properties: '@odata.context': type: string description: The information about Karbon controllers generating this response. example: https://api.karbonhq.com/v3/$metadata#WorkItems/KarbonService.WorkItemDTO/$entity '@odata.type': type: string description: The information about Karbon Objects generating this response. example: '#KarbonService.WorkItemDTO' - $ref: '#/components/schemas/WorkItemWithFeeSettings' - type: object properties: Description: type: string description: A free form text field to add more information about the Work Item example: Send to Jo for review ClientTaskRecipient: type: string description: The details about the recipient of the Client Tasks related to this Work Item. This property will always return `null`. example: null headers: Location: description: The endpoint URL to the newly created Work Item. schema: type: string example: https://api.karbonhq.com/v3/WorkItems('2VfHzHkJZPVV')/KarbonService.WorkItemDTO '400': description: Bad Request content: application/json: schema: oneOf: - $ref: '#/components/schemas/EnhancedErrorMessages' - $ref: '#/components/schemas/ErrorMessages' examples: Client Not a member of ClientGroup: $ref: '#/components/examples/Bad_Model_WorkItem_Client_Not_a_member_of_ClientGroup' Incorrect Assignee Email Address: $ref: '#/components/examples/Bad_Model_WorkItem_Incorrect_EmailAddress' Incorrect Client Key: $ref: '#/components/examples/Bad_Model_WorkItem_Incorrect_ClientKey' Incorrect Client Type: $ref: '#/components/examples/Bad_Model_WorkItem_Incorrect_ClientType' Incorrect Work Template Key: $ref: '#/components/examples/Bad_Model_WorkItem_Incorrect_WorkTemplate_Key' Incorrect Work Type: $ref: '#/components/examples/Bad_Model_WorkItem_Incorrect_WorkType' Missing Create Data: $ref: '#/components/examples/Missing_Create_Data' Required Property is empty: $ref: '#/components/examples/Bad_Model_WorkItem_Empty_Property' '401': description: Unauthorized content: application/json: schema: $ref: '#/components/schemas/ResourceNotFound' examples: Unauthorized Access: $ref: '#/components/examples/UnauthorizedAccess' '429': description: Rate Limit Exceeded content: application/json: schema: $ref: '#/components/schemas/RateLimitErrorMessage' '500': description: Internal Server Error content: application/json: schema: $ref: '#/components/schemas/ErrorMessages' examples: Undefined Error: $ref: '#/components/examples/elongated_5001' requestBody: description: Refer to the table below for more information on each field in the request body. required: true content: application/json: schema: $ref: '#/components/schemas/RequestCreateWorkItem' servers: - url: https://api.karbonhq.com description: The production API server /v3/WorkItems/{WorkItemKey}: get: tags: - Work Items summary: Gets a Work Item using WorkItemKey parameters: - required: true in: path name: WorkItemKey schema: type: string example: 2LPSrkzbYrn4 description: The Karbon-generated Work Item key description: Use the `GET` method on this endpoint to receive the details of a Work Item specified using the WorkItemKey. operationId: getWorkItemByID responses: '200': description: Successful operation content: application/json: schema: allOf: - type: object properties: '@odata.context': type: string description: The information about Karbon controllers generating this response. example: https://api.karbonhq.com/v3/$metadata#WorkItems/KarbonService.WorkItemDTO/$entity '@odata.type': type: string description: The information about Karbon Objects generating this response. example: '#KarbonService.WorkItemDTO' - $ref: '#/components/schemas/WorkItemWithFeeSettingsAndUserRoleAssignments' - type: object properties: Description: type: string description: A free form text field to add more information about the Work Item example: Send to Jo for review ClientTaskRecipient: type: string description: The details about the recipient of the Client Tasks related to this Work Item. This property will always return `null`. example: null '400': description: Bad Request content: application/json: schema: $ref: '#/components/schemas/ErrorMessages' examples: Unsupported Option: $ref: '#/components/examples/Unsupported_option' '401': description: Unauthorized content: application/json: schema: $ref: '#/components/schemas/ResourceNotFound' examples: Unauthorized Access: $ref: '#/components/examples/UnauthorizedAccess' '404': description: Not Found content: application/json: schema: $ref: '#/components/schemas/ErrorMessages' examples: Key Not Found: $ref: '#/components/examples/WorkItem_Key_Not_Found_404' '429': description: Rate Limit Exceeded content: application/json: schema: $ref: '#/components/schemas/RateLimitErrorMessage' '500': description: Internal Server Error content: application/json: schema: $ref: '#/components/schemas/ErrorMessages' examples: Undefined Error: $ref: '#/components/examples/elongated_5001' put: tags: - Work Items summary: Updates a Work Item (Full) parameters: - required: true in: path name: WorkItemKey schema: type: string example: 2LPSrkzbYrn4 description: The Karbon-generated Work Item key description: Use the `PUT` method on this endpoint to update full details of a Work Item (specified using the WorkItemKey). operationId: putWorkItemByID responses: '204': description: No Content '400': description: Bad Request content: application/json: schema: oneOf: - $ref: '#/components/schemas/EnhancedErrorMessages' - $ref: '#/components/schemas/ErrorMessages' examples: Client Not a member of ClientGroup: $ref: '#/components/examples/Bad_Model_WorkItem_Client_Not_a_member_of_ClientGroup' Incorrect Assignee Email Address: $ref: '#/components/examples/Bad_Model_WorkItem_Incorrect_EmailAddress' Incorrect Client Key: $ref: '#/components/examples/Bad_Model_WorkItem_Incorrect_ClientKey' Incorrect Client Type: $ref: '#/components/examples/Bad_Model_WorkItem_Incorrect_ClientType' Incorrect Work Template Key: $ref: '#/components/examples/Bad_Model_WorkItem_Incorrect_WorkTemplate_Key' Incorrect Work Type: $ref: '#/components/examples/Bad_Model_WorkItem_Incorrect_WorkType' Missing Create Data: $ref: '#/components/examples/Missing_Create_Data' Required Property is empty: $ref: '#/components/examples/Bad_Model_WorkItem_Empty_Property' Incorrect or Missing Data: $ref: '#/components/examples/Missing_Update_Data' Unsupported Option: $ref: '#/components/examples/Unsupported_option' '401': description: Unauthorized content: application/json: schema: $ref: '#/components/schemas/ResourceNotFound' examples: Unauthorized Access: $ref: '#/components/examples/UnauthorizedAccess' '404': description: Resource Not Found content: application/json: schema: $ref: '#/components/schemas/ErrorMessages' examples: Work Item Key Not Found: $ref: '#/components/examples/WorkItem_Key_Not_Found_404' '429': description: Rate Limit Exceeded content: application/json: schema: $ref: '#/components/schemas/RateLimitErrorMessage' '500': description: Internal Server Error content: application/json: schema: $ref: '#/components/schemas/ErrorMessages' examples: Undefined Error: $ref: '#/components/examples/elongated_5001' '409': description: Conflict — the resource was modified by another request. Refetch the latest version and retry. content: application/json: schema: $ref: '#/components/schemas/ErrorMessages' examples: Stale Object State: $ref: '#/components/examples/Conflict_StaleObjectState' requestBody: description: Refer to the table below for more information on each field in the request body. required: true content: application/json: schema: $ref: '#/components/schemas/RequestCreateWorkItem' patch: tags: - Work Items summary: Updates a Work Item (Partial) parameters: - in: path name: WorkItemKey schema: type: string required: true example: 2LPSrkzbYrn4 description: The Karbon-generated Work Item key description: 'Use the `PATCH` method on this endpoint to update partial details of a Work Item (specified using the WorkItemKey). This method supports editing the `Title`, `Description`, `StartDate`, `DueDate`, `DeadlineDate`, `AssigneeEmailAddress`, `WorkType`, and `UserRoleAssignments` properties. Sending any other property in the request body returns a `400`. `UserRoleAssignments` replaces the full set of role assignments on the Work Item. Reassigning a role also moves any time estimates on that role to the new user.' operationId: patchWorkItemByID responses: '204': description: No Content content: {} '400': description: Bad Request content: application/json: schema: $ref: '#/components/schemas/ErrorMessages' examples: Incorrect or Missing Data: $ref: '#/components/examples/Missing_Update_Data' Unsupported Option: $ref: '#/components/examples/Unsupported_option' Invalid Property: $ref: '#/components/examples/Invalid_Property' '401': description: Unauthorized content: application/json: schema: $ref: '#/components/schemas/ResourceNotFound' examples: Unauthorized Access: $ref: '#/components/examples/UnauthorizedAccess' '404': description: Resource Not Found content: application/json: schema: $ref: '#/components/schemas/ResourceNotFound' examples: Work Item Key Not Found: $ref: '#/components/examples/WorkItem_Key_Not_Found_404' '429': description: Rate Limit Exceeded content: application/json: schema: $ref: '#/components/schemas/RateLimitErrorMessage' '500': description: Internal Server Error content: application/json: schema: $ref: '#/components/schemas/ErrorMessages' examples: Undefined Error: $ref: '#/components/examples/elongated_5001' '409': description: Conflict — the resource was modified by another request. Refetch the latest version and retry. content: application/json: schema: $ref: '#/components/schemas/ErrorMessages' examples: Stale Object State: $ref: '#/components/examples/Conflict_StaleObjectState' requestBody: description: Refer to the table below for more information on each field in the request body. required: true content: application/json: schema: $ref: '#/components/schemas/UpdateWorkItem' servers: - url: https://api.karbonhq.com description: The production API server components: examples: Unsupported_option: description: The error returned when the query option in a request is not allowed for by the API value: error: code: '4002' message: Query option '