Suppliers

This section describes both suppliers and production units. 

Supplier data fields 

Field

Description

Data type

supplier_name

Name of the supplier

String

supplier_number

The supplier number

String

groups

A list of groups matching groups in Qarma (used for controlling access)

List of strings

production_units

A list of production units for this supplier. The list needs to include all production units linked to the supplier (the full final state). When updating an existing supplier, any linked production units that are not included in the import data will be unlinked. 

  • production_unit_number (required)

  • production_unit_name (optional)

Creation and update lifecycle

New records will only be created, if there is no existing supplier or production unit matching on:

  • Supplier number if provided 

  • Supplier name (only if no number if provided - note that fuzzy matching is applied to match names. The fuzzy matching removes all paces, commas, and periods, and also lower cases. So e.g.
    "Shanghai Factory, China" and “shanghaifactorychina” will match to the same supplier.


If an existing supplier is found, it will be updated with the information supplied. 

Production Units

This section describes production units. Although production units can be created when updating or creating suppliers, the only way to update a production unit is through the following fields.

Note that production units can only be updated if the organization has unit production unit numbers.

Production unit fields

Field

Description

Data type

production_unit_name

Name of the production unit

String

production_unit_number

The production unit number

String

production_unit_address

The address of the PU

String

location

The gps location of the PU

  • latitude

  • longitude

map

float

custom fields

Custom fields defined per organization in Qarma

Depends on which type of custom field (date, number, text, list)

status

The status of a production unit

String

upstream_production_units

A list of production units that supply to the current production unit. The list needs to include all upstream production units  (the full final state). When updating an existing production unit, any linked production units that are not included in the import data will be unlinked. 

  • production_unit_number (required)

  • production_unit_name (optional)

General notes

Omission of a field will mean that this field is not updated when matching an existing entity in Qarma. If fields need to be cleared, an empty value needs to be provided rather than omitting the field.