Currently the asset movement anchor returns a flat array of KYC attributes:
[
"entityType",
"firstName",
"lastName",
"dateOfBirth",
"address",
"nationality",
"middleName",
"documentDriversLicense",
"documentIdCard",
"documentPassport",
"documentPassportCard",
"documentVisa",
"documentResidenceDocument"
]
We need to option to mark an attribute as optional e.g. the middleName as well as bundling several attributes into a choice e.g. documentPassport or documentPassportCard or etc.
Proposal for a new type:
type AttributeRequirement =
| { kind: "required"; name: string }
| { kind: "optional"; name: string }
| { kind: "oneOf"; names: string[] };
The new response could look as follows:
[
{ "kind": "required", "name": "entityType" },
{ "kind": "required", "name": "firstName" },
{ "kind": "optional", "name": "middleName" },
{ "kind": "required", "name": "lastName" },
{ "kind": "required", "name": "dateOfBirth" },
{ "kind": "required", "name": "address" },
{ "kind": "required", "name": "nationality" },
{ "kind": "oneOf", "names": ["documentPassport", "documentPassportCard", "documentDriversLicense", "documentIdCard", "documentVisa",
"documentResidenceDocument"] }
]
Currently the asset movement anchor returns a flat array of KYC attributes:
We need to option to mark an attribute as optional e.g. the
middleNameas well as bundling several attributes into a choice e.g.documentPassportordocumentPassportCardor etc.Proposal for a new type:
The new response could look as follows: