#Pipedrive Integration Oauth not imitating/working
1 messages · Page 1 of 1 (latest)
Error details:
at CEG.throwAPIError (.next/server/chunks/51558.js:44395:15)
at CEG.handleAllError (.next/server/chunks/51558.js:44363:35)
at ConnectedAccounts.initiate (.next/server/chunks/51558.js:46021:23)
at async handleInitiateConnection (.next/server/app/(backend)/api/composio-auth/route.js:320:33)
at async responseGenerator (.next/server/app/(backend)/api/composio-auth/route.js:667:38)
at async handleResponse (.next/server/app/(backend)/api/composio-auth/route.js:729:32) {
metadata: [Object],
errCode: 'BACKEND::BAD_REQUEST',
description: 'Validation Errors: undefined',
possibleFix: 'Please check the request parameters and ensure they are correct.',
timestamp: '2025-07-31T16:25:41.824Z',
errorId: '69110ea9-2d99-4f02-a066-f34efd2db1a8'
}```
@latent snow
Hey,
Could you share reproducible code snippet? Also, please specify your SDK version and Imports. Thanks!
Sure,
import { getComposioToolset } from '@/libs/composio';
const composioToolset = getComposioToolset();
const entity = await composioToolset.getEntity(userId);
const connectionReq = await entity.initiateConnection({
config: {
redirectUrl: redirectUri,
},
integrationId: specificIntegrationId,
});
And based on the connectionID and userID, using mcp server http url to connect the user via MCP
Composio version: "composio-core": "^0.5.39",
Hi, based on your SDK version you can try this snippet and lmk if it works for you.
import { ComposioToolSet } from "composio-core";
const composioToolset = new ComposioToolSet({
apiKey: "<API_KEY>",
});
const entity = await composioToolset.getEntity("default");
const connectionReq = await entity.initiateConnection({
config: {
redirectUrl: "<REDIRECT_URL>", //redirect-to-post-auth
},
integrationId: "<uuid>",
});
console.log(connectionReq);
Also, we recommend you to migrate to v3. Let me know if you need help with migration.
Also, regarding appending your connected account ID to your MCP server Url to specify a user, make sure you've converted the connected account from the payload which is in uuid to nanoID.
You can use this endpoint: https://docs.composio.dev/api-reference/migration/get-migration-get-nanoid
Hey, this is the exact setup for me to imitate connections as well.
But this isn't working with Piperdrive and Heygen, there were some others as well.
That being said, almost every other app integrations works perfectly with this, it's only the Piperdrive and Heygen that I have noticed to be not working and throwing that error
Would love any other suggestions or fixes to try, as Pipedrive is a little important for our integration suite.
@latent snow