Export to M3 Mapping (API)

Sections

Mapping available here.

M3 export mapping file is divided in 5 sections and each section is further divided into 2 sections

  • Header

    • Header Static Fields

    • Header Fields

  • Tax Lines

    • Tax Line Static Fields

    • Tax Line Fields

  • Receipt Lines

    • Receipt Line Static Fields

    • Receipt Line Fields

  • Order Charge Lines (Additional Amounts)

    • Order Charge Static Fields

    • Order Charge Fields

  • Cost Lines

    • Cost Line Static Fields

    • Cost Line Fields

Adding/Removing Fields

Adding New Field:

  • First we need to add the M3 API field name to the relevant section’s fields list property (e.g. StaticFields, HeaderFields, InvoiceTaxFields)

  • Define the static value or document field name for the API field with appropriate prefix for the section

    • Example 1: To define a static value of AAA for the M3 API field DIVI. First we added DIVI to StaticFields property. Then we add a line SF_DIVI = AAA as SF_ is the prefix for static fields

    • Example2: To map header field IVDT (invoice data) to invoice_date field of DocBits. First we add IVDT to HeaderFields property. Then we add a line HF_IVDT = invoice_date as HF_ is the prefix for header fields

Removing Field:

  • Just remove the field from section’s field list property and remove the line defining value for the field.

Available M3 API Fields

  • Available M3 fields can be checked by opening appropriate screen in M3.

  • Open program APS450 by pressing Ctrl + R and open any invoice

  • Here you have the list of fields available for the API. You can get field name by right clicking the field and click show Field Information. It will open a popup like below

  • Here the Field help is the API field name.
  • Similarly you can get field names for lines

Header

Header Static Fields

Fields List Property: StaticFields

Section Fields Prefix: SF_

Available Fields: You can map any M3 API field with any static value

Header Fields

Fields List Property: HeaderFields

Section Fields Prefix: HF_

Available Fields: You can map any DocBits field to any M3 API field

Tax Line

Tax Line Static Fields

Fields List Property: InvoiceTaxStaticFields

Section Fields Prefix: IT_SF_

Available M3 Fields: Please check M3 API or UI

Available DocBits Fields: You can put any value as they are static fields

Tax Line Fields

Fields List Property: InvoiceTaxFields

M3 Fields Prefix: ITF_

DocBits Table Field Prefix: TF_

Available M3 Fields: Please check M3 API or UI

Available DocBits Fields: line_number, tax_amount, tax_rate, net_amount, gross_amount, tax_code_full, tax_code, tax_country

Receipt Line

Receipt Line Static Fields

Fields List Property: InvoiceReceiptStaticFields

Section Fields Prefix: IR_SF_

Available M3 Fields: Please check M3 API or UI

Available DocBits Fields: You can put any value as they are static fields

Receipt Line Fields

Fields List Property: InvoiceReceiptFields

M3 Fields Prefix: IRF_

DocBits Table Field Prefix: TF_

Available M3 Fields: Please check M3 API or UI

Available DocBits Fields: packing_slip, purchase_order, line_number, line_sequence, delivery_number, delivery_line, amount, quantity, total_net_amount

Order Charge Line

Order Charge Static Fields

Fields List Property: OrderChargeStaticFields

Section Fields Prefix: OC_SF_

Available M3 Fields: Please check M3 API or UI

Available DocBits Fields: You can put any value as they are static fields

Order Charge Fields

Fields List Property: OrderChargeFields

M3 Fields Prefix: OCF_

DocBits Table Field Prefix: TF_

Available M3 Fields: Please check M3 API or UI

Available DocBits Fields: ledger_account, dimension_2-7, amount, quantity, quantity2, position

Cost Line

Cost Line Static Fields

Fields List Property: InvoiceCostStaticFields

Section Fields Prefix: IC_SF_

Available M3 Fields: Please check M3 API or UI

Available DocBits Fields: You can put any value as they are static fields

Cost Line Fields

Fields List Property: InvoiceCostFields

M3 Fields Prefix: ICF_

DocBits Table Field Prefix: TF_

Available M3 Fields: Please check M3 API or UI

Available DocBits Fields: ledger_account, dimension_1-12, amount, quantity, quantity2, position

Table of Contents