Skip to main content

KeyCRM with CostCare AI

Connect KeyCRM with CostCare AI to automate lead processing with AI agents and keep your KeyCRM pipeline updated. With this integration, CostCare AI can receive signals from KeyCRM when a lead moves to a specific pipeline stage. This signal starts the AI-agent workflow. If the AI agent needs help from a real manager, CostCare AI can move the lead card in KeyCRM to a dedicated manager stage.
CostCare AI listens to webhook events from KeyCRM and can update the lead card stage in KeyCRM when the AI agent escalates the lead to a manager.

How the integration works

The integration works with KeyCRM pipeline stages and webhook events. There are two main flows:

KeyCRM to CostCare AI

When a lead moves to a specific stage in KeyCRM, KeyCRM sends a webhook signal to CostCare AI. This signal tells the AI agent to start processing the lead.

CostCare AI to KeyCRM

When the AI agent escalates a lead to a real manager, CostCare AI can move the lead card in KeyCRM to a dedicated stage, such as “Manager work”.

Lead processing flow

1

Lead is created or updated in KeyCRM

A lead exists in your KeyCRM pipeline and contains the information your team uses during the sales process.
2

Lead moves to the AI-processing stage

A manager or automation moves the lead to the stage where AI processing should begin.
3

KeyCRM sends a webhook to CostCare AI

KeyCRM sends the lead data and stage-change event to the webhook URL generated in CostCare AI.
4

AI agent starts processing

CostCare AI receives the webhook signal and starts the AI-agent workflow for this lead.
5

AI agent continues or escalates

If the AI agent has enough information, it continues processing the lead according to the configured scenario. If the agent does not have enough information or the conversation requires human support, it can escalate the lead to a real manager.
6

Lead is moved to the manager stage in KeyCRM

During escalation, CostCare AI can move the lead card to a dedicated stage in KeyCRM, for example “Manager work”.
The manager escalation stage must be created in KeyCRM before you configure the AI agent to transfer leads to this stage.

Before you start

Before connecting KeyCRM to CostCare AI, make sure you have:

Access to CostCare AI

You need access to your CostCare AI workspace and the Integrations section.

Access to KeyCRM

You need access to the KeyCRM account where your leads and sales pipelines are managed.

KeyCRM API key

You need a KeyCRM API key to connect your account with CostCare AI.

AI-processing stage

Decide which KeyCRM stage should trigger the AI agent to start processing the lead.

Manager escalation stage

Create a dedicated stage in KeyCRM where leads should be moved when the AI agent escalates them to a real manager.
Before configuring the AI agent, prepare the required stages in your KeyCRM pipeline. For example, your pipeline may include:
  • New lead — the lead has just entered the pipeline.
  • AI processing — the stage that triggers CostCare AI to start the AI-agent workflow.
  • Manager work — the stage where the lead is moved if the AI agent escalates the conversation to a real manager.
  • Qualified — the lead has been successfully qualified.
  • Closed — the lead has been completed or rejected.
You can use your own stage names. The important part is to clearly define which stage starts AI processing and which stage is used for manager escalation.

Connect KeyCRM to CostCare AI

1. Open Integrations in CostCare AI

In your CostCare AI account, go to Integrations. Select KeyCRM from the list of available integrations. Click Connect.
Integration KeyCRM 1 eng

2. Add your KeyCRM API key

Paste your KeyCRM API key into the connection window. Then click Continue.
Integration KeyCRM 2 eng
The API key allows CostCare AI to connect with your KeyCRM account, receive lead data, and update the lead card stage when required by the AI-agent scenario.

3. Copy the webhook URL

After the API key is added, CostCare AI will generate a webhook URL. Copy this webhook URL. You will need to add it to KeyCRM.

4. Add the webhook in KeyCRM

In KeyCRM, create a webhook that triggers when a lead moves to the stage where the AI agent should start processing. Paste the webhook URL copied from CostCare AI into the webhook settings in KeyCRM.
Integration KeyCRM 3 eng
The webhook should be configured for the stage-change event that represents the moment when the lead should be passed to the AI agent.

5. Finish the connection

After adding the webhook in KeyCRM, return to CostCare AI and click Done. Once completed, the integration status will change to Connected.
Integration KeyCRM 4 eng

Configure AI-agent escalation

After the KeyCRM integration is connected, you can configure the AI agent to escalate leads to a real manager. This behavior is configured in the AI-agent prompt. For example, you can instruct the AI agent to escalate the lead when:
  • the customer asks a question the AI agent cannot answer;
  • the AI agent does not have enough information to continue;
  • the customer requests to speak with a real person;
  • the conversation requires manual review;
  • the lead is ready for a manager to continue the sales process.
When escalation happens, CostCare AI can move the lead card in KeyCRM to the stage created for manager work.
Create the manager escalation stage in KeyCRM before adding this behavior to the AI-agent prompt. If the stage does not exist, the lead may not be moved correctly.

Example AI-agent prompt instruction

You can add this instruction to the AI-agent prompt:
If you do not have enough information to answer the customer’s question, or if the customer asks to speak with a real manager, escalate the lead to a human manager.When escalating, transfer the lead to the “Manager work” stage in KeyCRM.
Use the exact name of the stage from your KeyCRM pipeline when describing the escalation rule in the AI-agent prompt.

What happens after connection

After the integration is connected, CostCare AI listens for webhook events from KeyCRM. When a lead moves to the defined AI-processing stage, CostCare AI receives the signal and starts the AI-agent workflow. If the AI agent continues the conversation successfully, the workflow follows the configured scenario. If the AI agent escalates the lead to a manager, CostCare AI updates the lead card in KeyCRM and moves it to the manager escalation stage.
The AI agent will not start processing every new lead automatically. It starts only when the lead moves to the KeyCRM stage configured as the trigger.

What data is sent to CostCare AI

Depending on your KeyCRM setup and webhook configuration, CostCare AI may receive:
  • lead details;
  • contact information;
  • pipeline information;
  • current lead stage;
  • order or request details;
  • custom fields used in your sales process.
The exact data depends on the fields available in KeyCRM and the webhook payload configured in your KeyCRM account.

Important behavior

AI starts from a stage

The AI agent starts processing only after the lead moves to the selected stage in KeyCRM.

CostCare AI listens to webhooks

CostCare AI receives stage-change signals from KeyCRM through webhook events.

Escalation moves the lead

If the AI agent escalates the lead to a real manager, CostCare AI can move the lead card to the manager stage in KeyCRM.

Stage must exist first

The manager escalation stage must be created in KeyCRM before it is used in the AI-agent prompt.

Agent logic is prompt-based

The escalation behavior is described in the AI-agent prompt after the KeyCRM integration is connected.

No separate chat card in KeyCRM

CostCare AI does not create a separate chat card in KeyCRM for this integration.

Test the integration

To check whether the integration works correctly:
1

Create or choose a test lead in KeyCRM

Use an existing lead or create a new test lead in your KeyCRM pipeline.
2

Move the lead to the AI-processing stage

Move the lead to the stage that should start AI processing.
3

Check the webhook event

Make sure the webhook was triggered successfully in KeyCRM.
4

Check CostCare AI

Confirm that the AI agent received the lead data and started processing.
5

Test escalation

Ask a question that should trigger manager escalation, or simulate a case where the AI agent does not have enough information.
6

Check the lead stage in KeyCRM

Confirm that the lead card was moved to the manager escalation stage, such as “Manager work”.

Troubleshooting

If the lead was not passed to CostCare AI or was not moved to the correct stage, check the following:
Make sure the webhook URL in KeyCRM is the same as the URL generated in CostCare AI.
Check whether your KeyCRM API key is active and was copied correctly.
Make sure the webhook is triggered by the correct lead stage-change event.
The AI agent starts only when the lead moves to the stage selected for AI processing.
Create the manager escalation stage in KeyCRM before configuring the AI agent to move leads to this stage.
Make sure the stage name in the AI-agent prompt matches the stage name in KeyCRM.
Add a clear instruction to the AI-agent prompt that explains when the lead should be escalated and which KeyCRM stage should be used.
If your balance is low, agents may not work without interruptions. Top up your balance and try again.

Disconnect KeyCRM

To disconnect KeyCRM from CostCare AI:
1

Open Integrations

Go to Integrations in your CostCare AI account.
2

Select KeyCRM

Open the connected KeyCRM integration.
3

Click Disconnect

Click Disconnect to stop receiving data from KeyCRM.
After disconnecting, CostCare AI will no longer receive webhook events from KeyCRM or update lead stages in KeyCRM.

FAQ

No. CostCare AI does not create a separate chat card in KeyCRM. The integration receives data through a webhook when a lead moves to a specific stage.
The AI agent starts when the lead moves to the KeyCRM stage configured as the trigger for AI processing.
Yes. You can define the stage in your KeyCRM pipeline that should send the signal to CostCare AI.
Yes. If the AI agent escalates the lead to a real manager, CostCare AI can move the lead card to a dedicated manager stage in KeyCRM.
Escalation is configured in the AI-agent prompt after the KeyCRM integration is connected.
Yes. Create the manager escalation stage in KeyCRM first, then add the escalation instruction to the AI-agent prompt.
Check the API key, webhook URL, webhook event settings, selected pipeline stage, and your CostCare AI balance.
Check whether the manager stage exists in KeyCRM, whether its name matches the AI-agent prompt, and whether the escalation rule is clearly described in the prompt.