Connectors

/

HubSpot

/

Adjust a HubSpot deal's line items
Write

Change HubSpot deal line items and see the new total first

For sales reps who need to adjust quantities, prices or discounts on a HubSpot deal, just by asking their AI assistant.

Try PopdockAI free
Get a live demo
Adjust a HubSpot deal's line items
On the Contoso Annual Renewal deal in HubSpot, set Premium Support seats to 40 and give a 10 percent discount on the Analytics add-on.
I matched both changes on Contoso Annual Renewal, current amount 52,000.00. - Premium Support: quantity 30 to 40, net price 18,000.00 to 24,000.00 - Analytics add-on: discount 0 to 10 percent, net price 10,000.00 to 9,000.00 - Expected new total: 57,000.00 Shall I save these changes?
HubSpot
Sample figures. Your results come from your own account.
hubspot-get-deals
hubspot-get-deal-line-items
hubspot-update-deal-line-item
hubspot-add-deal-line-item

On this page

The problem

The problem

The prompt

Who it's for

How it works

Tools used

Connector

HubSpot

HubSpot
Run it on your own HubSpot data.

Connect HubSpot, pick your AI tool and paste the prompt.

Try PopdockAI free

The problem

Deal line item edits leave the wrong line or the wrong total

Changing a quantity, price or discount on a HubSpot deal means finding the right line among several and working out the new total yourself. It is easy to edit the wrong line or miss that the deal amount no longer matches.

Without PopdockAI

  • Open the deal and scroll through its line items
  • Edit quantity, price and discount field by field
  • Work out the new total on the side
  • Notice later that the deal amount no longer matches

With PopdockAI

  • Each change is matched to a line by name or SKU
  • Only quantity, unit price and discount can change
  • You see old and new values and the expected total first
  • Stored values are read back and a mismatched deal amount is flagged

The prompt

Use this prompt

Copy it into any AI tool connected to PopdockAI. Swap the values in braces for your own.

Prompt
**Objective:** Apply `{changes}` to the line items on the deal `{deal-name}`.

**Step 1: Resolve the deal**

Call `hubspot-get-deals` with `deal-name.contains` = `{deal-name}`. If none or several match, list them and stop. Keep its `record-id` and `amount`.

**Step 2: Read the line items**

Call `hubspot-get-deal-line-items` with `deal-id` = the deal's record-id. If there are none, say so and stop.

**Step 3: Map the changes**

Match each change in `{changes}` to a line item by name or SKU. Supported changes: `quantity`, `price` (unit price) and `discount-percentage`. If a change matches no line item or several, ask which and stop.

**Step 4: Confirm**

Show a table per affected line: name, SKU, field, old value, new value, old and new net price. Show the deal's current amount and the expected new total. Wait for an explicit yes.

**Step 5: Update**

Call `hubspot-update-deal-line-item` once per affected line with `id` = its record-id and only the changed fields.

**Step 6: Verify and report**

Call `hubspot-get-deal-line-items` again for the deal and report the stored values and new total. If the deal's `amount` does not follow the line items in this portal, say so; do not update the deal yourself.

**Rules & Guidelines:**

* Only `hubspot-update-deal-line-item` may write, once per affected line, after Step 4.
* Do NOT call any other write tool: no other hubspot-add, hubspot-update, hubspot-rename, hubspot-remove, hubspot-subscribe, hubspot-unsubscribe or hubspot-import tool.
* Never add or remove line items in this prompt; `hubspot-add-deal-line-item` cannot link a new item to the deal.

**Validation:**

* If a requested change is to something other than quantity, price or discount, say it is not supported here and leave it out.

Who it's for

One answer, three teams that use it

Account executives

Update a deal right after the negotiation

Apply the agreed seats, prices and discounts in one message and see the new total before anything is saved.

On the Fabrikam Expansion deal in HubSpot, change Analytics seats to 25 and set the unit price to 80.

Sales managers

Apply approved discounts accurately

Put an approved discount on the right line and check the net price and deal total before it lands.

Give a 15 percent discount on Premium Support on the Contoso Renewal deal in HubSpot and show me the new total.

Deal desk

Catch totals that drift from the lines

After each change the stored lines are read back, and you are told if the deal amount does not follow them.

Set Onboarding hours to 40 on the Northwind Traders Implementation deal and tell me if the deal amount still matches.

How it works

What PopdockAI does when you ask

You describe the changes in plain words and your AI assistant matches them to the deal's line items. Nothing is saved until you have seen the old and new values and said yes.

01

Ask

You name the deal and the changes, such as a new quantity or discount.

Your AI tool

02

Match

It reads the deal's line items and matches each change by name or SKU.

hubspot-get-deals
hubspot-get-deal-line-items

03

Confirm

You see old and new values, net prices and the expected deal total, and say yes.

No items found.

04

Update

It saves the changed lines, reads them back and reports the stored values.

Your AI tool

What PopdockAI provides

The tools behind the answer

Ready made tools for HubSpot and one secure connection to your AI tool. No code, no exports.

get-data

hubspot-get-deals

Returns deals from HubSpot CRM, with amount, stage, pipeline, close date, owner and associated company and contact from the HubSpot connector. Filter by pipeline name, close date, deal stage name, deal type, record id, company id, deal name, amount, deal owner.
get-data

hubspot-get-deal-line-items

Returns line items on deals, with product, SKU, quantity, prices and billing terms from the HubSpot connector. Filter by create date, deal id, net price, name, sku.
run-action

hubspot-update-deal-line-item

Updates a deal line item in HubSpot. Only the fields you pass are changed. Required: Deal line item ID. Optional: Name, Quantity, Unit price, SKU, Discount percentage, Billing frequency, Description. Writes to HubSpot.
run-action

hubspot-add-deal-line-item

Creates a line item in HubSpot (it is not linked to a deal by this tool) and returns the new deal line item's ID. Required: Name. Optional: Quantity, Unit price, SKU, Discount percentage, Billing frequency, Description. Writes to HubSpot.
Read only.Nothing in HubSpot Changes

This report is built from Get data tools only. PopdockAI applies the row, field and parameter rules your admin sets, and every query is written to the audit trail.

How Popdock AI secures your data

The outcome

Line items that change exactly as agreed

Try PopdockAI free
Get a live demo

Related use cases

More ways to put this data to work

All Ramp use cases

One prompt template with infinite possibilities.

‍

Your AI assistant adapts its approach, tone, and capabilities to match each unique context while you maintain a single, manageable workflow.

Join forward-thinking companies that are transforming their operations with intelligent, secure AI automation.

Try PopdockAI Free
See Documentation