Add Missing Last Name
Automatically add a last name to Linnworks orders where the customer gave only one name, so courier labels always show a full name.
Overview
Add Missing Last Name is an automated order-cleaning solution for Linnworks. It finds orders where the customer's name is a single word and adds a last name that you choose.
The macro runs through the Linnworks Rules Engine. It checks the full name on the shipping address and, if there is no last name, adds yours after the first name. Orders that already have a full name are left as they are.
Many couriers need both a first and last name on the label. This macro fills the gap automatically, so these orders do not get stuck at despatch.
Add Missing Last Name helps you avoid courier label errors, save time editing names by hand and keep orders moving.
Completes names
Turns a single name such as "John" into "John Customer" using the last name you set.
Runs automatically
The Rules Engine sends matching orders to the macro. You only need to set one value.
One simple setting
Choose the last name to add, for example "Customer".
Video Walkthrough
Configure the Macro
Once the app is installed, please create a macro configuration. This tells Linnworks which macro to run and lets you select it in the Rules Engine.
You can change this set-up at any time to suit how you work.
Steps to Configure
Go to Apps > Macro Configuration and click + Add new configuration.

Select the AddMissingLastName macro and click Create Configuration.

In the Macro Configuration screen, add the configuration name and the last name to use. Then click Save.

This macro has one required setting:
| Parameter | Required | Description |
|---|---|---|
| SetLastName | Yes | The last name added to customer names that are a single word. If it is left blank, the macro does not change any order. |
For example, enter:
Customer
With this value, an order for "John" becomes "John Customer".
Please enter one word only, with no spaces before or after it. A neutral word such as "Customer" makes it clear the last name was added for you.
Please make sure the macro is enabled so you can use it in the Rules Engine.

Note: If the macro is not enabled, it will not appear in the Action value list when you set up the rule.
Go to Orders > Rules engine and click + Add new rule.

Enter the rule name and click Create.

Click Add new, select Condition, set the condition as required and save it.


Use conditions that target the orders you want checked, for example orders from a particular channel or orders ready for despatch.
Add the macro action and click Save.


In the Add action window:
- Enter an Action name, for example
Add Missing Last Name - Set Action type to
Execute a macro - In Action value, select
AddMissingLastName - Click Save
Note: If the macro is not enabled, it will not appear in the Action value list when you set up the rule.
Review the saved rule.

- Check that the condition and action are connected correctly
- Click Save in the bottom-right corner to save the rule
Who Should Use Add Missing Last Name
Warehouse & Fulfilment Teams
Labels print without name errors, so parcels are not held back while someone edits the order.
Logistics Managers
Fewer courier rejections for orders where the customer entered only a first name.
Linnworks Administrators
Administrators set up the macro in Linnworks, enable it and choose which orders it runs on.
Operations & Customer Service Teams
Customer names are consistent, which makes orders easier to search and review.
Key Features
Finds single-word names
Checks the full name on the shipping address and spots names with no last name.
Your own last name
You choose the last name that is added, for example "Customer".
Leaves full names alone
Names that already have two or more words are never changed.
Safe to run again
An order that has already been updated is not changed a second time.
Handles large batches
The macro stays within the Linnworks time limit and does not start an order it cannot finish.
How Add Missing Last Name Works
Add Missing Last Name follows the same steps each time it processes one or more orders. The Rules Engine starts it and sends it the matching orders automatically.
Step 1: The setting is checked
The macro reads your SetLastName value. If it is blank, the macro stops straight away and does not change any order.
Step 2: The customer name is read
For each order, the macro reads the full name on the shipping address. Orders with no address or an empty name are skipped.
Step 3: Single-word names are completed
If the name is one word, such as "John", the macro adds your last name to make "John Customer". Names with two or more words are left unchanged.
Step 4: The order is saved
The macro saves the new name on the order and on the customer record in Linnworks.
Key Benefits
The macro replaces the manual job of finding orders with a single name and typing in a last name before despatch.
Complete names mean fewer courier rejections and faster despatch.
Fewer label errors
Couriers that need a first and last name receive a complete name every time.
Quick to set up
Enter one last name, enable the macro and add it to a rule.
No manual editing
Orders are updated automatically as soon as they match your rule.
Only changes what it needs to
Orders that already have a full name are left exactly as they are.
Usage of App
Add Missing Last Name runs through the Linnworks Rules Engine to complete customer names on the orders you choose.
Execution
Once your rule is active, the macro runs automatically on every order that matches it. You can also run it yourself on the orders you choose. This is handy for testing, or for orders that need it straight away.
Quick path: Orders > Open Orders → select your orders → Actions → Other actions → Run rules engine → Add Missing Last Name
Select your orders
Go to Orders > Open Orders and tick the box next to each order you want the macro to process.
Open the Actions menu
Click the Actions button at the top left of the screen. You can also right-click any of the selected orders.
Go to Other actions > Run rules engine
Point to Other actions, then Run rules engine. A list of your rules appears.
Choose your rule
Click the name of the rule you created in Step 6 of Steps to Configure, for example Add Missing Last Name. The macro runs on the selected orders straight away.

Good to know: The rule's conditions still apply, so the macro only changes selected orders that match them. If you choose All instead of your rule's name, every active rule runs on the selected orders.
Outcome
When the macro runs on an order, it:
Reads the customer name
The macro checks the full name on the shipping address.

Adds the last name
A single-word name such as "John" becomes "John Customer" when SetLastName is Customer.

Please note: The macro changes the customer name directly on the order and on the customer record in Linnworks. We recommend testing on a few orders first.
Input Parameters
You enter this macro's only setting, SetLastName, in Step 3 of Steps to Configure. Please fill it in, as the macro does not change any order while it is blank.
The Rules Engine sends the matching orders to the macro automatically, so you do not need to enter any order numbers.
The following behaviour is built into the macro and cannot be changed on the Macro Configuration screen:
| Setting | Description |
|---|---|
| Field checked | The full name on the shipping address only. The billing name is not changed. |
| Single-word name | A name with no space in it, such as "John" or "Mary-Jane". |
| Customer record | The updated name is also saved to the customer record in Linnworks. |
Best Practices
A few simple checks before you switch the rule on will give you the best results.
Choose a clear last name
Pick a neutral value such as "Customer", so it is obvious the last name was added for you.
Use targeted rule conditions
Set up the Rules Engine so the macro runs only on the orders that need it.
Test before enabling at scale
Run the macro on a few test orders first before switching it on for all orders.
Run before printing labels
Place the rule so the macro runs before labels are generated, so couriers receive the complete name.
FAQ
How is Add Missing Last Name triggered?
The macro runs through the Linnworks Rules Engine. When an order matches your rule, the Rules Engine sends it to the macro automatically.
Can I run the macro on an order straight away?
Yes. Select the orders in Orders > Open Orders, then click Actions or right-click them. Choose Other actions > Run rules engine and select the rule name you created in Step 6. The rule's conditions still apply.
Does the macro need any settings?
Yes. Please enter a last name in SetLastName, for example Customer. This is the only setting.
What happens if SetLastName is left blank?
The macro stops without changing any order and records the reason in the macro log. Please add a last name and run it again.
Which names does the macro change?
Only names that are a single word with no space, such as "John". Names such as "John Smith" or "Mary Ann Jones" are never changed.
Does the macro change the billing name?
No. It changes only the full name on the shipping address.
Is the customer record in Linnworks updated too?
Yes. The new name is saved on the order and on the matching customer record.
What happens if the macro runs on the same order twice?
Nothing changes the second time. The name already has two words, so the macro leaves it alone.
Does the macro add an order note?
No. You can see each change in the macro log in Linnworks.
What happens if many orders are sent at once?
The macro works within the Linnworks time limit for macros. If time runs short, it stops before starting the next order. Orders it did not reach are left untouched and are processed the next time the rule runs on them.
Legal Information
- Privacy Policy: https://rishvi.co.uk/privacy-policy/
- Terms and Conditions: https://rishvi.co.uk/terms-conditions/
Please review these pages to understand how data is handled and the terms that apply to this application.
Summary
Add Missing Last Name automatically completes customer names on the Linnworks orders you choose.
Once it is set up through the Rules Engine, the macro adds your chosen last name to any single-word name. Orders that already have a full name are left unchanged.
Complete customer names
Single-word names get your chosen last name before despatch.
Rules Engine automation
Matching orders are sent to the macro automatically through your Linnworks rule.
If an order does not give the expected result, please check that the macro configuration is enabled and that SetLastName is filled in. Please also make sure the order matches your rule's conditions.