Skip to content

Open-source manufacturing ERP, MES and QMS. Quoting, MRP, inventory, shop floor, quality and lot/serial traceability on one Postgres schema, with a REST API and MCP server. Self-host or use Carbon Cloud.

fix: update linear search api

Sidwebworks20038ed12026
diff --git a/packages/ee/src/linear/lib/client.ts b/packages/ee/src/linear/lib/client.ts
index c7ee7baf46..4052547bf1 100644
--- a/packages/ee/src/linear/lib/client.ts
+++ b/packages/ee/src/linear/lib/client.ts
@@ -70,24 +70,22 @@ export class LinearClient {
async listIssues(companyId: string, input: string) {
try {
- const query = `query SearchIssues($filter: IssueFilter!) { issues( filter: $filter first: 5 orderBy: updatedAt ) { nodes { id identifier title description state { name type color } url assignee { email } } } }`;
+ const query = `query SearchIssues($term : String!) { searchIssues(term: $term, first: 5, orderBy: updatedAt) { nodes { id identifier title description state { name type color } url assignee { email } } } }`;
const response = await this.instance.request<{
- data: { issues: { nodes: LinearIssue[] } };
+ data: { searchIssues: { nodes: LinearIssue[] } };
}>({
method: "POST",
headers: await this.getAuthHeaders(companyId),
data: {
query,
variables: {
- filter: {
- title: { containsIgnoreCase: input },
- },
+ term: input,
},
},
});
- return response.data.data.issues.nodes.map((el) => el);
+ return response.data.data.searchIssues.nodes.map((el) => el);
} catch (error) {
console.error("Error listing Linear issues:", error);
return [];