@didit-protocol/sdk-node 2.15.0 → 2.17.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.cjs +106 -6
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +264 -31
- package/dist/index.d.ts +264 -31
- package/dist/index.js +106 -6
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -324,7 +324,7 @@ function decodeDates(value, plan, named, depth = 0) {
|
|
|
324
324
|
}
|
|
325
325
|
|
|
326
326
|
// src/core/version.ts
|
|
327
|
-
var VERSION = "2.
|
|
327
|
+
var VERSION = "2.17.0";
|
|
328
328
|
|
|
329
329
|
// src/core/runtime.ts
|
|
330
330
|
function processLike() {
|
|
@@ -1746,6 +1746,7 @@ var DATE_PLANS = {
|
|
|
1746
1746
|
},
|
|
1747
1747
|
TransactionsNotesListResponse: { p: { results: { i: "TransactionNote" } } },
|
|
1748
1748
|
TransactionsRulesListResponse: { p: { results: { i: "TransactionRuleDetail" } } },
|
|
1749
|
+
TravelRuleAssignVaspResponse: { p: { assignee: "TravelRuleVaspAssignee" } },
|
|
1749
1750
|
TravelRuleCounterpartyContact: { p: { verified_at: 1, invalid_at: 1, created_at: 1 } },
|
|
1750
1751
|
TravelRuleCounterpartyContactsListResponse: {
|
|
1751
1752
|
p: { results: { i: "TravelRuleCounterpartyContact" } }
|
|
@@ -1758,12 +1759,16 @@ var DATE_PLANS = {
|
|
|
1758
1759
|
TravelRuleCounterpartyQuestionnaireList: {
|
|
1759
1760
|
p: { questionnaires: { i: "TravelRuleCounterpartyQuestionnaire" } }
|
|
1760
1761
|
},
|
|
1761
|
-
TravelRuleCounterpartyScreening: {
|
|
1762
|
+
TravelRuleCounterpartyScreening: {
|
|
1763
|
+
p: { screened_at: 1, hits: { i: { p: { review: { p: { reviewed_at: 1 } } } } } }
|
|
1764
|
+
},
|
|
1762
1765
|
TravelRuleCounterpartyScreeningResult: { p: { screening: "TravelRuleCounterpartyScreening" } },
|
|
1763
1766
|
TravelRuleCounterpartyScreeningStatus: { p: { screening: "TravelRuleCounterpartyScreening" } },
|
|
1764
1767
|
TravelRuleDataUnmasked: { p: { at: 1 } },
|
|
1765
|
-
TravelRuleDelivery: { p: { next_attempt_at: 1, delivered_at: 1 } },
|
|
1766
|
-
TravelRuleDeliveryLogEntry: {
|
|
1768
|
+
TravelRuleDelivery: { p: { next_attempt_at: 1, delivered_at: 1, updated_at: 1 } },
|
|
1769
|
+
TravelRuleDeliveryLogEntry: {
|
|
1770
|
+
p: { created_at: 1, delivered_at: 1, updated_at: 1, next_attempt_at: 1 }
|
|
1771
|
+
},
|
|
1767
1772
|
TravelRuleDeliveryLogPage: { p: { results: { i: "TravelRuleDeliveryLogEntry" } } },
|
|
1768
1773
|
TravelRuleDiscoveryStep: { p: { at: 1 } },
|
|
1769
1774
|
TravelRuleInboundResponse: { p: { travel_rule: "TravelRuleTransferDetail" } },
|
|
@@ -1803,6 +1808,7 @@ var DATE_PLANS = {
|
|
|
1803
1808
|
}
|
|
1804
1809
|
}
|
|
1805
1810
|
},
|
|
1811
|
+
TravelRuleReviewVaspScreeningHitResponse: { p: { screening: "TravelRuleCounterpartyScreening" } },
|
|
1806
1812
|
TravelRuleSettingsDetail: {
|
|
1807
1813
|
p: {
|
|
1808
1814
|
networks: {
|
|
@@ -1834,9 +1840,14 @@ var DATE_PLANS = {
|
|
|
1834
1840
|
TravelRuleUnmatchedDepositsListResponse: { p: { results: { i: "TravelRuleTransferRow" } } },
|
|
1835
1841
|
TravelRuleUserChoice: { p: { link_expires_at: 1 } },
|
|
1836
1842
|
TravelRuleUserLinkResponse: { p: { expires_at: 1 } },
|
|
1843
|
+
TravelRuleVaspAssignee: { p: { assigned_at: 1 } },
|
|
1837
1844
|
TravelRuleWalletAddressesListResponse: { p: { results: { i: "WalletAddressEntry" } } },
|
|
1845
|
+
TravelRuleWalletAddressesListTransfersResponse: {
|
|
1846
|
+
p: { results: { i: "TravelRuleWalletTransfer" } }
|
|
1847
|
+
},
|
|
1838
1848
|
TravelRuleWalletProofReview: { p: { method_chosen_at: 1, decided_at: 1, created_at: 1 } },
|
|
1839
1849
|
TravelRuleWalletProofsListResponse: { p: { results: { i: "TravelRuleWalletProofReview" } } },
|
|
1850
|
+
TravelRuleWalletTransfer: { p: { created_at: 1 } },
|
|
1840
1851
|
TravelRuleWidgetSessionResponse: { p: { expires_at: 1 } },
|
|
1841
1852
|
TravelRuleWorkspace: {
|
|
1842
1853
|
p: {
|
|
@@ -1886,7 +1897,8 @@ var DATE_PLANS = {
|
|
|
1886
1897
|
essential_checks: { p: { checked_at: 1 } },
|
|
1887
1898
|
decision: "TravelRuleCounterpartyDecision",
|
|
1888
1899
|
entity_screening: "TravelRuleCounterpartyScreening",
|
|
1889
|
-
questionnaires: { i: "TravelRuleCounterpartyQuestionnaire" }
|
|
1900
|
+
questionnaires: { i: "TravelRuleCounterpartyQuestionnaire" },
|
|
1901
|
+
assignee: "TravelRuleVaspAssignee"
|
|
1890
1902
|
}
|
|
1891
1903
|
},
|
|
1892
1904
|
WalletAddressEntry: { p: { created_at: 1 } },
|
|
@@ -8706,6 +8718,17 @@ var TRAVEL_RULE_WALLET_ADDRESSES_LIST = {
|
|
|
8706
8718
|
query: ["limit", "offset"],
|
|
8707
8719
|
dates: { p: { results: { i: "WalletAddressEntry" } } }
|
|
8708
8720
|
};
|
|
8721
|
+
var TRAVEL_RULE_WALLET_ADDRESSES_LIST_TRANSFERS = {
|
|
8722
|
+
method: "GET",
|
|
8723
|
+
path: "/v3/travel-rule/wallet-addresses/{entry_uuid}/transfers/",
|
|
8724
|
+
query: ["limit", "offset"],
|
|
8725
|
+
dates: { p: { results: { i: "TravelRuleWalletTransfer" } } }
|
|
8726
|
+
};
|
|
8727
|
+
var TRAVEL_RULE_WALLET_ADDRESSES_LOOKUP = {
|
|
8728
|
+
method: "GET",
|
|
8729
|
+
path: "/v3/travel-rule/wallet-addresses/lookup/",
|
|
8730
|
+
query: ["address", "chain", "memo"]
|
|
8731
|
+
};
|
|
8709
8732
|
var TRAVEL_RULE_WALLET_ADDRESSES_UPDATE = {
|
|
8710
8733
|
method: "PATCH",
|
|
8711
8734
|
path: "/v3/travel-rule/wallet-addresses/{entry_uuid}/",
|
|
@@ -8755,6 +8778,12 @@ var TRAVEL_RULE_WORKSPACE_VERIFY_DOMAIN_DNS = {
|
|
|
8755
8778
|
path: "/v3/travel-rule/workspace/domain/dns/",
|
|
8756
8779
|
dates: "TravelRuleWorkspace"
|
|
8757
8780
|
};
|
|
8781
|
+
var TRAVEL_RULE_ASSIGN_VASP = {
|
|
8782
|
+
method: "POST",
|
|
8783
|
+
path: "/v3/travel-rule/vasps/{vasp_id}/assign/",
|
|
8784
|
+
body: "json",
|
|
8785
|
+
dates: { p: { assignee: "TravelRuleVaspAssignee" } }
|
|
8786
|
+
};
|
|
8758
8787
|
var TRAVEL_RULE_CLEAR_VASP_DECISION = {
|
|
8759
8788
|
method: "DELETE",
|
|
8760
8789
|
path: "/v3/travel-rule/vasps/{vasp_id}/decision/",
|
|
@@ -8777,6 +8806,10 @@ var TRAVEL_RULE_LIST_VASP_QUESTIONNAIRES = {
|
|
|
8777
8806
|
path: "/v3/travel-rule/vasps/{vasp_id}/questionnaires/",
|
|
8778
8807
|
dates: "TravelRuleCounterpartyQuestionnaireList"
|
|
8779
8808
|
};
|
|
8809
|
+
var TRAVEL_RULE_LIST_VASP_REVIEWERS = {
|
|
8810
|
+
method: "GET",
|
|
8811
|
+
path: "/v3/travel-rule/vasps/reviewers/"
|
|
8812
|
+
};
|
|
8780
8813
|
var TRAVEL_RULE_LIST_VASPS = {
|
|
8781
8814
|
method: "GET",
|
|
8782
8815
|
path: "/v3/travel-rule/vasps/",
|
|
@@ -8819,6 +8852,12 @@ var TRAVEL_RULE_RETRIEVE_VASP_SCREENING = {
|
|
|
8819
8852
|
path: "/v3/travel-rule/vasps/{vasp_id}/screening/",
|
|
8820
8853
|
dates: "TravelRuleCounterpartyScreeningStatus"
|
|
8821
8854
|
};
|
|
8855
|
+
var TRAVEL_RULE_REVIEW_VASP_SCREENING_HIT = {
|
|
8856
|
+
method: "PATCH",
|
|
8857
|
+
path: "/v3/travel-rule/vasps/{vasp_id}/screening/",
|
|
8858
|
+
body: "json",
|
|
8859
|
+
dates: { p: { screening: "TravelRuleCounterpartyScreening" } }
|
|
8860
|
+
};
|
|
8822
8861
|
var TRAVEL_RULE_SCREEN_VASP = {
|
|
8823
8862
|
method: "POST",
|
|
8824
8863
|
path: "/v3/travel-rule/vasps/{vasp_id}/screening/",
|
|
@@ -8949,7 +8988,7 @@ var TravelRuleTransfers = class extends APIResource {
|
|
|
8949
8988
|
/**
|
|
8950
8989
|
* List Travel Rule transfers
|
|
8951
8990
|
*
|
|
8952
|
-
* Your application's Travel Rule transfers, newest first, paginated with `limit` (default 50) and `offset`. Rows carry VASP names, wallets
|
|
8991
|
+
* Your application's Travel Rule transfers, newest first, paginated with `limit` (default 50) and `offset`. Rows carry VASP names, wallets, memos, the transaction's review decision, your own end user's name (masked exactly as the transaction detail masks it), the counterparty VASP's jurisdiction, the chain and the fiat amount; they never carry the counterparty's person data. Comma-separated values select several. An unknown value answers 400 naming the parameter, for example `{"direction": ["Unknown value(s): inbound."]}`.
|
|
8953
8992
|
*
|
|
8954
8993
|
* `GET /v3/travel-rule/transfers/`
|
|
8955
8994
|
*/
|
|
@@ -9034,6 +9073,33 @@ var TravelRuleWalletAddresses = class extends APIResource {
|
|
|
9034
9073
|
list(params = {}, options) {
|
|
9035
9074
|
return this._client.requestPage(TRAVEL_RULE_WALLET_ADDRESSES_LIST, [], params, options);
|
|
9036
9075
|
}
|
|
9076
|
+
/**
|
|
9077
|
+
* List the transfers that used a wallet address
|
|
9078
|
+
*
|
|
9079
|
+
* Paginated list of your Travel Rule transfers whose originator or beneficiary wallet is this address book entry, newest first. The endpoint answers 404 once the entry is deleted.
|
|
9080
|
+
*
|
|
9081
|
+
* `GET /v3/travel-rule/wallet-addresses/{entry_uuid}/transfers/`
|
|
9082
|
+
*
|
|
9083
|
+
* @param entryUuid entry_uuid
|
|
9084
|
+
*/
|
|
9085
|
+
listTransfers(entryUuid, params = {}, options) {
|
|
9086
|
+
return this._client.requestPage(
|
|
9087
|
+
TRAVEL_RULE_WALLET_ADDRESSES_LIST_TRANSFERS,
|
|
9088
|
+
[entryUuid],
|
|
9089
|
+
params,
|
|
9090
|
+
options
|
|
9091
|
+
);
|
|
9092
|
+
}
|
|
9093
|
+
/**
|
|
9094
|
+
* Look up a wallet address
|
|
9095
|
+
*
|
|
9096
|
+
* Checks one exact address, chain and memo against your own wallet address book and then against wallets proven by other Didit Travel Rule participants. It never screens the wallet, never sends a message and never returns holder data from another application. `directory_checked` is always `false`: the lookup does not search a public directory, so `none` means the wallet is neither in your book nor proven on Didit, not that it is unknown elsewhere.
|
|
9097
|
+
*
|
|
9098
|
+
* `GET /v3/travel-rule/wallet-addresses/lookup/`
|
|
9099
|
+
*/
|
|
9100
|
+
lookup(params, options) {
|
|
9101
|
+
return this._client.request(TRAVEL_RULE_WALLET_ADDRESSES_LOOKUP, [], params, options);
|
|
9102
|
+
}
|
|
9037
9103
|
/**
|
|
9038
9104
|
* Update wallet address holder metadata
|
|
9039
9105
|
*
|
|
@@ -9143,6 +9209,18 @@ var TravelRule = class extends APIResource {
|
|
|
9143
9209
|
walletAddresses = new TravelRuleWalletAddresses(this._client);
|
|
9144
9210
|
walletProofs = new TravelRuleWalletProofs(this._client);
|
|
9145
9211
|
workspace = new TravelRuleWorkspaceResource(this._client);
|
|
9212
|
+
/**
|
|
9213
|
+
* Assign a VASP to a member
|
|
9214
|
+
*
|
|
9215
|
+
* Assigns the counterparty to one application member, or unassigns it with `assignee_email: null`. Repeating the same assignment changes nothing (`changed: false`). The assignment is private to your application. Needs the transactions write privilege.
|
|
9216
|
+
*
|
|
9217
|
+
* `POST /v3/travel-rule/vasps/{vasp_id}/assign/`
|
|
9218
|
+
*
|
|
9219
|
+
* @param vaspId The id of a row of GET /v3/travel-rule/vasps/: a directory entry or a Didit network member.
|
|
9220
|
+
*/
|
|
9221
|
+
assignVasp(vaspId, params, options) {
|
|
9222
|
+
return this._client.request(TRAVEL_RULE_ASSIGN_VASP, [vaspId], params, options);
|
|
9223
|
+
}
|
|
9146
9224
|
/**
|
|
9147
9225
|
* Clear your decision on a VASP
|
|
9148
9226
|
*
|
|
@@ -9187,6 +9265,16 @@ var TravelRule = class extends APIResource {
|
|
|
9187
9265
|
listVaspQuestionnaires(vaspId, options) {
|
|
9188
9266
|
return this._client.request(TRAVEL_RULE_LIST_VASP_QUESTIONNAIRES, [vaspId], void 0, options);
|
|
9189
9267
|
}
|
|
9268
|
+
/**
|
|
9269
|
+
* List the members who can be assigned a VASP
|
|
9270
|
+
*
|
|
9271
|
+
* The application members who can review Travel Rule counterparties. Use one `email` as `assignee_email` of `POST /v3/travel-rule/vasps/{vasp_id}/assign/`. Needs the transactions read privilege.
|
|
9272
|
+
*
|
|
9273
|
+
* `GET /v3/travel-rule/vasps/reviewers/`
|
|
9274
|
+
*/
|
|
9275
|
+
listVaspReviewers(options) {
|
|
9276
|
+
return this._client.request(TRAVEL_RULE_LIST_VASP_REVIEWERS, [], void 0, options);
|
|
9277
|
+
}
|
|
9190
9278
|
/**
|
|
9191
9279
|
* Search the VASP directory
|
|
9192
9280
|
*
|
|
@@ -9253,6 +9341,18 @@ var TravelRule = class extends APIResource {
|
|
|
9253
9341
|
retrieveVaspScreening(vaspId, options) {
|
|
9254
9342
|
return this._client.request(TRAVEL_RULE_RETRIEVE_VASP_SCREENING, [vaspId], void 0, options);
|
|
9255
9343
|
}
|
|
9344
|
+
/**
|
|
9345
|
+
* Review a screening hit
|
|
9346
|
+
*
|
|
9347
|
+
* Records your review of one possible match of a screening. The screening score and status are recomputed from the reviewed hits, but the counterparty's decision is never changed for you: decide it with `PUT /v3/travel-rule/vasps/{vasp_id}/decision/`. Repeating the same review changes nothing (`changed: false`). Needs the transactions write privilege.
|
|
9348
|
+
*
|
|
9349
|
+
* `PATCH /v3/travel-rule/vasps/{vasp_id}/screening/`
|
|
9350
|
+
*
|
|
9351
|
+
* @param vaspId The id of a row of GET /v3/travel-rule/vasps/: a directory entry or a Didit network member.
|
|
9352
|
+
*/
|
|
9353
|
+
reviewVaspScreeningHit(vaspId, params, options) {
|
|
9354
|
+
return this._client.request(TRAVEL_RULE_REVIEW_VASP_SCREENING_HIT, [vaspId], params, options);
|
|
9355
|
+
}
|
|
9256
9356
|
/**
|
|
9257
9357
|
* Screen a VASP
|
|
9258
9358
|
*
|