What are Macro Tags

In some areas of the site, you have the option to create default text, for example default e-mail message. Macros are tags that you put in that text and when the text is generated, real-time information is substituted for them.

For example: Every registered seller has the option to generate an invoice to their buyer after they receive an order. BrickLink uses a default template for invoices but the seller has the option to fully customize the whole layout and add or remove text. Below on the left is a sample of an invoice and on the right is the default template that the invoice is generated from. The template uses macros for the different types of information, for example order ID, buyer address or items in order. When an invoice is generated, the order information is substituted for the macro. Macros are the keywords enclosed in left and right brackets. Click Here for a full list of all the macros that you can use, their explanation and e-mail types where they can be used.

Sample Invoice: Default Invoice Template Layout:
 
Invoice for BrickLink Order #1234
generated on 11/17/01 9:03:11 PM

Order Date: 9/12/00 12:12:00 AM
Payment By: Paypal.com
--------------------------------------
Comments from Seller:
Please send a grand total of $19.60 to ...
--------------------------------------
Order Summary:
--------------------------------------
Total Items: 100
Unique Items (lots): 9

Total: $17.60
Shipping: $2.00
Insurance: $0.00
Additional Charges: $0.00
Grand Total: $19.60
--------------------------------------
Items in Order:
--------------------------------------
*
* Batch #1
*
Black Brick 1 x 1 x 5 (x40) ..... $0.15 each = $6.00
Black Door 1 x 4 x 8 (x2) ..... $0.38 each = $0.76
Black Hinge Car Roof 4 x 4 (x4) ..... $0.15 each = $0.60
Black Hinge Tile 1 x 4 (x4) ..... $0.11 each = $0.44
Black Net (x2) ..... $0.38 each = $0.76
Brown Baseplate 16 x 16 (x4) ..... $0.75 each = $3.00
Dark Grey Slope 75 (x20) ..... $0.15 each = $3.00
Green Slope 45 2 x 1 (x8) ..... $0.08 each = $0.64
Green Slope 45 2 x 2 (x16) ..... $0.15 each = $2.40

--------------------------------------
Buyer Information:
--------------------------------------
BrickLink Username: Test1
E-Mail: test@test.com

Address:
John Doe
1234 Street
City, State, Zip 98585
USA
--------------------------------------
Seller Information:
--------------------------------------
BrickLink Username: Test2
E-Mail: sample@sample.com
BrickLink Store Name: John's Bricks

Address:
Jane Doe
4343 West Avenue
Nowhere, Bangkok
Vietnam

Invoice for BrickLink Order # <ORDERID> generated on <CURRENTDATETIME>

Order Date: <ORDERDATE>
Payment By: <PAYMENTTYPE>
--------------------------------------
Comments from Seller:
<COMMENTS>Please send a grand total of $<GRANDTOTAL> to ...</COMMENTS>
--------------------------------------
Order Summary:
--------------------------------------
Total Items: <ORDERITEMS>
Unique Items (lots): <ORDERLOTS>

Total: $<ORDERTOTAL>
Shipping: $<ORDERSHIPPING>
Insurance: $<ORDERINSURANCE>
Additional Charges: $<ORDERADDCHRG>
Grand Total: $<GRANDTOTAL>
--------------------------------------
Items in Order:
--------------------------------------
<ORDERDETAIL>
--------------------------------------
Buyer Information:
--------------------------------------
BrickLink Username: <BUYERUSERNAME>
E-Mail: <BUYEREMAIL>

Address:
<BUYERNAME>
<BUYERADDRESS>
--------------------------------------
Seller Information:
--------------------------------------
BrickLink Username: <SELLERUSERNAME>
E-Mail: <SELLEREMAIL>
BrickLink Store Name: <SELLERSTORENAME>

Address:
<SELLERNAME>
<SELLERADDRESS>