@dfinity/ledger-icrc 5.0.1 → 6.0.0-next-2025-11-18
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/candid/icrc_index-ng.certified.idl.js +1 -1
- package/dist/candid/icrc_index-ng.d.ts +7 -7
- package/dist/candid/icrc_index-ng.did +1 -1
- package/dist/candid/icrc_index-ng.idl.js +1 -1
- package/dist/candid/icrc_index.certified.idl.js +1 -1
- package/dist/candid/icrc_index.d.ts +7 -7
- package/dist/candid/icrc_index.idl.js +1 -1
- package/dist/candid/icrc_ledger.certified.idl.js +1 -1
- package/dist/candid/icrc_ledger.d.ts +21 -21
- package/dist/candid/icrc_ledger.did +1 -1
- package/dist/candid/icrc_ledger.idl.js +1 -1
- package/dist/candid/icrc_nft-ledger.certified.idl.d.ts +2 -0
- package/dist/candid/icrc_nft-ledger.certified.idl.js +102 -0
- package/dist/candid/icrc_nft-ledger.d.ts +80 -0
- package/dist/candid/icrc_nft-ledger.did +67 -0
- package/dist/candid/icrc_nft-ledger.idl.d.ts +2 -0
- package/dist/candid/icrc_nft-ledger.idl.js +106 -0
- package/dist/index.d.ts +3 -0
- package/dist/index.js.map +1 -1
- package/dist/index.mjs.map +1 -1
- package/package.json +4 -4
|
@@ -0,0 +1,106 @@
|
|
|
1
|
+
/* eslint-disable */
|
|
2
|
+
|
|
3
|
+
// @ts-nocheck
|
|
4
|
+
|
|
5
|
+
// This file was automatically generated by @icp-sdk/bindgen@0.2.0.
|
|
6
|
+
// You should NOT make any changes in this file as it will be overwritten.
|
|
7
|
+
// Additionally, you should also exclude this file from your linter and/or formatter to prevent it from being checked or modified.
|
|
8
|
+
|
|
9
|
+
export const idlFactory = ({ IDL }) => {
|
|
10
|
+
const Value = IDL.Rec();
|
|
11
|
+
const Subaccount = IDL.Vec(IDL.Nat8);
|
|
12
|
+
const Account = IDL.Record({
|
|
13
|
+
owner: IDL.Principal,
|
|
14
|
+
subaccount: IDL.Opt(Subaccount),
|
|
15
|
+
});
|
|
16
|
+
Value.fill(
|
|
17
|
+
IDL.Variant({
|
|
18
|
+
Int: IDL.Int,
|
|
19
|
+
Map: IDL.Vec(IDL.Tuple(IDL.Text, Value)),
|
|
20
|
+
Nat: IDL.Nat,
|
|
21
|
+
Blob: IDL.Vec(IDL.Nat8),
|
|
22
|
+
Text: IDL.Text,
|
|
23
|
+
Array: IDL.Vec(Value),
|
|
24
|
+
}),
|
|
25
|
+
);
|
|
26
|
+
const TransferArg = IDL.Record({
|
|
27
|
+
to: Account,
|
|
28
|
+
token_id: IDL.Nat,
|
|
29
|
+
memo: IDL.Opt(IDL.Vec(IDL.Nat8)),
|
|
30
|
+
from_subaccount: IDL.Opt(IDL.Vec(IDL.Nat8)),
|
|
31
|
+
created_at_time: IDL.Opt(IDL.Nat64),
|
|
32
|
+
});
|
|
33
|
+
const TransferError = IDL.Variant({
|
|
34
|
+
GenericError: IDL.Record({
|
|
35
|
+
message: IDL.Text,
|
|
36
|
+
error_code: IDL.Nat,
|
|
37
|
+
}),
|
|
38
|
+
Duplicate: IDL.Record({ duplicate_of: IDL.Nat }),
|
|
39
|
+
NonExistingTokenId: IDL.Null,
|
|
40
|
+
Unauthorized: IDL.Null,
|
|
41
|
+
CreatedInFuture: IDL.Record({ ledger_time: IDL.Nat64 }),
|
|
42
|
+
InvalidRecipient: IDL.Null,
|
|
43
|
+
GenericBatchError: IDL.Record({
|
|
44
|
+
message: IDL.Text,
|
|
45
|
+
error_code: IDL.Nat,
|
|
46
|
+
}),
|
|
47
|
+
TooOld: IDL.Null,
|
|
48
|
+
});
|
|
49
|
+
const TransferResult = IDL.Variant({ Ok: IDL.Nat, Err: TransferError });
|
|
50
|
+
|
|
51
|
+
return IDL.Service({
|
|
52
|
+
icrc7_atomic_batch_transfers: IDL.Func([], [IDL.Opt(IDL.Bool)], ["query"]),
|
|
53
|
+
icrc7_balance_of: IDL.Func(
|
|
54
|
+
[IDL.Vec(Account)],
|
|
55
|
+
[IDL.Vec(IDL.Nat)],
|
|
56
|
+
["query"],
|
|
57
|
+
),
|
|
58
|
+
icrc7_collection_metadata: IDL.Func(
|
|
59
|
+
[],
|
|
60
|
+
[IDL.Vec(IDL.Tuple(IDL.Text, Value))],
|
|
61
|
+
["query"],
|
|
62
|
+
),
|
|
63
|
+
icrc7_default_take_value: IDL.Func([], [IDL.Opt(IDL.Nat)], ["query"]),
|
|
64
|
+
icrc7_description: IDL.Func([], [IDL.Opt(IDL.Text)], ["query"]),
|
|
65
|
+
icrc7_logo: IDL.Func([], [IDL.Opt(IDL.Text)], ["query"]),
|
|
66
|
+
icrc7_max_memo_size: IDL.Func([], [IDL.Opt(IDL.Nat)], ["query"]),
|
|
67
|
+
icrc7_max_query_batch_size: IDL.Func([], [IDL.Opt(IDL.Nat)], ["query"]),
|
|
68
|
+
icrc7_max_take_value: IDL.Func([], [IDL.Opt(IDL.Nat)], ["query"]),
|
|
69
|
+
icrc7_max_update_batch_size: IDL.Func([], [IDL.Opt(IDL.Nat)], ["query"]),
|
|
70
|
+
icrc7_name: IDL.Func([], [IDL.Text], ["query"]),
|
|
71
|
+
icrc7_owner_of: IDL.Func(
|
|
72
|
+
[IDL.Vec(IDL.Nat)],
|
|
73
|
+
[IDL.Vec(IDL.Opt(Account))],
|
|
74
|
+
["query"],
|
|
75
|
+
),
|
|
76
|
+
icrc7_permitted_drift: IDL.Func([], [IDL.Opt(IDL.Nat)], ["query"]),
|
|
77
|
+
icrc7_supply_cap: IDL.Func([], [IDL.Opt(IDL.Nat)], ["query"]),
|
|
78
|
+
icrc7_symbol: IDL.Func([], [IDL.Text], ["query"]),
|
|
79
|
+
icrc7_token_metadata: IDL.Func(
|
|
80
|
+
[IDL.Vec(IDL.Nat)],
|
|
81
|
+
[IDL.Vec(IDL.Opt(IDL.Vec(IDL.Tuple(IDL.Text, Value))))],
|
|
82
|
+
["query"],
|
|
83
|
+
),
|
|
84
|
+
icrc7_tokens: IDL.Func(
|
|
85
|
+
[IDL.Opt(IDL.Nat), IDL.Opt(IDL.Nat)],
|
|
86
|
+
[IDL.Vec(IDL.Nat)],
|
|
87
|
+
["query"],
|
|
88
|
+
),
|
|
89
|
+
icrc7_tokens_of: IDL.Func(
|
|
90
|
+
[Account, IDL.Opt(IDL.Nat), IDL.Opt(IDL.Nat)],
|
|
91
|
+
[IDL.Vec(IDL.Nat)],
|
|
92
|
+
["query"],
|
|
93
|
+
),
|
|
94
|
+
icrc7_total_supply: IDL.Func([], [IDL.Nat], ["query"]),
|
|
95
|
+
icrc7_transfer: IDL.Func(
|
|
96
|
+
[IDL.Vec(TransferArg)],
|
|
97
|
+
[IDL.Vec(IDL.Opt(TransferResult))],
|
|
98
|
+
[],
|
|
99
|
+
),
|
|
100
|
+
icrc7_tx_window: IDL.Func([], [IDL.Opt(IDL.Nat)], ["query"]),
|
|
101
|
+
});
|
|
102
|
+
};
|
|
103
|
+
|
|
104
|
+
export const init = ({ IDL }) => {
|
|
105
|
+
return [];
|
|
106
|
+
};
|
package/dist/index.d.ts
CHANGED
|
@@ -1,3 +1,6 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @module api/ledger/icrc
|
|
3
|
+
*/
|
|
1
4
|
export type { ICRC3Value as Icrc3Value, Allowance as IcrcAllowance, ApproveError as IcrcApproveError, BlockIndex as IcrcBlockIndex, Account as IcrcCandidAccount, GetBlocksArgs as IcrcGetBlocksArgs, GetBlocksResult as IcrcGetBlocksResult, StandardRecord as IcrcStandardRecord, Subaccount as IcrcSubaccount, Timestamp as IcrcTimestamp, Tokens as IcrcTokens, TransferArg as IcrcTransferArg, TransferFromError as IcrcTransferFromError, TransferError as IcrcTransferVariantError, Value as IcrcValue, } from "./candid/icrc_ledger";
|
|
2
5
|
export * from "./converters/converters";
|
|
3
6
|
export * from "./converters/ledger.converters";
|