S10 (UPU standard)

Last updated
The 13-character identifier for a package. It starts with the service indicator for registered mail ("RR"), followed by an 8-digit serial number (28704377), the check-digit (5) and the two-letter ISO country code for the issuing country, India ("IN") RegisteredMailBarcode (cropped).jpg
The 13-character identifier for a package. It starts with the service indicator for registered mail ("RR"), followed by an 8-digit serial number (28704377), the check-digit (5) and the two-letter ISO country code for the issuing country, India ("IN")

The UPU S10 standard defines a system for assigning 13-character identifiers to international postal items for the purpose of tracking and tracing them during shipping.

Contents

With increased liberalization and the possibility of multiple postal services operating in the same country, the use of country codes to designate the postal service is a problem. To solve this, each country has a designated postal service that controls all S10 identifiers from that country; any competing postal services will have to cooperate with the designated owner. The organization assigned by the UPU member country shall manage the issue and use of S10 identifiers, among all the operators under the authority of that UPU member country, in such a way as to ensure that no S10 identifier is reused within a period of 12 calendar months. A period of 24 calendar months, or longer, is recommended.

Format

The identifiers consist of a two-letter service indicator code, an eight-digit serial number (in the range 00000000 to 99999999), a single check-digit, and a two-letter ISO country code identifying the issuing postal administration's country. [1]

S10 format
1234
AA000000009BB
  1. Service indicator code (see below)
  2. Serial number
  3. Check-digit (see below)
  4. ISO 3166-1 alpha-2 country code

Service indicator codes

Service codes are generally assigned and administered within each issuing country, but certain types of service and code ranges are used for all countries as listed here.

CodeInterpretation [1]
AA–AUUnassigned [lower-alpha 1]
AV–AZDomestic, bilateral, multilateral use only [lower-alpha 2]
BA–BZDomestic, bilateral, multilateral use only
CA–CZ Parcel post
  • The use of CV is recommended (though not required) for insured parcels [lower-alpha 3]
  • The use of CZ requires bilateral agreement
DA–DZDomestic, bilateral, multilateral use only
EA–EZ EMS
  • The use of EX–EZ requires bilateral agreement
FA–FZUnassigned [lower-alpha 1]
GADomestic, bilateral, multilateral use only
GB–GCUnassigned [lower-alpha 1]
GDDomestic, bilateral, multilateral use only
GE–GZUnassigned [lower-alpha 1]
HA–HZE-commerce parcels
  • The use of HX–HY requires multilateral agreement
  • The use of HZ requires bilateral agreement
IA–IZUnassigned [lower-alpha 1]
JA–JZReserved [lower-alpha 4]
KA–KZReserved [lower-alpha 4]
LA–LZLetter post tracked
  • The use of LZ requires bilateral agreement
MA–MZLetter post M bags
NA–NZDomestic, bilateral, multilateral use only
OA–OZUnassigned [lower-alpha 1]
PA–PZDomestic, bilateral, multilateral use only
QA–QM International Business Reply Service
QN–QZUnassigned [lower-alpha 1]
RA–RZ Letter post registered
  • The use of RZ requires bilateral agreement.
SA–SZReserved [lower-alpha 4]
TA–TZReserved [lower-alpha 4]
UA–UZLetter post items (when L, M, Q, R and V codes don't apply) [lower-alpha 5]
  • The use of UZ requires bilateral agreement
VA–VZLetter post insured
  • The use of VZ requires bilateral agreement
WA–WZReserved [lower-alpha 4]
XA–XZUnassigned [lower-alpha 1]
YA–YZUnassigned [lower-alpha 1]
ZA–ZZDomestic, bilateral, multilateral use only

Check-digit calculation

  1. Ignore the service indicator code and country code.
  2. Assign the weights 8, 6, 4, 2, 3, 5, 9, 7 to the 8 digits, from left to right.
  3. Calculate S, the sum of each digit multiplied by its weight.
    • For example, for the number 47312482: S = 4×8 + 7×6 + 3×4 + 1×2 + 2×3 + 4×5 + 8×9 + 2×7 = 200.
  4. Calculate the check digit C = 11 − (S mod 11).
    • If C = 10, change to C = 0.
    • If C = 11, change to C = 5.
    • For the example 47312482, C = 11 − (200 mod 11) = 11 − 2 = 9.

Python code for check-digit calculation

For Python 3.6 or later:

defget_check_digit(num:int)->int:"""Get S10 check digit."""weights=[8,6,4,2,3,5,9,7]sum=0fori,digitinenumerate(f"{num:08}"):sum+=weights[i]*int(digit)sum=11-(sum%11)ifsum==10:sum=0elifsum==11:sum=5returnsum

JavaScript code for check-digit calculation

functiongetCheckDigit(num){constweights=[8,6,4,2,3,5,9,7];constnumArr=Array.from(String(num),Number);letsum=0;numArr.forEach((n,i)=>sum=sum+(n*weights[i]));sum=11-(sum%11);if(sum==10)sum=0;elseif(sum==11)sum=5;returnsum;}

Haskell code for check-digit calculation

checkDigit::[Int]->IntcheckDigitns|c==11=5|c==10=0|otherwise=cwhereweights=[8,6,4,2,3,5,9,7]s=sum$zipWith(*)weightsnsc=11-(s`mod`11)

See also

Notes

  1. 1 2 3 4 5 6 7 8 9 "Any combinations of two alphabetic characters that are not yet assigned for universal use, nor allocated for exclusively domestic/bilateral/multilateral use, may be assigned under the authority of the UPU's Standards Board" (p.2) [1]
  2. "In principle, the use of code range AV–AZ is to identify RFID-tracked items." (p.4) [1]
  3. "Thus: a) insured parcels might have a service indicator other than CV; and b) service indicator CV does not necessarily imply that the parcel is an insured one." (p.4) [1]
  4. 1 2 3 4 5 "To reduce the risk of confusion between S10 identifier barcodes and barcodes which make use of ISO/IEC 15418 data identifiers, character combinations JA–JZ; KA–KZ; SA–SZ; TA–TZ and WA–WZ are reserved and cannot be assigned as valid service indicator values." (p.2) [1]
  5. "The use of code range UA–UZ is for letter-post items containing goods requiring an S10 identifier and without customer-oriented tracking. The identifier is used for visibility in the supply chain, for example in an ITMATT message for electronic advance data." (p.4) [1]

Related Research Articles

<span class="mw-page-title-main">ISBN</span> Unique numeric book identifier since 1970

The International Standard Book Number (ISBN) is a numeric commercial book identifier that is intended to be unique. Publishers purchase or receive ISBNs from an affiliate of the International ISBN Agency.

<span class="mw-page-title-main">International Bank Account Number</span> Alphanumeric code that uniquely identifies a bank account in any participating country

The International Bank Account Number (IBAN) is an internationally agreed upon system of identifying bank accounts across national borders to facilitate the communication and processing of cross border transactions with a reduced risk of transcription errors. An IBAN uniquely identifies the account of a customer at a financial institution. It was originally adopted by the European Committee for Banking Standards (ECBS) and since 1997 as the international standard ISO 13616 under the International Organization for Standardization (ISO). The current version is ISO 13616:2020, which indicates the Society for Worldwide Interbank Financial Telecommunication (SWIFT) as the formal registrar. Initially developed to facilitate payments within the European Union, it has been implemented by most European countries and numerous countries in other parts of the world, mainly in the Middle East and the Caribbean. By July 2023, 86 countries were using the IBAN numbering system.

<span class="mw-page-title-main">Universal Product Code</span> Barcode symbology used for tracking trade items in stores

The Universal Product Code is a barcode symbology that is used worldwide for tracking trade items in stores.

<span class="mw-page-title-main">ISSN</span> Serial number used to identify a periodical publication

An International Standard Serial Number (ISSN) is an eight-digit serial number used to uniquely identify a serial publication (periodical), such as a magazine. The ISSN is especially helpful in distinguishing between serials with the same title. ISSNs are used in ordering, cataloging, interlibrary loans, and other practices in connection with serial literature.

An International Securities Identification Number (ISIN) is a code that uniquely identifies a security globally for the purposes of facilitating clearing, reporting and settlement of trades. Its structure is defined in ISO 6166. The ISIN code is a 12-character alphanumeric code that serves for uniform identification of a security through normalization of the assigned National Number, where one exists, at trading and settlement.

<span class="mw-page-title-main">Code 39</span> Variable length, discrete barcode symbology

Code 39 is a variable length, discrete barcode symbology defined in ISO/IEC 16388:2007.

POSTNET is a barcode symbology used by the United States Postal Service to assist in directing mail. The ZIP Code or ZIP+4 code is encoded in half- and full-height bars. Most often, the delivery point is added, usually being the last two digits of the address or PO box number.

A check digit is a form of redundancy check used for error detection on identification numbers, such as bank account numbers, which are used in an application where they will at least sometimes be input manually. It is analogous to a binary parity bit used to check for errors in computer-generated data. It consists of one or more digits computed by an algorithm from the other digits in the sequence input.

The Luhn algorithm or Luhn formula, also known as the "modulus 10" or "mod 10" algorithm, named after its creator, IBM scientist Hans Peter Luhn, is a simple check digit formula used to validate a variety of identification numbers. It is described in U.S. Patent No. 2,950,048, granted on August 23, 1960.

In the United States, an ABA routing transit number is a nine-digit code printed on the bottom of checks to identify the financial institution on which it was drawn. The American Bankers Association (ABA) developed the system in 1910 to facilitate the sorting, bundling, and delivering of paper checks to the drawer's bank for debit to the drawer's account.

SEDOL stands for Stock Exchange Daily Official List, a list of security identifiers used in the United Kingdom and Ireland for clearing purposes. The numbers are assigned by the London Stock Exchange, on request by the security issuer. SEDOLs serve as the National Securities Identifying Number for all securities issued in the United Kingdom and are therefore part of the security's ISIN as well. The SEDOL Masterfile (SMF) provides reference data on millions of global multi-asset securities each uniquely identified at the market level using a universal SEDOL code.

A CUSIP is a nine-character numeric or alphanumeric code that uniquely identifies a North American financial security for the purposes of facilitating clearing and settlement of trades. All CUSIP identifiers are fungible, which means that a unique CUSIP identifier for each individual security stays the same, regardless of the exchange where the shares were purchased or venue on which the shares were traded. CUSIP was adopted as an American national standard by the Accredited Standards Committee X9 and is designated ANSI X9.6. CUSIP was re-approved as an ANSI standard in December 2020. The acronym derives from Committee on Uniform Security Identification Procedures.

<span class="mw-page-title-main">International Standard Music Number</span> Identifier for printed music developed by ISO

The International Standard Music Number or ISMN is a thirteen-character alphanumeric identifier for printed music developed by ISO.

In some programming languages, const is a type qualifier, which indicates that the data is read-only. While this can be used to declare constants, const in the C family of languages differs from similar constructs in other languages in that it is part of the type, and thus has complicated behavior when combined with pointers, references, composite data types, and type-checking. In other languages, the data is not in a single memory location, but copied at compile time for each use. Languages which use it include C, C++, D, JavaScript, Julia, and Rust.

<span class="mw-page-title-main">Express mail</span> Accelerated mail delivery service

Express mail is an expedited mail delivery service for which the customer pays a premium for faster delivery. Express mail is a service for domestic and international mail, and is in most nations governed by the country's own postal administration. Since 1999, the international express delivery services are governed by the EMS Cooperative.

<span class="mw-page-title-main">International Article Number</span> Standard barcode system used in global trade

The International Article Number is a standard describing a barcode symbology and numbering system used in global trade to identify a specific retail product type, in a specific packaging configuration, from a specific manufacturer. The standard has been subsumed in the Global Trade Item Number standard from the GS1 organization; the same numbers can be referred to as GTINs and can be encoded in other barcode symbologies defined by GS1. EAN barcodes are used worldwide for lookup at retail point of sale, but can also be used as numbers for other purposes such as wholesale ordering or accounting. These barcodes only represent the digits 0–9, unlike some other barcode symbologies which can represent additional characters.

In number theory, a narcissistic number in a given number base is a number that is the sum of its own digits each raised to the power of the number of digits.

The Luhn mod N algorithm is an extension to the Luhn algorithm that allows it to work with sequences of values in any even-numbered base. This can be useful when a check digit is required to validate an identification string composed of letters, a combination of letters and digits or any arbitrary set of N characters where N is divisible by 2.

<span class="mw-page-title-main">MSI Barcode</span> Barcode symbology

MSI is a barcode symbology developed by the MSI Data Corporation, based on the original Plessey Code symbology. It is a continuous symbology that is not self-checking. MSI is used primarily for inventory control, marking storage containers and shelves in warehouse environments.

Tracking numbers are numbers assigned to packages when they are shipped. Tracking numbers are useful for knowing the location of time sensitive deliveries. It is a unique ID number or code assigned to a package or parcel. The tracking number is typically printed on the shipping label as a bar code that can be scanned by anyone with a bar code reader or smartphone.

References

  1. 1 2 3 4 5 6 7 "S10 Identification of postal items – 13-character identifier" (PDF). UPU. 2017-10-17. Retrieved 2024-03-05.