Skip to main content

Query ConnectWise Tickets

The Query ConnectWise Tickets action searches for service tickets in ConnectWise Manage. This is a low-level API action that makes a single API call, returning tickets that match your query conditions.

Single API Call Action

This is a single API call action. You define the query conditions and the action makes one API call to retrieve the results. Learn more about the difference between workflow actions and single API call actions.

When to Use This Action​

Use this action when:

  • You need to find tickets matching specific criteria
  • You want to check if a ticket exists before creating one
  • You need ticket data for decision-making in your workflow
  • You're building custom search or reporting logic

For updating existing tickets from emails, consider using the Update ConnectWise Ticket workflow action instead, which handles ticket lookup and note creation together.

Configuration​

Connection​

FieldDescription
ConnectWise ConnectionOptionally select a connection override. Leave blank to use your default ConnectWise connection, or your oldest available connection if you have not designated a default.

Create a ConnectWise connection before running this action. If you select a connection that is no longer available, the action fails instead of switching to another connection.

Query Conditions​

Use the query builder to create filter conditions. Common fields include:

Ticket Info:

  • ID, Summary, Record Type, Closed Flag

Classification:

  • Board ID/Name, Status ID/Name, Type ID/Name, Sub-Type, Item, Priority, Source

Company & Contact:

  • Company ID/Identifier/Name, Contact ID/Name, Site ID/Name

Assignment:

  • Team ID/Name, Owner ID/Name

Dates:

  • Date Entered, Date Closed, Due Date, Required Date, Last Updated

Metrics:

  • Budget Hours, Actual Hours, Severity, Impact

Child Conditions​

Filter by fields in related entities (one-to-many relationships). Conditions apply to the same child record.

Pagination​

FieldDescription
Page SizeNumber of results per page (1-1000). Default: 25.
PagePage number to retrieve. Default: 1.
Return all resultsWhen enabled, returns an array of all matching tickets. When disabled, returns only the first ticket.

Error Handling​

FieldDescription
If no results are returnedSelect what the workflow should do when the requested page contains no tickets. Default: Continue.
If more than one result is returnedSelect what the workflow should do when the requested page contains more than one ticket. Default: Continue.
Error HandlingAction to take if the query fails (Exception, Continue, Stop, Stop All).

The action counts tickets on the requested page before applying the output settings. These result-count options apply whether Return all results is enabled or disabled.

Each selector shows only the choices available in the current workflow context. Choices can include Continue processing, Stop current rule, Stop all rules, Generate an exception and stop processing, Bounce email to sender for email workflows, and Exit macro for macros.

Returned Variables​

When you configure Store the results in Variable:

When "Return all results" is disabled: Returns a single ticket object.

When "Return all results" is enabled: Returns an array of ticket objects.

Ticket Object Properties​

PropertyTypeDescription
idnumberTicket ID
summarystringTicket summary/title
boardobjectService board (id, name)
statusobjectCurrent status (id, name)
companyobjectAssociated company (id, identifier, name)
contactobjectAssociated contact (id, name)
siteobjectSite information
priorityobjectPriority level (id, name)
typeobjectService type (id, name)
subTypeobjectService sub-type
itemobjectService item
sourceobjectTicket source
teamobjectAssigned team
ownerobjectTicket owner/assignee
severitystringSeverity level
impactstringImpact level
budgetHoursnumberBudgeted hours
actualHoursnumberActual hours logged
dateEnteredstringCreation timestamp
closedDatestringClosure timestamp (if closed)
closedFlagbooleanWhether ticket is closed
customFieldsarrayCustom field values

Example Use Cases​

Find Ticket by Number​

Look up a specific ticket:

SettingValue
Conditionid equals {{custom.ticketNumber}}
Return all resultsDisabled

Find Open Tickets for Company​

Get all active tickets:

SettingValue
Conditionscompany/id equals {{custom.company.id}} AND closedFlag equals false
Return all resultsEnabled
SortdateEntered (Descending)

Find High Priority Tickets​

Get escalated tickets:

SettingValue
Conditionspriority/name equals "Priority 1 - Critical" AND closedFlag equals false
Return all resultsEnabled

Check for Duplicate Tickets​

Before creating a ticket, check if one exists:

SettingValue
Conditionssummary contains {{email.subject}} AND company/id equals {{custom.company.id}} AND closedFlag equals false
Return all resultsDisabled

FAQs​

How do I access nested properties?​

Use dot notation in your conditions: company/id, status/name, board/id.

What's the maximum number of results?​

ConnectWise API returns up to 1000 results per page. Use pagination for larger datasets.

How do I filter by custom fields?​

Custom fields are available in the query builder. Reference them by their field name.

Can I sort results?​

Yes. Configure the sort field and direction in the query builder.