Skip to content
Verified

Calling Xuda from your own backend

Every connection on this page is also a plain HTTP call, reachable from a server instead of the dashboard.

Nothing in this section has a separate "integrations API". Connecting Gmail, creating a Google Ads client account, renting a phone number, embedding an external app, all of it happens through the same cpi_methods the dashboard itself calls. Once you hold an API key, your own backend can call any of them directly.

The shape, in one call

Every method is POST https://xuda.ai/cpi/<method_name>, a JSON body carrying api_key plus that method's own fields, and a { code, data } response: code > 0 is success, code < 0 is an error with data telling you why. get_account_info needs nothing but the key, so it is the fastest way to confirm a key works before wiring anything real to it:

curl -s https://xuda.ai/cpi/get_account_info \
  -H 'content-type: application/json' \
  -d '{"api_key":"YOUR_API_KEY"}'
const res = await fetch('https://xuda.ai/cpi/get_account_info', {
  method: 'POST',
  headers: { 'content-type': 'application/json' },
  body: JSON.stringify({ api_key: 'YOUR_API_KEY' }),
});
const { code, data } = await res.json();

Where a key comes from, and how a call is shaped

Both of those are already covered in full, and this page does not repeat them:

Reaching an integration from your backend

Every page in this section names its own methods. The starting point for each:

Next