Connectors

/

Microsoft Dynamics GP

/

Return items to a vendor in Dynamics GP
Write

Send faulty goods back to the right vendor

For operations teams who want a Dynamics GP return to vendor created against the right supplier and RMA, by asking their AI assistant.

Try PopdockAI free
Get a live demo
Return items to a vendor in Dynamics GP
Return the damaged LP-10 printers from RMA-1042 to Fabrikam Supply in Dynamics GP.
RMA-1042 has 2 items, and Fabrikam Supply supplies one of them. - Return: 5 LP-10 printers at the last receipt cost of 228 - Left out: 1 item supplied by another vendor - Address: Fabrikam Supply returns, Portland - Codes: return type and reason as used on recent returns Shall I create the return to vendor?
Microsoft Dynamics GP
Sample figures. Your results come from your own account.
microsoft-dynamics-gp-get-pm-vendor
microsoft-dynamics-gp-get-pm-vendor-address
microsoft-dynamics-gp-get-srv-rma-line
microsoft-dynamics-gp-get-iv-vendor-item
microsoft-dynamics-gp-get-srv-rtv
microsoft-dynamics-gp-srv-rtv-add
microsoft-dynamics-gp-srv-rtv-line-add
microsoft-dynamics-gp-get-srv-rtv-line

On this page

The problem

The problem

The prompt

Who it's for

How it works

Tools used

Connector

Microsoft Dynamics GP

Microsoft Dynamics GP
Run it on your own Microsoft Dynamics GP data.

Connect Microsoft Dynamics GP, pick your AI tool and paste the prompt.

Try PopdockAI free

The problem

Goods sent back to the wrong vendor

Sending faulty goods back to a vendor in Dynamics GP means working out which items that vendor supplied, finding the return address and codes, and keying each line at cost. Items go to the wrong vendor, or the paperwork never matches the customer RMA.

Without PopdockAI

  • Work out which returned items this vendor supplied
  • Look up the return address and RTV codes
  • Find the last receipt cost for each item
  • Key each line and hope it matches the RMA

With PopdockAI

  • The vendor and return address are found
  • With an RMA, only items this vendor supplies are kept
  • Lines are priced at the last receipt cost with codes already in use
  • You confirm every line, and the stored lines are read back

The prompt

Use this prompt

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

Prompt
**Objective:** Create a return to vendor for goods going back to `{vendor-name}` (from customer RMA `{rma-number}`, if given), after the user confirms the lines.

Pass `{company}` as `company` on every call (if it is empty, omit `company` and the default company is used). Pass a generous `max-records` (1000). If a result comes back with exactly that many rows, say the result may be truncated.

**Step 1: Vendor and address**

Call `dynamics-gp-get-pm-vendor` with `vendor-name.contains` (or `vendor-id`); if several match, list them and stop. Call `dynamics-gp-get-pm-vendor-address` by `vendor-id` for the return `address-code`.

**Step 2: What to return**

If `{rma-number}` is given, call `dynamics-gp-get-srv-rma-line` by `return-document-id` and keep items this vendor supplies (check with `dynamics-gp-get-iv-vendor-item` by `vendor-id` and `item-number`). Otherwise ask the user which items and quantities are going back. Take `last-receipt-cost` from the vendor item as the part cost.

**Step 3: Codes to reuse**

Call `dynamics-gp-get-srv-rtv` by `vendor-id` (or unfiltered, a few rows) to see the `rtv-type` and `rtv-status` values in use for a new return.

**Step 4: Confirm**

Ask the user for the RTV number and the location the goods ship from. Show the user exactly what will be written, field by field, and ask for explicit confirmation. Do nothing further without a clear yes. Show vendor, address code, RTV number, type, status, and each line (item, vendor item number, quantity, part cost, RMA number).

**Step 5: Write**

1. Call `dynamics-gp-srv-rtv-add` once with `rtv-number`, `vendor-id`, `address-code`, `rtv-type`, `rtv-status`, `rma-number` and `location-code`.
2. Only if that succeeded, call `dynamics-gp-srv-rtv-line-add` once per line with `rtv-number`, `rtv-line` (1, 2, 3 ...), `item-number`, `quantity`, `part-cost`, `vendor-item-number`, `rma-number` and `location-code`.

If a line fails, stop and report which lines exist. Do not retry a failed write automatically. Report the error exactly as returned.

**Step 6: Verify**

Call `dynamics-gp-get-srv-rtv-line` by `rtv-number` and report the stored lines.

**Rules & Guidelines:**

* The only write tools this prompt may call are `dynamics-gp-srv-rtv-add` (once) and `dynamics-gp-srv-rtv-line-add` (once per confirmed line), after Step 4.

**Validation:**

* If none of the RMA's items come from this vendor, say so and stop.

Who it's for

One answer, three teams that use it

Returns coordinators

Turn a customer RMA into a vendor return

Items from the RMA that this vendor supplied are carried across, so the paperwork lines up.

Send the faulty items from RMA-2210 back to Contoso Components in Dynamics GP.

Purchasing

Return stock at the right cost

Lines are priced at the last receipt cost, so the credit you expect matches what you paid.

Return 8 CART-12 cartridges to Fabrikam Supply in Dynamics GP, they were the wrong colour.

Warehouse leads

Ship returns to the right address

The vendor's return address is found for you, so goods do not go to the wrong location.

Raise a return to Northwind Supply in Dynamics GP for 2 SD-200 docks that failed testing.

How it works

What PopdockAI does when you ask

You name the vendor and optionally the customer RMA, and your AI assistant builds the return from Dynamics GP. Nothing is created until you confirm every line.

01

Ask

You name the vendor, and optionally the customer RMA the goods came from.

Your AI tool

02

Match

It finds the return address and keeps only items this vendor supplies.

microsoft-dynamics-gp-get-pm-vendor
microsoft-dynamics-gp-get-pm-vendor-address
microsoft-dynamics-gp-get-srv-rma-line
microsoft-dynamics-gp-get-iv-vendor-item
microsoft-dynamics-gp-get-srv-rtv

03

Confirm

You approve every line, priced at the last receipt cost with existing codes.

No items found.

04

Create

It creates the return and lines and reads them back.

Your AI tool

What PopdockAI provides

The tools behind the answer

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

get-data

microsoft-dynamics-gp-get-pm-vendor

Returns vendor records from Dynamics GP Payables Management, including contact details, payment terms, status and current balance. Filter by vendor name, hold, vendor class ID, vendor status, state, current balance, city and vendor ID, and pick the company and the maximum number of records.
get-data

microsoft-dynamics-gp-get-pm-vendor-address

Returns vendor address records from Dynamics GP Payables Management, with the vendor, address code, contact, location and phone details. Filter by city, vendor ID, vendor name, state, country, zip code, address code and vendor status, and pick the company and the maximum number of records.
get-data

microsoft-dynamics-gp-get-srv-rma-line

Returns return material authorization lines from Dynamics GP Field Service, with the customer, returned item, quantity, status, reason and dates. Filter by return document ID, entry date, return status, extended price, item number, customer ID, return type and customer name, and pick the company and the maximum number of records.
get-data

microsoft-dynamics-gp-get-iv-vendor-item

Returns vendor item records from Dynamics GP Inventory, linking items to the vendors who supply them with order quantities, lead times and last receipt details. Filter by vendor ID, last receipt date, vendor item description, quantity on order, vendor item number and item number, and pick the company and the maximum number of records.
get-data

microsoft-dynamics-gp-get-srv-rtv

Returns return to vendor documents from Dynamics GP Field Service, with the vendor, related RMA, status, key dates and costs. Filter by vendor ID, vendor name, location code, entry date, RTV status, RTV number, RTV type and part cost, and pick the company and the maximum number of records.
run-action

microsoft-dynamics-gp-srv-rtv-add

Adds a return to vendor in Dynamics GP through eConnect; GP defaults any field not listed. Requires address code, RTV number, vendor ID, RTV status and RTV type. Optional: shipping method, office ID, vrma document ID, description, RMA number and location code. Writes to the live Dynamics GP company database.
run-action

microsoft-dynamics-gp-srv-rtv-line-add

Adds a return to vendor line in Dynamics GP through eConnect; GP defaults any field not listed. Requires RTV line, item number and RTV number. Optional: quantity, RMA number, vendor item number, unit of measure, item description and type. Writes to the live Dynamics GP company database.
get-data

microsoft-dynamics-gp-get-srv-rtv-line

Returns return to vendor lines from Dynamics GP Field Service, showing the item, vendor, RTV status, quantities shipped and received and key dates. Filter by entry date, item number, purchase order number, item description, RTV status, vendor ID, RTV number and RTV type, and pick the company and the maximum number of records.
Read only.Nothing in Microsoft Dynamics GP 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

Returns to the right supplier, ready to recover cost

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