AWS clients
All AWS access goes through these wrappers. Table shapes are in DynamoDB tables; S3 key conventions in S3 datalake.
DynamoDB
Every client uses boto3.resource('dynamodb') and a table name from settings.
| File | Table setting | Role |
|---|---|---|
|
|
Task lifecycle. |
|
|
Verdicts per |
|
|
Per-supplier/person tool state. |
|
|
Append-only audit. |
FinalStatusTable and ToolTable both take a ChangelogTable in their constructor — that is
how auditing is guaranteed rather than remembered.
Enums and exceptions
| Module | Contents |
|---|---|
|
|
|
|
|
|
class ToolType(Enum):
THOMSON_REUTERS_CLEAR_ID = 'Thomson Reuters Clear ID (KYC Check)'
THOMSON_REUTERS_PERSONAL_BACKGROUND_REPORT = 'Thomson Reuters Personal Background Report'
AU10TIX = 'Au10tix'
ENTRUST = 'Entrust Identity Verification'
@staticmethod
def get_by_process_name(process_name: str) -> 'ToolType':
supported_processes = {
Process.VALIDATE_IDENTITY_DOCUMENT: ToolType.AU10TIX,
Process.VALIDATE_PERSONAL_INFORMATION: ToolType.THOMSON_REUTERS_CLEAR_ID,
Process.DOWNLOAD_PERSONAL_BACKGROUND_REPORT: ToolType.THOMSON_REUTERS_PERSONAL_BACKGROUND_REPORT
}
try:
return supported_processes[process_name]
except KeyError:
raise NotSupportedToolType(process_name=process_name)
|
Au10tix / Entrust coexistence. Entrust Identity Verification (Onfido) is the eventual
replacement for Au10tix identity-document validation. During the rollout both vendors run
under the same |
ToolTable.SUPPORTED_TOOLS does include ENTRUST, so GET /tools auto-creates an Entrust row
(status NOT_RUN) for every supplier/person it is asked about. Only the process → tool mapping
still points at Au10tix.
S3
| File | Contents |
|---|---|
|
|
|
|
|
|
Implemented by the three Thomson Reuters handle tasks and driven by
DELETE /tasks/result.
SWF (worker side)
components/swf_client.py — a boto3.client('swf') activity worker.
| Method | Behaviour |
|---|---|
|
Loops on |
|
|
|
|
EventBridge
| File | Contents |
|---|---|
|
Base |
|
|
|
|
Catalog and payloads: EventBridge events.
CloudWatch
Not a components/ client: utils/metric_utils.py wraps pyb-sdk’s
`CriticalMetricNamespace. See Observability.
IAM surface
The two ECS task roles need, at minimum: DynamoDB read/write on the four tables and the
supplier_key-process_name-index GSI; s3:PutObject/GetObject/DeleteObject on the datalake
bucket; SWF poll and respond on the domain and task list (worker); events:PutEvents on the
bus; and CloudWatch PutMetricData. Secrets Manager access is only needed at build time by
config_setup.py.