Closed arkanoid17 closed 3 weeks ago
To resolve the issue of not getting the list of applications in the magic link, follow these steps:
Check Database Entries: Ensure that the project_connectors
table has entries for the given id_project
(acb1a3a8-f868-42c4-9040-68db6be5057f
). The error indicates that no connectors are found for the project.
Service Method: Verify the getConnectorsByProjectId
method in project-connectors.service.ts
to ensure it correctly queries the database:
async getConnectorsByProjectId(id_project: string) {
try {
const project = await this.prisma.projects.findFirst({
where: { id_project },
});
if (!project) {
throw new NotFoundException('Project does not exist!');
}
const res = await this.prisma.project_connectors.findFirst({
where: { id_project: id_project },
});
if (!res) {
throw new NotFoundException('Connectors not found for current project!');
}
return res;
} catch (error) {
handleServiceError(error, this.logger);
}
}
getConnectorsFromProject
method in project-connectors.controller.ts
correctly calls the service method:@Get()
async getConnectorsFromProject(@Query('projectId') id: string) {
return await this.projectConnectorsService.getConnectorsByProjectId(id);
}
useProjectConnectors
hook in useProjectConnectors.tsx
to ensure it correctly fetches data from the API:const useProjectConnectors = (id: string) => {
return useQuery({
queryKey: ['project-connectors', id],
queryFn: async (): Promise<any> => {
const response = await fetch(`${config.API_URL}/project-connectors?projectId=${id}`);
if (!response.ok) {
throw new Error('Network response was not ok');
}
return response.json();
}
});
};
export default useProjectConnectors;
Ensure that the API URL is correct and the project ID is being passed correctly.
/packages/api/src/@core/project-connectors/project-connectors.service.ts /packages/api/src/@core/project-connectors/project-connectors.controller.ts /apps/magic-link/src/hooks/queries/useProjectConnectors.tsx /apps/magic-link/src/hooks/queries /packages/api/src/@core/project-connectors
Hi, I have been trying to create a magic link to create a CRM integration but after the link is generated no applications are showing up as can bee seen in the screenshot below.
Also I keep getting this issue in the terminal saying
err: { api-1 | "type": "NotFoundException", api-1 | "message": "Connectors not found for current project!", api-1 | "stack": api-1 | NotFoundException: Connectors not found for current project! api-1 | at ProjectConnectorsService.getConnectorsByProjectId (/app/packages/api/dist/src/@core/project-connectors/project-connectors.service.js:91:23) api-1 | at async ProjectConnectorsController.getConnectorsFromProject (/app/packages/api/dist/src/@core/project-connectors/project-connectors.controller.js:39:16) api-1 | "response": { api-1 | "type": "Object", api-1 | "message": "Connectors not found for current project!", api-1 | "stack": api-1 | api-1 | "error": "Not Found", api-1 | "statusCode": 404 api-1 | }, api-1 | "status": 404, api-1 | "options": {}, api-1 | "name": "NotFoundException" api-1 | } api-1 | Req data is: { api-1 | id_user: '5de5e7f2-aee8-4114-b7e3-a1dc5e67e87a', api-1 | email: 'arkaprabha.mahata@adjoint.in', api-1 | first_name: 'Arkaprabha', api-1 | last_name: 'Mahata', api-1 | id_project: 'acb1a3a8-f868-42c4-9040-68db6be5057f' api-1 | }
It would be very helpful if you can resolve this quickly. Thnak you again
I just merged a PR
Hi, I have been trying to create a magic link to create a CRM integration but after the link is generated no applications are showing up as can bee seen in the screenshot below.
Also I keep getting this issue in the terminal saying
err: { api-1 | "type": "NotFoundException", api-1 | "message": "Connectors not found for current project!", api-1 | "stack": api-1 | NotFoundException: Connectors not found for current project! api-1 | at ProjectConnectorsService.getConnectorsByProjectId (/app/packages/api/dist/src/@core/project-connectors/project-connectors.service.js:91:23) api-1 | at async ProjectConnectorsController.getConnectorsFromProject (/app/packages/api/dist/src/@core/project-connectors/project-connectors.controller.js:39:16) api-1 | "response": { api-1 | "type": "Object", api-1 | "message": "Connectors not found for current project!", api-1 | "stack": api-1 | api-1 | "error": "Not Found", api-1 | "statusCode": 404 api-1 | }, api-1 | "status": 404, api-1 | "options": {}, api-1 | "name": "NotFoundException" api-1 | } api-1 | Req data is: { api-1 | id_user: '5de5e7f2-aee8-4114-b7e3-a1dc5e67e87a', api-1 | email: 'arkaprabha.mahata@adjoint.in', api-1 | first_name: 'Arkaprabha', api-1 | last_name: 'Mahata', api-1 | id_project: 'acb1a3a8-f868-42c4-9040-68db6be5057f' api-1 | }
It would be very helpful if you can resolve this quickly. Thnak you again
When did you try to do it ? Because I merged a PR fixing this issue 30min ago
Hi, I have been trying to create a magic link to create a CRM integration but after the link is generated no applications are showing up as can bee seen in the screenshot below.
Also I keep getting this issue in the terminal saying
err: { api-1 | "type": "NotFoundException", api-1 | "message": "Connectors not found for current project!", api-1 | "stack": api-1 | NotFoundException: Connectors not found for current project! api-1 | at ProjectConnectorsService.getConnectorsByProjectId (/app/packages/api/dist/src/@core/project-connectors/project-connectors.service.js:91:23) api-1 | at async ProjectConnectorsController.getConnectorsFromProject (/app/packages/api/dist/src/@core/project-connectors/project-connectors.controller.js:39:16) api-1 | "response": { api-1 | "type": "Object", api-1 | "message": "Connectors not found for current project!", api-1 | "stack": api-1 | api-1 | "error": "Not Found", api-1 | "statusCode": 404 api-1 | }, api-1 | "status": 404, api-1 | "options": {}, api-1 | "name": "NotFoundException" api-1 | } api-1 | Req data is: { api-1 | id_user: '5de5e7f2-aee8-4114-b7e3-a1dc5e67e87a', api-1 | email: 'arkaprabha.mahata@adjoint.in', api-1 | first_name: 'Arkaprabha', api-1 | last_name: 'Mahata', api-1 | id_project: 'acb1a3a8-f868-42c4-9040-68db6be5057f' api-1 | }
It would be very helpful if you can resolve this quickly. Thnak you againI just merged a PR
Hi, I have been trying to create a magic link to create a CRM integration but after the link is generated no applications are showing up as can bee seen in the screenshot below.
Also I keep getting this issue in the terminal saying
err: { api-1 | "type": "NotFoundException", api-1 | "message": "Connectors not found for current project!", api-1 | "stack": api-1 | NotFoundException: Connectors not found for current project! api-1 | at ProjectConnectorsService.getConnectorsByProjectId (/app/packages/api/dist/src/@core/project-connectors/project-connectors.service.js:91:23) api-1 | at async ProjectConnectorsController.getConnectorsFromProject (/app/packages/api/dist/src/@core/project-connectors/project-connectors.controller.js:39:16) api-1 | "response": { api-1 | "type": "Object", api-1 | "message": "Connectors not found for current project!", api-1 | "stack": api-1 | api-1 | "error": "Not Found", api-1 | "statusCode": 404 api-1 | }, api-1 | "status": 404, api-1 | "options": {}, api-1 | "name": "NotFoundException" api-1 | } api-1 | Req data is: { api-1 | id_user: '5de5e7f2-aee8-4114-b7e3-a1dc5e67e87a', api-1 | email: 'arkaprabha.mahata@adjoint.in', api-1 | first_name: 'Arkaprabha', api-1 | last_name: 'Mahata', api-1 | id_project: 'acb1a3a8-f868-42c4-9040-68db6be5057f' api-1 | }
It would be very helpful if you can resolve this quickly. Thnak you againWhen did you try to do it? Because I merged a PR fixing this issue 30min ago
Hello @arkanoid17, please use the given credentials for login. The issue will be resolved for these credentials.
Email - local@panora.dev Password - panora123
Check the getConnectorsByProjectId
method in packages/api/src/@core/project-connectors/project-connectors.service.ts
to ensure the project ID is correct. Verify the useProjectConnectors
hooks in apps/magic-link/src/hooks/queries/useProjectConnectors.tsx
, apps/client-ts/src/hooks/get/useProjectConnectors.tsx
, and apps/embedded-catalog/react/src/hooks/queries/useProjectConnectors.tsx
to ensure they are querying the API correctly.
/packages/api/src/@core/project-connectors/project-connectors.service.ts /packages/api/src/@core/project-connectors/project-connectors.controller.ts /apps/magic-link/src/hooks/queries/useProjectConnectors.tsx /apps/client-ts/src/hooks/get/useProjectConnectors.tsx /apps/embedded-catalog/react/src/hooks/queries/useProjectConnectors.tsx /apps/magic-link/src/hooks/queries /packages/api/src/@core/project-connectors
Fixed with the new PR merged
Hi, I have been trying to create a magic link to create a CRM integration but after the link is generated no applications are showing up as can bee seen in the screenshot below.
Also I keep getting this issue in the terminal saying
err: { api-1 | "type": "NotFoundException", api-1 | "message": "Connectors not found for current project!", api-1 | "stack": api-1 | NotFoundException: Connectors not found for current project! api-1 | at ProjectConnectorsService.getConnectorsByProjectId (/app/packages/api/dist/src/@core/project-connectors/project-connectors.service.js:91:23) api-1 | at async ProjectConnectorsController.getConnectorsFromProject (/app/packages/api/dist/src/@core/project-connectors/project-connectors.controller.js:39:16) api-1 | "response": { api-1 | "type": "Object", api-1 | "message": "Connectors not found for current project!", api-1 | "stack": api-1 | api-1 | "error": "Not Found", api-1 | "statusCode": 404 api-1 | }, api-1 | "status": 404, api-1 | "options": {}, api-1 | "name": "NotFoundException" api-1 | } api-1 | Req data is: { api-1 | id_user: '5de5e7f2-aee8-4114-b7e3-a1dc5e67e87a', api-1 | email: 'arkaprabha.mahata@adjoint.in', api-1 | first_name: 'Arkaprabha', api-1 | last_name: 'Mahata', api-1 | id_project: 'acb1a3a8-f868-42c4-9040-68db6be5057f' api-1 | }
It would be very helpful if you can resolve this quickly. Thnak you again