Fetch only. This package fetches and parses the list. It does not screen names and it stores nothing. List data alone is not a clearance decision.
The UK Sanctions List published by the FCDO (uk), the single
source of UK designations since the OFSI Consolidated List closed on
28 January 2026. About 6,400 designations: individuals, entities and
ships.
Format used: the XML file
(https://sanctionslist.fcdo.gov.uk/docs/UK-Sanctions-List.xml,
about 22 MB; the CSV is about 50 MB because it repeats every field
per name). It is larger than the default 16 MiB response cap, so it
is downloaded in 8 MiB Range requests, which the server supports.
Change detection uses its ETag: current-version reads it without
downloading the list, and fetch skips the download when you pass
the version you already hold.
Example
out ::uk::sanctions/fetch()
out.version
first(out.entries).name
Values
LIST_NAME
LIST_NAME: Str "UK Sanctions List"
MONTHS
MONTHS: Map {
jan: "01",
feb: "02",
mar: "03",
apr: "04",
may: "05",
jun: "06",
jul: "07",
aug: "08",
sep: "09",
oct: "10",
nov: "11",
dec: "12"
}
URL
URL: Str "https://sanctionslist.fcdo.gov.uk/docs/UK-Sanctions-List.xml"
Functions
address-line
fn (address: Str): Str
blank-to-null
fn (v: Any): Str?
clean-list
fn (values: Vec): Vec<Str>
Trim strings, drop blanks and duplicates, keep the first-seen order.
current-version
fn (): Str?
The list's current version from one HEAD request, without downloading the list: its ETag, or Last-Modified. Compare it with the version you hold to skip a download. Null when the server sends neither, an Err when the request fails.
Example
::uk::sanctions/current-version()
fetch
fn (): Map
fn (known-version: Str?): Map
Download and parse the UK list. Returns {version, entries, unchanged}, with Designation records in entries.
known-version is the version you already hold: when the HEAD ETag
(or Last-Modified) equals it, nothing is downloaded, unchanged is
true and entries is null. A list that parses to no records is an
Err.
Example
out ::uk::sanctions/fetch()
again ::uk::sanctions/fetch(out.version)
again.unchanged
full-name
fn (name: Str): Str
iso-date
fn (raw: Str?): Str?
Normalize one published date of birth to ISO 8601, or null when it
has no year. Accepts 1948-12-10, 10 Dec 1948, Dec 1948,
1948, circa 1948, 10/12/1948 and dd/mm/1948 (day
first), and ranges such as 1959 to 1962 or 01 Jan 1960 to 31 Dec 1962 (1959/1962, 1960/1962).
Example
::uk::sanctions/iso-date("10 Dec 1948") // "1948-12-10"
::uk::sanctions/iso-date("dd/mm/1963") // "1963"
::uk::sanctions/iso-date("1959 to 1962") // "1959/1962"
kind
fn (raw: Str?): Str
other-names
fn (aliases: Vec, name: Str): Vec<Str>
Cleaned aliases without the primary name, ignoring case.
pad2
fn (s: Str): Str
parse
fn (doc: Str): Vec<Designation>
Parse the whole UK Sanctions List XML into Designation records (pure). Records without a name or id are skipped.
parse-designation
fn (record: Str): Designation
Turn one <Designation> record string into a Designation. Exposed for testing.
present
fn (v: Any): Bool
require-entries
fn (entries: Vec): Vec
The parsed records, or an Err when there are none: a changed file format can parse to nothing, and an empty list must not pass for a list with nobody on it.
version-of
fn (info: Map): Str?
Types
Designation
Designation type {
id: Str,
kind: DesignationKind,
name: Str,
aliases: Vec<Str>,
dobs: Vec<Str>,
nationalities: Vec<Str>,
regimes: Vec<Str>,
addresses: Vec<Str>,
other-information: Str?,
designation-source: Str?,
un-reference: Str?,
ofsi-group-id: Str?,
date-designated: Str?,
last-updated: Str?,
url: Str
}
One designation, as the UK Sanctions List XML publishes it.
Fields
id— theUniqueIDkind— aDesignationKindname— the primary name, itsName1toName6parts joinedaliases— every other name, then the non-Latin namesdobs— dates of birth as ISO 8601:YYYY-MM-DD,YYYY-MMorYYYY(dd/mm/1963is"1963")nationalities— as publishedregimes— the sanctions regime namesaddresses— one line per addressother-information— theOtherInformationtextdesignation-source— who designated it, e.g."UN"un-reference— theUNReferenceNumberofsi-group-id— theOFSIGroupIDdate-designated,last-updated— as published (dd/mm/yyyy)url— the list file
DesignationKind
DesignationKind type "individual" | "entity" | "vessel"
What is designated. The list says Individual, Entity or Ship, and a ship is "vessel" here.