EPCIS 2.0 and EPCIS 1.2

Discover the specifics of EPCIS, how it works, and what OpenEPCIS is.

The standards and resources this page refers to are listed below; follow them if you want to read the EPCIS standard in full.

Introduction & History

EPCIS is an open ISO/IEC/GS1 standard for capturing visibility data as events and sharing those events within an organization or between organizations. It serves companies that move products between stages of their own operations just as well as companies that hand products on to trading partners.

The Bigger Picture: EPCIS is the event backbone that connects RFID, QR codes, NFC and IoT sensors into a unified product-tracking infrastructure. To see how EPCIS fits with DIDs, Verifiable Credentials and the broader digital-twin ecosystem, read The Digital Twin Vision.

EPCIS events can describe physical objects such as assets, products, logistic units and reusable transport items, and they can equally describe digital objects such as music downloads, electronic books, electronic coupons and subscriptions. The standard was designed to improve cooperation between trading partners by letting them exchange comprehensive information about these items. EPCIS 1.0 was released at the beginning of 2007, followed by EPCIS 1.1 in 2014 and EPCIS 1.2 in 2016, each with various enhancements. The current version, EPCIS 2.0, was published in June 2022 and brought many significant additions.

EPCIS data exists to make a business process visible. Figure 1 shows how EPCIS data may be generated in a simple business process.

Figure 1: Generation of EPCIS events in a simple business process.

The figure follows one item through a simplified business process. A manufacturer produces it, packs it and ships it to the retailer's distribution centre, which receives it and sends it on to a retail store. The store receives it in turn and moves it to a sales area, where a consumer can buy it.

Packing, shipping and receiving are the critical tracking events in this process, and each of them creates an EPCIS event that records what happened to the item at that point. Together, these events describe the whole process. The GS1 EPCIS standard is defined in ISO/IEC 19987.

Each EPCIS event carries its context in five dimensions: What, When, Where, Why and How. Every dimension is made up of several fields. The dimensions are independent of one another, and an event does not have to include all of them or all of their fields. When the product in the example above is shipped from the manufacturer to the retail distribution centre, the event fills four of the dimensions:

  • What names the items or containers that were sent to the distribution centre.
  • When gives the date and time of the shipment together with its time zone offset.
  • Where gives the location the shipment was sent from and where the items are expected to be after the event.
  • Why gives the business context; in this event, the business step is shipping.

Areas of application for EPCIS

Because EPCIS events can be stitched together over time, within one organization or across several, they support a range of applications. The most recent event for an object tells an organization exactly where that object is in the supply chain, which is the basis for tracking. All events for an object, read together, lead back to its origin, which is the basis for tracing. Events collected over a period can be analyzed in a specific business context. An incoming event can trigger other business processes in real time, so EPCIS also drives automation. Finally, comparing the status that the current event reports with the state the object was expected to be in allows an organization to verify its processes.

Benefits of EPCIS

EPCIS is used in many industries, among them automotive, healthcare, food services, transport and retail, and the benefits depend on the sector. Identifying where an object originated supports anti-counterfeiting measures, and a dated chain of custody shows who held the object and when. Digital coupons can be validated in real time, and the freshness of a product can be recognized. Organizations can be notified in real time about the location, timing, status, quantity or quality of a product, which helps them ensure that items reach consumers at the right place and time. All of this adds up to better protection for consumers.

EPCIS event types

The five dimensions describe activities that happen to physical objects in the real world and to digital objects in the virtual world. Which event type an organization uses depends on what kind of process the objects go through, and EPCIS defines five of them. Every event type can carry all five dimensions, although the fields available in each dimension vary with the event type.

ObjectEvent

An ObjectEvent records something that happened to one or more physical or digital objects; in other words, it is a simple observation of business objects. It may carry instance-level EPCs (Electronic Product Codes) or class-level identifiers without any relationship between them. A typical example is a pallet that is shipped or received and identified by its SSCC (Serial Shipping Container Code).

AggregationEvent

An AggregationEvent records that one or more objects were aggregated or disaggregated. The aggregated objects have a strong physical relationship and stay at the same location until they are disaggregated. The event is reversible: disaggregation gives back the original objects. Packing cases onto a pallet and unloading a container are typical examples.

TransactionEvent

A TransactionEvent records that one or more physical or digital objects were associated with or disassociated from business transactions, for example when the pallet and the cases of milk cartons on it are linked to their commercial invoice.

TransformationEvent

A TransformationEvent records that one or more physical or digital objects were consumed entirely or partially and that outputs were produced from them. A transformation is irreversible, which sets it apart from an AggregationEvent: once the inputs are transformed, they cannot be recovered. The process may also take a considerable amount of time. Baking a chocolate cake is a good example, since the mixed ingredients can never be separated again.

AssociationEvent

An AssociationEvent records that one or more physical or digital objects were associated with a parent object or with a location, or that the association was undone. As with an AggregationEvent, the objects stay together at the same place and time until they are disassociated. Two things set it apart:

  • It can associate objects with a physical location; an AggregationEvent cannot.
  • The association may be permanent, or at least long-term.

Building a wagon out of screws, tyres and sensors is an AssociationEvent, and loading that wagon with vegetables or cosmetic cases is an AggregationEvent. If the wagon itself had been recorded as an aggregation, unloading the goods and dismantling the wagon would look the same in the data.

Dimensions of EPCIS

As described above, every EPCIS event carries its context in five dimensions, and the fields in each dimension depend on the event type. The following sections describe each dimension in turn.

What

The What dimension identifies the physical or digital objects involved in the event. GS1 provides an identification scheme for each kind of business object, for instance the GTIN (Global Trade Item Number), the SGTIN (GTIN with serial number), the SSCC (Serial Shipping Container Code) and the GIAI (Global Individual Asset Identifier). Figure 2 shows the attributes of the What dimension for the different event types.

Figure 2: EPCIS 2.0 What Dimension

Instance Level

An instance-level identifier belongs to exactly one object, so no two objects share it. A manufacturer may, for example, give every toy or phone it produces its own number. Instance-level identifiers are represented as EPCs, and their GS1-conformant values can be written either as an EPC URI (Uniform Resource Identifier) or as a GS1 Digital Link URI.

Class level

A class-level identifier is shared by many objects. A pallet holding hundreds of toys from the same production, for example, may carry one such identifier. Class-level identifiers can be used in the Quantity element, which has the following structure:

  • EPC Class: the class-level identifier to which the counted objects belong.
  • Quantity: an optional field stating how many or how much of the EPC Class is meant. If it is missing, the quantity is unknown.
  • UOM: the optional unit of measure for the quantity, given as a unit code such as KGM for kilogram.

When

The When dimension gives the date and time of the event. Figure 3 shows its attributes.

Figure 3: EPCIS 2.0 When Dimension

Event time

The event time is the date and time at which the event took place. When objects arrive at a docking station at their destination, for example, the receiving event carries the exact date and time of their arrival as its event time.

Event time zone offset

The event time zone offset records the time zone in which the event took place. Events need to be shown in local time, which is why the offset matters. An item shipped from Germany to India produces an event with the offset of Central European Time, and the receiving side uses this information to display the event in Indian Standard Time (IST).

Record time

The record time is the date and time at which the event was stored in the EPCIS repository. It says nothing about the business step itself, and unlike the other event data it is set when the repository stores the event. It serves as a reference that can be useful when retrieving data from the repository.

Where

The Where dimension gives the physical location where the event took place and can also state where the items are after the event. Figure 4 shows its attributes.

Figure 4: Attributes of Where dimension.

Read point

The read point is the exact location where the event took place, and capturing devices such as RFID readers can determine it. Picture a receiving site where a box of objects passes through a door portal and is scanned there: the location identifier tied to that door becomes the read point of the event.

Business location

The business location is where the items are considered to be after the business step. Continuing the example, once the box has passed the door portal and the receiving event has been recorded, the items are put into a warehouse, and the location identifier tied to the warehouse becomes the business location of the event.

Why

The Why dimension gives the business context of the event. Figure 5 shows its attributes.

Figure 5: Attributes of Why dimension.

Business step

The business step states which business process was taking place when the event occurred. Examples from the CBV (Core Business Vocabulary) are receiving, picking and shipping.

Disposition

The disposition describes the state of the object immediately after the event. CBV values for it include expired, recalled, active and in_transit. An event with the business step shipping, for example, would typically carry the disposition in_transit.

Persistent Disposition

The persistent disposition was introduced with EPCIS 2.0. It holds one or more business conditions that apply to the object after the event. Each value can be set or unset independently of the others, and a value stays set until it is explicitly unset. The CBV values for persistent disposition are similar to those for disposition.

Business Transaction

This field lists one or more business transactions the event relates to. CBV examples include inv (invoice), po (purchase order) and desadv (dispatch advice). A business transaction consists of two fields:

  • Type: an optional field stating what kind of transaction is meant.
  • Business Transaction: the identifier of the particular transaction.

Source and Destination

Source and destination add business context whenever ownership or possession of the items changes hands. In a complex business process, different parties may carry out the individual business steps, so the event needs to name every party involved. Read point and business location in the Where dimension describe the physical location of the business step; source and destination name the parties involved and can optionally add the physical location where the business process starts or ends.

In a multi-step supply chain process, some or all of the events may share the same source and destination. Source and destination are made up of the following fields:

  • Source and Destination type: the type of source or destination. There are three of them.
  • Owning party: the party that owns the objects at the start or end point.
  • Possessing party: the party that physically holds the objects at the start or end point, such as a third-party delivery service.
  • Location: the physical location where the business step starts or ends.

How

The How dimension, introduced with EPCIS 2.0, carries a list of sensor elements. They describe the condition of the objects as captured by sensor devices, such as temperature, pressure or speed. Each sensor element has at most one metadata element and any number of sensor reports. Figure 6 shows the attributes of the How dimension.

Figure 6: Attributes of How dimension.

Sensor Metadata

Sensor metadata is optional. When it is present, it applies to every sensor report within the same sensor element. Its fields include time, start time, end time and device id.

Sensor Report

A sensor report holds one or more attributes describing a sensor reading, for example the temperature, pressure or speed of the objects. It may also include attributes such as time, device id, value and UOM.

Additional attributes

Beyond the five dimensions, EPCIS defines further attributes that may or must appear in an event, depending on the event type. Figure 7 gives an overview of the ones that add meaning to an event.

Figure 7: Additional attributes available in the EPCIS event.

Instance/Lot Master Data (ILMD)

Master data describe a broad group of objects, such as the production location, weight or physical dimensions of all goods with a particular GTIN. ILMD is master data for a smaller group: a single instance of a physical or digital object, or a specific batch or lot. The expiry date is a good example. Weight and size are the same for every item of a GTIN, while the expiry date depends on when an item was produced and therefore applies only to the items made on a particular day or at a particular time.

ILMD can hold any such detail, for instance the production date, the exact manufacturing site or the weight, as long as it applies to the smaller group. Like master data, ILMD is static and does not change over the life of the product; an expiry date, for example, never changes. Data that may change during an object's life therefore does not belong in ILMD. Because ILMD can only be added when the object comes into existence, it appears only in the ObjectEvent and the TransformationEvent.

Action property

The action value describes how an event relates to the life cycle of the object, independently of the business step that was carried out. Every event type except the TransformationEvent must include it. The action takes one of three values, ADD, OBSERVE or DELETE, whatever the event type and process, and the exact meaning of each value depends on the event type.

Transformation ID

The transformation ID exists only in the TransformationEvent and links TransformationEvents together. It is optional. When a value is given, the inputs of all events sharing that value may contribute to the outputs of all events sharing it.

Event identifiers

Event identifiers populate the eventID field of an event. The field is optional, but when it is present it should be globally unique, error declarations being the exception. An eventID can be a UUID (Universally Unique Identifier) or an EPCIS event hash ID. Either value is unique to the event, whether the event is written in XML, JSON or another format. Event hash IDs can be computed with SHA-256 (Secure Hash Algorithm 256) or other hash functions. Here is one example of each form:

urn:uuid:f81d4fae-8efd-22e0-b876-00b0d92e6bf7
ni:///sha-256;c6407ffcac52ec159528f2b556ba4ac3844c5aa48485c1fd61643e94f0a2d678?ver=CBV2.0

Error declaration

Each EPCIS event records a forward step that objects take in a business process, and the sequence of events represents the whole business cycle. Sometimes a recorded event contains wrong information because of a faulty device, physical conditions or an operator error, so the history no longer matches what really happened. The EPCIS standard does not allow existing events to be deleted or modified, since other events and business processes may depend on them. A new event is generated to declare the earlier one erroneous.

Consider this case: Company A records an ObjectEvent with action DELETE for an object with identifier 111, stating that the object has been destroyed. Later it turns out that the object was never destroyed and is still in the warehouse. Since an event with action DELETE already exists, no new events can be created for that identifier. Company A therefore creates an error declaration stating that the object with identifier 111 was not destroyed.

The ErrorDeclaration element marks an event as special: it states that an earlier event is incorrect. The error declaration repeats the information of the original, erroneous event and adds the ErrorDeclaration element, which the original does not have. ErrorDeclaration may contain the following elements:

  • Declaration Time: the date and time at which the error was declared.
  • Reason: an optional field giving the cause of the error.
  • Corrective Event IDs: an optional list of the eventID values of the events that correct the erroneous event.

Terms associated with the EPCIS standard

Two further terms come up throughout EPCIS documents.

Syntax type

Up to EPCIS 1.2, standard vocabulary elements in events were written only as URNs (Uniform Resource Names). EPCIS 2.0 also allows Web URIs (Uniform Resource Identifiers), so every standard vocabulary element from the CBV can be written in either of these syntaxes:

urn:epcglobal:cbv:qualifier:payload
https://ref.gs1.org/cbv/qualifier-payload

The qualifier names the vocabulary type, and the payload names the element within that vocabulary. The business step shipping, for example, looks like this in URN and in Web URI format:

urn:epcglobal:cbv:bizstep:shipping

https://ref.gs1.org/cbv/BizStep-shipping

GS1 Company Prefix (GCP)

An organization that becomes a GS1 member receives a unique identification code, the GCP (GS1 Company Prefix). The GCP is four to twelve digits long and identifies the organization uniquely within GS1. It is the foundation from which the organization builds unique identifiers for its locations (GLN), goods (GTIN), shipments (SSCC) and so on. The following SGTIN EPC URI shows where the GCP sits in a product identifier:

urn:epc:id:sgtin:CompanyPrefix.ItemRefAndIndicator.SerialNumber
urn:epc:id:sgtin:2345678.190123.987

In this example, 2345678 is the GCP assigned to the organization, 90123 is the item reference, 1 is the indicator digit and 987 is the serial number.

Core Business Vocabulary (CBV)

Core Business Vocabulary (CBV) is the data standard that accompanies EPCIS. It supplies the vocabulary elements that fill EPCIS events, so that everyone sharing the data reads it the same way. If each organisation invented its own codes, nobody else could interpret its events.

CBV covers business step, disposition, source and destination type, persistent disposition and sensor elements, across a broad set of industry sectors and their common scenarios. EPCIS does allow user-defined vocabulary, but use CBV wherever it reaches. The GS1 CBV standard is defined in ISO/IEC 19988.

CBV 2.0 was released in June 2022 together with EPCIS 2.0. It adds new vocabulary for fields such as business step, disposition and business transaction type, and it supplies vocabulary for the fields EPCIS 2.0 introduced, such as sensor elements and persistent disposition.

Enhancements in EPCIS 2.0 version

EPCIS 2.0, published in June 2022, is the most recent version and improves significantly on EPCIS 1.2. The main changes, most of which the sections above already touched on, are these:

  • Up to EPCIS 1.2, events could only be written in XML. EPCIS 2.0 allows XML as well as JSON/JSON-LD.
  • Up to EPCIS 1.2, identifiers and vocabulary were written only as URNs. EPCIS 2.0 allows URNs or Web URIs.
  • The new How dimension carries sensor information.
  • The AssociationEvent is a new event type.
  • Persistent Disposition is a new attribute.

EPCIS 2.0 contains several further improvements, which the official GS1 EPCIS 2.0 specification describes in detail.

Example of an EPCIS event

The following listings show a simple EPCIS ObjectEvent, first in JSON/JSON-LD and then in XML. The event belongs to a shipping step and contains one instance-level object and one class-level identifier. It fills four dimensions with fields such as recordTime, eventTime, readPoint, source and destination. The XML version writes identifiers and standard vocabulary as URNs, while the JSON/JSON-LD version uses the Web URI format.

EPCIS event in JSON/JSON-LD format:

EPCIS 2.0 Event in JSON/JSON_LD Format.json
  {
    "@context": [
      "https://ref.gs1.org/standards/epcis/epcis-context.jsonld"
    ],
    "type": "ObjectEvent",
    "eventTime": "2022-05-01T08:10:10Z",
    "recordTime": "2022-05-16T13:03:43.010235Z",
    "eventTimeZoneOffset": "+02:00",
    "eventID": "urn:uuid:aed0c443-7be2-4b64-8fd6-972ca76ef2c2",
    "epcList": [
      "urn:epc:id:sgtin:7547845584.887.100"
    ],
    "action": "ADD",
    "bizStep": "shipping",
    "disposition": "in_transit",
    "readPoint": {
      "id": "urn:epc:id:sgln:7587875478.45.10"
    },
    "bizLocation": {
      "id": "urn:epc:id:sgln:8577747457.85.20"
    },
    "quantityList": [{
      "epcClass": "urn:epc:class:lgtin:6456675455.645.200",
      "quantity": 100,
      "uom": "KGM"
    }],
    "sourceList": [{
      "type": "owning_party",
      "source": "urn:epc:id:sgln:5747587485.84.100"
    }],
    "destinationList": [{
      "type": "possessing_party",
      "destination": "urn:epc:id:sgln:7854785487.45.200"
    }]
  }

EPCIS event in XML format:

EPCIS 2.0 Event in XML Format.xml
<ObjectEvent>
  <eventTime>2022-05-01T08:10:10Z</eventTime>
  <recordTime>2022-05-16T13:03:43.01Z</recordTime>
  <eventTimeZoneOffset>+02:00</eventTimeZoneOffset>
  <eventID>urn:uuid:aed0c443-7be2-4b64-8fd6-972ca76ef2c2</eventID>
  <epcList>
    <epc>urn:epc:id:sgtin:7547845584.887.100</epc>
  </epcList>
  <action>ADD</action>
  <bizStep>urn:epcglobal:cbv:bizstep:shipping</bizStep>
  <disposition>urn:epcglobal:cbv:disp:in_transit</disposition>
  <readPoint>
    <id>urn:epc:id:sgln:7587875478.45.10</id>
  </readPoint>
  <bizLocation>
    <id>urn:epc:id:sgln:8577747457.85.20</id>
  </bizLocation>
  <quantityList>
    <quantityElement>
      <epcClass>urn:epc:class:lgtin:6456675455.645.200</epcClass>
      <quantity>100.0</quantity>
      <uom>KGM</uom>
    </quantityElement>
  </quantityList>
  <sourceList>
    <source type="urn:epcglobal:cbv:sdt:owning_party">urn:epc:id:sgln:5747587485.84.100</source>
  </sourceList>
  <destinationList>
    <destination type="urn:epcglobal:cbv:sdt:possessing_party">urn:epc:id:sgln:7854785487.45.200</destination>
  </destinationList>
</ObjectEvent>

OpenEPCIS

OpenEPCIS is developed by benelog GmbH & Co. KG, a software and system-architecture company based in Cologne, Germany. The benelog team contributed to the GS1 working groups that standardized EPCIS 2.0 and continues to work on EPCIS implementations in production environments. Several open-source tools and libraries around the EPCIS standard are published as part of that work, and the rest of this documentation covers them in detail.

EPCIS documents can contain thousands or millions of events, so the OpenEPCIS components stream-process documents with bounded memory. The tools come as REST endpoints, command-line utilities and JVM libraries, and integrators can use whichever fits their stack best.

If your organization needs a full EPCIS 2.0 implementation with 1.2 round-trip support, OpenEPCIS is a complete starting point. The standards-conformant building blocks are open source under Apache 2.0, and benelog provides a commercially supported business edition with the multi-tenant runtime, AS2/B2B gateways, storage backends and operational tooling.

Contact

We are happy to talk if you have questions or suggestions, or if you would like to work with us on a project. Send us an email at info@openepcis.io.