https://linen.dev logo
Getting Missing Fields Error with GoogleAds Tool O...
# 🖥│support-forum
l
Hello, I've been trying to initiaiting a connection to the GoogleAds tool but after repeatedly trying I was unable to do it. I think there are some issues with trying passing in the required
generic_id
and
generic_token
. My current implementation:
Copy code
connRequest = await withTimeout(composio.connectedAccounts.initiate(userId, authConfigId, customParams));
The customParams is a simple Record object with keys matching the configuration:
Copy code
{
  "generic_token": "actual_developer_token_value",
  "generic_id": "1234567890"
}
The request ID is a5fb454a-35cb-4137-b8d5-5f8f1b31ae6d.
c
Hi Luke, We looked into the issue on our end and it appears to be a minor type Issue. In the meantime, you can use the following snippet as a workaround:
Copy code
ts
import { Composio } from '@composio/core';

const composio = new Composio({ apiKey: '<compsosio-api-key>' });

const connectionRequest = await composio.connectedAccounts.initiate(
  '<user-id>',
  'ac_xxxxx',
  {
    config: {
      authScheme: 'OAUTH2',
      // @ts-ignore
      val: {
        generic_token: '<developer-token>',
        generic_id: '<customer-id>',
      }
    }
  }
);

console.log(connectionRequest.redirectUrl);
Also, please ensure you're using the latest version of the [Composio](https://www.npmjs.com/package/@composio/core/v/0.1.37) SDK. Let us know if you run into anything else!
2 Views