@bitcredit/bcr-ebill-wasm 0.3.0 → 0.3.1

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/README.md ADDED
@@ -0,0 +1,7 @@
1
+ # @bitcredit/bcr-ebill-wasm
2
+
3
+ WASM-version of the E-Bill API.
4
+
5
+ Check out the docs [here](https://github.com/BitcreditProtocol/E-Bill/blob/master/docs/wasm.md).
6
+
7
+ Check out the changelog [here](https://github.com/BitcreditProtocol/E-Bill/blob/master/CHANGELOG.md).
package/index.d.ts CHANGED
@@ -9,52 +9,6 @@ export enum IdentityTypeWeb {
9
9
  Person = 0,
10
10
  Company = 1,
11
11
  }
12
- export interface ContactsResponse {
13
- contacts: ContactWeb[];
14
- }
15
-
16
- export interface NewContactPayload {
17
- t: number;
18
- node_id: string;
19
- name: string;
20
- email: string;
21
- postal_address: PostalAddressWeb;
22
- date_of_birth_or_registration: string | undefined;
23
- country_of_birth_or_registration: string | undefined;
24
- city_of_birth_or_registration: string | undefined;
25
- identification_number: string | undefined;
26
- avatar_file_upload_id: string | undefined;
27
- proof_document_file_upload_id: string | undefined;
28
- }
29
-
30
- export interface EditContactPayload {
31
- node_id: string;
32
- name: string | undefined;
33
- email: string | undefined;
34
- postal_address: OptionalPostalAddressWeb;
35
- date_of_birth_or_registration: string | undefined;
36
- country_of_birth_or_registration: string | undefined;
37
- city_of_birth_or_registration: string | undefined;
38
- identification_number: string | undefined;
39
- avatar_file_upload_id: string | undefined;
40
- proof_document_file_upload_id: string | undefined;
41
- }
42
-
43
- export interface ContactWeb {
44
- t: ContactTypeWeb;
45
- node_id: string;
46
- name: string;
47
- email: string;
48
- postal_address: PostalAddressWeb;
49
- date_of_birth_or_registration: string | undefined;
50
- country_of_birth_or_registration: string | undefined;
51
- city_of_birth_or_registration: string | undefined;
52
- identification_number: string | undefined;
53
- avatar_file: FileWeb | undefined;
54
- proof_document_file: FileWeb | undefined;
55
- nostr_relays: string[];
56
- }
57
-
58
12
  export interface BillId {
59
13
  id: string;
60
14
  }
@@ -72,7 +26,7 @@ export interface BitcreditBillPayload {
72
26
  country_of_payment: string;
73
27
  city_of_payment: string;
74
28
  language: string;
75
- file_upload_id: string | undefined;
29
+ file_upload_ids: string[];
76
30
  }
77
31
 
78
32
  export interface BillNumbersToWordsForSum {
@@ -202,41 +156,110 @@ export interface BitcreditEbillQuote {
202
156
 
203
157
  export interface BitcreditBillWeb {
204
158
  id: string;
205
- time_of_drawing: number;
206
- time_of_maturity: number;
207
- country_of_issuing: string;
208
- city_of_issuing: string;
209
- drawee: IdentityPublicDataWeb;
210
- drawer: IdentityPublicDataWeb;
159
+ participants: BillParticipantsWeb;
160
+ data: BillDataWeb;
161
+ status: BillStatusWeb;
162
+ current_waiting_state: BillCurrentWaitingStateWeb | undefined;
163
+ }
164
+
165
+ export type BillCurrentWaitingStateWeb = { Sell: BillWaitingForSellStateWeb } | { Payment: BillWaitingForPaymentStateWeb } | { Recourse: BillWaitingForRecourseStateWeb };
166
+
167
+ export interface BillWaitingForSellStateWeb {
168
+ time_of_request: number;
169
+ buyer: IdentityPublicDataWeb;
170
+ seller: IdentityPublicDataWeb;
171
+ currency: string;
172
+ sum: string;
173
+ link_to_pay: string;
174
+ address_to_pay: string;
175
+ mempool_link_for_address_to_pay: string;
176
+ }
177
+
178
+ export interface BillWaitingForPaymentStateWeb {
179
+ time_of_request: number;
180
+ payer: IdentityPublicDataWeb;
211
181
  payee: IdentityPublicDataWeb;
212
- endorsee: IdentityPublicDataWeb | undefined;
213
182
  currency: string;
214
183
  sum: string;
215
- maturity_date: string;
216
- issue_date: string;
217
- country_of_payment: string;
218
- city_of_payment: string;
219
- language: string;
220
- accepted: boolean;
221
- endorsed: boolean;
222
- requested_to_pay: boolean;
223
- requested_to_accept: boolean;
224
- paid: boolean;
225
- waiting_for_payment: boolean;
226
- buyer: IdentityPublicDataWeb | undefined;
227
- seller: IdentityPublicDataWeb | undefined;
228
- in_recourse: boolean;
229
- recourser: IdentityPublicDataWeb | undefined;
230
- recoursee: IdentityPublicDataWeb | undefined;
231
- link_for_buy: string;
232
184
  link_to_pay: string;
233
- link_to_pay_recourse: string;
234
185
  address_to_pay: string;
235
186
  mempool_link_for_address_to_pay: string;
187
+ }
188
+
189
+ export interface BillWaitingForRecourseStateWeb {
190
+ time_of_request: number;
191
+ recourser: IdentityPublicDataWeb;
192
+ recoursee: IdentityPublicDataWeb;
193
+ currency: string;
194
+ sum: string;
195
+ link_to_pay: string;
196
+ address_to_pay: string;
197
+ mempool_link_for_address_to_pay: string;
198
+ }
199
+
200
+ export interface BillStatusWeb {
201
+ acceptance: BillAcceptanceStatusWeb;
202
+ payment: BillPaymentStatusWeb;
203
+ sell: BillSellStatusWeb;
204
+ recourse: BillRecourseStatusWeb;
205
+ redeemed_funds_available: boolean;
206
+ }
207
+
208
+ export interface BillAcceptanceStatusWeb {
209
+ time_of_request_to_accept: number | undefined;
210
+ requested_to_accept: boolean;
211
+ accepted: boolean;
212
+ request_to_accept_timed_out: boolean;
213
+ rejected_to_accept: boolean;
214
+ }
215
+
216
+ export interface BillPaymentStatusWeb {
217
+ time_of_request_to_pay: number | undefined;
218
+ requested_to_pay: boolean;
219
+ paid: boolean;
220
+ request_to_pay_timed_out: boolean;
221
+ rejected_to_pay: boolean;
222
+ }
223
+
224
+ export interface BillSellStatusWeb {
225
+ time_of_last_offer_to_sell: number | undefined;
226
+ sold: boolean;
227
+ offered_to_sell: boolean;
228
+ offer_to_sell_timed_out: boolean;
229
+ rejected_offer_to_sell: boolean;
230
+ }
231
+
232
+ export interface BillRecourseStatusWeb {
233
+ time_of_last_request_to_recourse: number | undefined;
234
+ recoursed: boolean;
235
+ requested_to_recourse: boolean;
236
+ request_to_recourse_timed_out: boolean;
237
+ rejected_request_to_recourse: boolean;
238
+ }
239
+
240
+ export interface BillDataWeb {
241
+ language: string;
242
+ time_of_drawing: number;
243
+ issue_date: string;
244
+ time_of_maturity: number;
245
+ maturity_date: string;
246
+ country_of_issuing: string;
247
+ city_of_issuing: string;
248
+ country_of_payment: string;
249
+ city_of_payment: string;
250
+ currency: string;
251
+ sum: string;
236
252
  files: FileWeb[];
237
253
  active_notification: NotificationWeb | undefined;
238
- bill_participants: string[];
254
+ }
255
+
256
+ export interface BillParticipantsWeb {
257
+ drawee: IdentityPublicDataWeb;
258
+ drawer: IdentityPublicDataWeb;
259
+ payee: IdentityPublicDataWeb;
260
+ endorsee: IdentityPublicDataWeb | undefined;
239
261
  endorsements_count: number;
262
+ all_participant_node_ids: string[];
240
263
  }
241
264
 
242
265
  export interface LightBitcreditBillWeb {
@@ -340,25 +363,58 @@ export interface SignatoryResponse {
340
363
  avatar_file: FileWeb | undefined;
341
364
  }
342
365
 
366
+ export interface ContactsResponse {
367
+ contacts: ContactWeb[];
368
+ }
369
+
370
+ export interface NewContactPayload {
371
+ t: number;
372
+ node_id: string;
373
+ name: string;
374
+ email: string;
375
+ postal_address: PostalAddressWeb;
376
+ date_of_birth_or_registration: string | undefined;
377
+ country_of_birth_or_registration: string | undefined;
378
+ city_of_birth_or_registration: string | undefined;
379
+ identification_number: string | undefined;
380
+ avatar_file_upload_id: string | undefined;
381
+ proof_document_file_upload_id: string | undefined;
382
+ }
383
+
384
+ export interface EditContactPayload {
385
+ node_id: string;
386
+ name: string | undefined;
387
+ email: string | undefined;
388
+ postal_address: OptionalPostalAddressWeb;
389
+ date_of_birth_or_registration: string | undefined;
390
+ country_of_birth_or_registration: string | undefined;
391
+ city_of_birth_or_registration: string | undefined;
392
+ identification_number: string | undefined;
393
+ avatar_file_upload_id: string | undefined;
394
+ proof_document_file_upload_id: string | undefined;
395
+ }
396
+
397
+ export interface ContactWeb {
398
+ t: ContactTypeWeb;
399
+ node_id: string;
400
+ name: string;
401
+ email: string;
402
+ postal_address: PostalAddressWeb;
403
+ date_of_birth_or_registration: string | undefined;
404
+ country_of_birth_or_registration: string | undefined;
405
+ city_of_birth_or_registration: string | undefined;
406
+ identification_number: string | undefined;
407
+ avatar_file: FileWeb | undefined;
408
+ proof_document_file: FileWeb | undefined;
409
+ nostr_relays: string[];
410
+ }
411
+
343
412
  export interface JsErrorData {
344
413
  error: string;
345
414
  message: string;
346
415
  code: number;
347
416
  }
348
417
 
349
- export interface NotificationWeb {
350
- id: string;
351
- node_id: string | undefined;
352
- notification_type: NotificationTypeWeb;
353
- reference_id: string | undefined;
354
- description: string;
355
- datetime: string;
356
- active: boolean;
357
- payload: any | undefined;
358
- }
359
-
360
- export type NotificationTypeWeb = "General" | "Bill";
361
-
362
418
  export interface StatusResponse {
363
419
  bitcoin_network: string;
364
420
  app_version: string;
@@ -440,15 +496,6 @@ export interface UploadFilesResponse {
440
496
  file_upload_id: string;
441
497
  }
442
498
 
443
- export interface Config {
444
- bitcoin_network: string;
445
- nostr_relay: string;
446
- surreal_db_connection: string;
447
- data_dir: string;
448
- job_runner_initial_delay_seconds: number;
449
- job_runner_check_interval_seconds: number;
450
- }
451
-
452
499
  export interface SwitchIdentity {
453
500
  t: IdentityTypeWeb | undefined;
454
501
  node_id: string;
@@ -498,6 +545,27 @@ export interface SeedPhrase {
498
545
  seed_phrase: string;
499
546
  }
500
547
 
548
+ export interface Config {
549
+ log_level: Level | undefined;
550
+ bitcoin_network: string;
551
+ nostr_relay: string;
552
+ job_runner_initial_delay_seconds: number;
553
+ job_runner_check_interval_seconds: number;
554
+ }
555
+
556
+ export interface NotificationWeb {
557
+ id: string;
558
+ node_id: string | undefined;
559
+ notification_type: NotificationTypeWeb;
560
+ reference_id: string | undefined;
561
+ description: string;
562
+ datetime: string;
563
+ active: boolean;
564
+ payload: any | undefined;
565
+ }
566
+
567
+ export type NotificationTypeWeb = "General" | "Bill";
568
+
501
569
  export class Api {
502
570
  private constructor();
503
571
  free(): void;
@@ -521,7 +589,6 @@ export class Bill {
521
589
  search(payload: BillsSearchFilterPayload): Promise<LightBillsResponse>;
522
590
  list_light(): Promise<LightBillsResponse>;
523
591
  list(): Promise<BillsResponse>;
524
- list_all(): Promise<BillsResponse>;
525
592
  numbers_to_words_for_sum(id: string): Promise<BillNumbersToWordsForSum>;
526
593
  detail(id: string): Promise<BitcreditBillWeb>;
527
594
  check_payment(): Promise<void>;
@@ -598,7 +665,6 @@ export class Notification {
598
665
  list(active?: boolean | null, reference_id?: string | null, notification_type?: string | null, limit?: bigint | null, offset?: bigint | null): Promise<NotificationWeb[]>;
599
666
  mark_as_done(notification_id: string): Promise<void>;
600
667
  trigger_test_msg(payload: any): Promise<void>;
601
- trigger_test_notification(node_id: string): Promise<void>;
602
668
  }
603
669
  export class Quote {
604
670
  private constructor();
@@ -612,26 +678,10 @@ export type InitInput = RequestInfo | URL | Response | BufferSource | WebAssembl
612
678
 
613
679
  export interface InitOutput {
614
680
  readonly memory: WebAssembly.Memory;
615
- readonly __wbg_contact_free: (a: number, b: number) => void;
616
- readonly contact_new: () => number;
617
- readonly contact_file: (a: number, b: number, c: number, d: number, e: number) => any;
618
- readonly contact_upload: (a: number, b: any) => any;
619
- readonly contact_list: (a: number) => any;
620
- readonly contact_detail: (a: number, b: number, c: number) => any;
621
- readonly contact_remove: (a: number, b: number, c: number) => any;
622
- readonly contact_create: (a: number, b: any) => any;
623
- readonly contact_edit: (a: number, b: any) => any;
624
681
  readonly __wbg_quote_free: (a: number, b: number) => void;
682
+ readonly quote_new: () => number;
625
683
  readonly quote_get: (a: number, b: number, c: number) => any;
626
684
  readonly quote_accept: (a: number, b: number, c: number) => any;
627
- readonly quote_new: () => number;
628
- readonly __wbg_general_free: (a: number, b: number) => void;
629
- readonly general_new: () => number;
630
- readonly general_status: (a: number) => any;
631
- readonly general_currencies: (a: number) => any;
632
- readonly general_temp_file: (a: number, b: number, c: number) => any;
633
- readonly general_overview: (a: number, b: number, c: number) => any;
634
- readonly general_search: (a: number, b: any) => any;
635
685
  readonly __wbg_identity_free: (a: number, b: number) => void;
636
686
  readonly identity_new: () => number;
637
687
  readonly identity_file: (a: number, b: number, c: number) => any;
@@ -643,15 +693,13 @@ export interface InitOutput {
643
693
  readonly identity_switch: (a: number, b: any) => any;
644
694
  readonly identity_seed_backup: (a: number) => any;
645
695
  readonly identity_seed_recover: (a: number, b: any) => any;
646
- readonly initialize_api: (a: any) => any;
647
- readonly __wbg_api_free: (a: number, b: number) => void;
648
- readonly api_bill: () => number;
649
- readonly api_general: () => number;
650
- readonly api_identity: () => number;
651
- readonly api_notification: () => number;
652
- readonly api_contact: () => number;
653
- readonly api_company: () => number;
654
- readonly api_quote: () => number;
696
+ readonly __wbg_general_free: (a: number, b: number) => void;
697
+ readonly general_new: () => number;
698
+ readonly general_status: (a: number) => any;
699
+ readonly general_currencies: (a: number) => any;
700
+ readonly general_temp_file: (a: number, b: number, c: number) => any;
701
+ readonly general_overview: (a: number, b: number, c: number) => any;
702
+ readonly general_search: (a: number, b: any) => any;
655
703
  readonly __wbg_company_free: (a: number, b: number) => void;
656
704
  readonly company_new: () => number;
657
705
  readonly company_file: (a: number, b: number, c: number, d: number, e: number) => any;
@@ -663,15 +711,22 @@ export interface InitOutput {
663
711
  readonly company_edit: (a: number, b: any) => any;
664
712
  readonly company_add_signatory: (a: number, b: any) => any;
665
713
  readonly company_remove_signatory: (a: number, b: any) => any;
714
+ readonly __wbg_notification_free: (a: number, b: number) => void;
666
715
  readonly notification_subscribe: (a: number, b: any) => any;
667
716
  readonly notification_list: (a: number, b: number, c: number, d: number, e: number, f: number, g: number, h: bigint, i: number, j: bigint) => any;
668
717
  readonly notification_mark_as_done: (a: number, b: number, c: number) => any;
669
718
  readonly notification_trigger_test_msg: (a: number, b: any) => any;
670
- readonly notification_trigger_test_notification: (a: number, b: number, c: number) => any;
671
719
  readonly notification_new: () => number;
672
- readonly __wbg_notification_free: (a: number, b: number) => void;
720
+ readonly __wbg_contact_free: (a: number, b: number) => void;
721
+ readonly contact_new: () => number;
722
+ readonly contact_file: (a: number, b: number, c: number, d: number, e: number) => any;
723
+ readonly contact_upload: (a: number, b: any) => any;
724
+ readonly contact_list: (a: number) => any;
725
+ readonly contact_detail: (a: number, b: number, c: number) => any;
726
+ readonly contact_remove: (a: number, b: number, c: number) => any;
727
+ readonly contact_create: (a: number, b: any) => any;
728
+ readonly contact_edit: (a: number, b: any) => any;
673
729
  readonly __wbg_bill_free: (a: number, b: number) => void;
674
- readonly bill_new: () => number;
675
730
  readonly bill_endorsements: (a: number, b: number, c: number) => any;
676
731
  readonly bill_past_endorsees: (a: number, b: number, c: number) => any;
677
732
  readonly bill_bitcoin_key: (a: number, b: number, c: number) => any;
@@ -680,7 +735,6 @@ export interface InitOutput {
680
735
  readonly bill_search: (a: number, b: any) => any;
681
736
  readonly bill_list_light: (a: number) => any;
682
737
  readonly bill_list: (a: number) => any;
683
- readonly bill_list_all: (a: number) => any;
684
738
  readonly bill_numbers_to_words_for_sum: (a: number, b: number, c: number) => any;
685
739
  readonly bill_detail: (a: number, b: number, c: number) => any;
686
740
  readonly bill_check_payment: (a: number) => any;
@@ -698,6 +752,16 @@ export interface InitOutput {
698
752
  readonly bill_reject_to_pay_recourse: (a: number, b: any) => any;
699
753
  readonly bill_request_to_recourse_bill_payment: (a: number, b: any) => any;
700
754
  readonly bill_request_to_recourse_bill_acceptance: (a: number, b: any) => any;
755
+ readonly __wbg_api_free: (a: number, b: number) => void;
756
+ readonly api_bill: () => number;
757
+ readonly initialize_api: (a: any) => any;
758
+ readonly bill_new: () => number;
759
+ readonly api_general: () => number;
760
+ readonly api_identity: () => number;
761
+ readonly api_notification: () => number;
762
+ readonly api_contact: () => number;
763
+ readonly api_company: () => number;
764
+ readonly api_quote: () => number;
701
765
  readonly ring_core_0_17_14__bn_mul_mont: (a: number, b: number, c: number, d: number, e: number, f: number) => void;
702
766
  readonly rustsecp256k1_v0_10_0_context_create: (a: number) => number;
703
767
  readonly rustsecp256k1_v0_10_0_context_destroy: (a: number) => void;
@@ -710,15 +774,15 @@ export interface InitOutput {
710
774
  readonly __wbindgen_export_4: WebAssembly.Table;
711
775
  readonly __wbindgen_free: (a: number, b: number, c: number) => void;
712
776
  readonly __wbindgen_export_6: WebAssembly.Table;
713
- readonly _dyn_core__ops__function__FnMut_____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__hbe6873c45b27b351: (a: number, b: number) => void;
714
- readonly closure3939_externref_shim_multivalue_shim: (a: number, b: number, c: any) => [number, number];
777
+ readonly _dyn_core__ops__function__FnMut_____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__hd28bc47676a15709: (a: number, b: number) => void;
778
+ readonly closure3958_externref_shim_multivalue_shim: (a: number, b: number, c: any) => [number, number];
715
779
  readonly __externref_table_dealloc: (a: number) => void;
716
- readonly _dyn_core__ops__function__FnMut_____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__h05c7f237f3bb177e: (a: number, b: number) => void;
717
- readonly closure5466_externref_shim: (a: number, b: number, c: any) => void;
718
- readonly closure5720_externref_shim: (a: number, b: number, c: any) => void;
719
- readonly _dyn_core__ops__function__FnMut_____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__hf2e94f04a8ad2147: (a: number, b: number) => void;
720
- readonly closure5931_externref_shim: (a: number, b: number, c: any) => void;
721
- readonly closure6063_externref_shim: (a: number, b: number, c: any, d: any) => void;
780
+ readonly _dyn_core__ops__function__FnMut_____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__hc6ad37980230d22e: (a: number, b: number) => void;
781
+ readonly closure5482_externref_shim: (a: number, b: number, c: any) => void;
782
+ readonly closure5745_externref_shim: (a: number, b: number, c: any) => void;
783
+ readonly _dyn_core__ops__function__FnMut_____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__h8b6645c2830c9446: (a: number, b: number) => void;
784
+ readonly closure5946_externref_shim: (a: number, b: number, c: any) => void;
785
+ readonly closure6078_externref_shim: (a: number, b: number, c: any, d: any) => void;
722
786
  readonly __wbindgen_start: () => void;
723
787
  }
724
788
 
package/index.js CHANGED
@@ -212,7 +212,7 @@ export function initialize_api(cfg) {
212
212
  }
213
213
 
214
214
  function __wbg_adapter_54(arg0, arg1) {
215
- wasm._dyn_core__ops__function__FnMut_____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__hbe6873c45b27b351(arg0, arg1);
215
+ wasm._dyn_core__ops__function__FnMut_____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__hd28bc47676a15709(arg0, arg1);
216
216
  }
217
217
 
218
218
  function takeFromExternrefTable0(idx) {
@@ -221,34 +221,34 @@ function takeFromExternrefTable0(idx) {
221
221
  return value;
222
222
  }
223
223
  function __wbg_adapter_57(arg0, arg1, arg2) {
224
- const ret = wasm.closure3939_externref_shim_multivalue_shim(arg0, arg1, arg2);
224
+ const ret = wasm.closure3958_externref_shim_multivalue_shim(arg0, arg1, arg2);
225
225
  if (ret[1]) {
226
226
  throw takeFromExternrefTable0(ret[0]);
227
227
  }
228
228
  }
229
229
 
230
230
  function __wbg_adapter_60(arg0, arg1) {
231
- wasm._dyn_core__ops__function__FnMut_____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__h05c7f237f3bb177e(arg0, arg1);
231
+ wasm._dyn_core__ops__function__FnMut_____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__hc6ad37980230d22e(arg0, arg1);
232
232
  }
233
233
 
234
234
  function __wbg_adapter_63(arg0, arg1, arg2) {
235
- wasm.closure5466_externref_shim(arg0, arg1, arg2);
235
+ wasm.closure5482_externref_shim(arg0, arg1, arg2);
236
236
  }
237
237
 
238
238
  function __wbg_adapter_66(arg0, arg1, arg2) {
239
- wasm.closure5720_externref_shim(arg0, arg1, arg2);
239
+ wasm.closure5745_externref_shim(arg0, arg1, arg2);
240
240
  }
241
241
 
242
242
  function __wbg_adapter_69(arg0, arg1) {
243
- wasm._dyn_core__ops__function__FnMut_____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__hf2e94f04a8ad2147(arg0, arg1);
243
+ wasm._dyn_core__ops__function__FnMut_____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__h8b6645c2830c9446(arg0, arg1);
244
244
  }
245
245
 
246
246
  function __wbg_adapter_72(arg0, arg1, arg2) {
247
- wasm.closure5931_externref_shim(arg0, arg1, arg2);
247
+ wasm.closure5946_externref_shim(arg0, arg1, arg2);
248
248
  }
249
249
 
250
- function __wbg_adapter_429(arg0, arg1, arg2, arg3) {
251
- wasm.closure6063_externref_shim(arg0, arg1, arg2, arg3);
250
+ function __wbg_adapter_427(arg0, arg1, arg2, arg3) {
251
+ wasm.closure6078_externref_shim(arg0, arg1, arg2, arg3);
252
252
  }
253
253
 
254
254
  /**
@@ -373,7 +373,7 @@ export class Bill {
373
373
  * @returns {Bill}
374
374
  */
375
375
  static new() {
376
- const ret = wasm.bill_new();
376
+ const ret = wasm.api_bill();
377
377
  return Bill.__wrap(ret);
378
378
  }
379
379
  /**
@@ -449,13 +449,6 @@ export class Bill {
449
449
  const ret = wasm.bill_list(this.__wbg_ptr);
450
450
  return ret;
451
451
  }
452
- /**
453
- * @returns {BillsResponse}
454
- */
455
- list_all() {
456
- const ret = wasm.bill_list_all(this.__wbg_ptr);
457
- return ret;
458
- }
459
452
  /**
460
453
  * @param {string} id
461
454
  * @returns {BillNumbersToWordsForSum}
@@ -1064,16 +1057,6 @@ export class Notification {
1064
1057
  const ret = wasm.notification_trigger_test_msg(this.__wbg_ptr, payload);
1065
1058
  return ret;
1066
1059
  }
1067
- /**
1068
- * @param {string} node_id
1069
- * @returns {Promise<void>}
1070
- */
1071
- trigger_test_notification(node_id) {
1072
- const ptr0 = passStringToWasm0(node_id, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
1073
- const len0 = WASM_VECTOR_LEN;
1074
- const ret = wasm.notification_trigger_test_notification(this.__wbg_ptr, ptr0, len0);
1075
- return ret;
1076
- }
1077
1060
  }
1078
1061
 
1079
1062
  const QuoteFinalization = (typeof FinalizationRegistry === 'undefined')
@@ -1105,7 +1088,7 @@ export class Quote {
1105
1088
  * @returns {Quote}
1106
1089
  */
1107
1090
  static new() {
1108
- const ret = wasm.contact_new();
1091
+ const ret = wasm.quote_new();
1109
1092
  return Quote.__wrap(ret);
1110
1093
  }
1111
1094
  /**
@@ -1210,11 +1193,11 @@ function __wbg_get_imports() {
1210
1193
  const ret = clearInterval(arg0);
1211
1194
  return ret;
1212
1195
  };
1213
- imports.wbg.__wbg_clearTimeout_4397cdf06dd2e6ef = function(arg0) {
1196
+ imports.wbg.__wbg_clearTimeout_5a54f8841c30079a = function(arg0) {
1214
1197
  const ret = clearTimeout(arg0);
1215
1198
  return ret;
1216
1199
  };
1217
- imports.wbg.__wbg_clearTimeout_5a54f8841c30079a = function(arg0) {
1200
+ imports.wbg.__wbg_clearTimeout_86721db0036bea98 = function(arg0) {
1218
1201
  const ret = clearTimeout(arg0);
1219
1202
  return ret;
1220
1203
  };
@@ -1295,14 +1278,14 @@ function __wbg_get_imports() {
1295
1278
  const ret = arg0.fetch(arg1);
1296
1279
  return ret;
1297
1280
  };
1298
- imports.wbg.__wbg_fetch_991491c8dac859a5 = function(arg0) {
1281
+ imports.wbg.__wbg_fetch_d36a73832f0a45e8 = function(arg0) {
1299
1282
  const ret = fetch(arg0);
1300
1283
  return ret;
1301
1284
  };
1302
- imports.wbg.__wbg_getRandomValues_78e016fdd1d721cf = function() { return handleError(function (arg0, arg1) {
1285
+ imports.wbg.__wbg_getRandomValues_21a0191e74d0e1d3 = function() { return handleError(function (arg0, arg1) {
1303
1286
  globalThis.crypto.getRandomValues(getArrayU8FromWasm0(arg0, arg1));
1304
1287
  }, arguments) };
1305
- imports.wbg.__wbg_getRandomValues_7dd14472e5bb087d = function() { return handleError(function (arg0, arg1) {
1288
+ imports.wbg.__wbg_getRandomValues_3d90134a348e46b3 = function() { return handleError(function (arg0, arg1) {
1306
1289
  globalThis.crypto.getRandomValues(getArrayU8FromWasm0(arg0, arg1));
1307
1290
  }, arguments) };
1308
1291
  imports.wbg.__wbg_getRandomValues_bcb4912f16000dc4 = function() { return handleError(function (arg0, arg1) {
@@ -1464,7 +1447,7 @@ function __wbg_get_imports() {
1464
1447
  const a = state0.a;
1465
1448
  state0.a = 0;
1466
1449
  try {
1467
- return __wbg_adapter_429(a, state0.b, arg0, arg1);
1450
+ return __wbg_adapter_427(a, state0.b, arg0, arg1);
1468
1451
  } finally {
1469
1452
  state0.a = a;
1470
1453
  }
@@ -1535,6 +1518,10 @@ function __wbg_get_imports() {
1535
1518
  const ret = arg0.node;
1536
1519
  return ret;
1537
1520
  };
1521
+ imports.wbg.__wbg_now_698fd875f24e9a0f = function() { return handleError(function () {
1522
+ const ret = Date.now();
1523
+ return ret;
1524
+ }, arguments) };
1538
1525
  imports.wbg.__wbg_now_71123b9940376874 = function(arg0) {
1539
1526
  const ret = arg0.now();
1540
1527
  return ret;
@@ -1543,10 +1530,6 @@ function __wbg_get_imports() {
1543
1530
  const ret = Date.now();
1544
1531
  return ret;
1545
1532
  };
1546
- imports.wbg.__wbg_now_9e28294e2edd6344 = function() { return handleError(function () {
1547
- const ret = Date.now();
1548
- return ret;
1549
- }, arguments) };
1550
1533
  imports.wbg.__wbg_now_d18023d54d4e5500 = function(arg0) {
1551
1534
  const ret = arg0.now();
1552
1535
  return ret;
@@ -1642,7 +1625,7 @@ function __wbg_get_imports() {
1642
1625
  const ret = setInterval(arg0, arg1);
1643
1626
  return ret;
1644
1627
  }, arguments) };
1645
- imports.wbg.__wbg_setTimeout_d69c3ce010c0e055 = function(arg0, arg1) {
1628
+ imports.wbg.__wbg_setTimeout_2e707715f8cc9497 = function(arg0, arg1) {
1646
1629
  const ret = setTimeout(arg0, arg1);
1647
1630
  return ret;
1648
1631
  };
@@ -1858,32 +1841,32 @@ function __wbg_get_imports() {
1858
1841
  const ret = false;
1859
1842
  return ret;
1860
1843
  };
1861
- imports.wbg.__wbindgen_closure_wrapper21534 = function(arg0, arg1, arg2) {
1862
- const ret = makeMutClosure(arg0, arg1, 3940, __wbg_adapter_57);
1844
+ imports.wbg.__wbindgen_closure_wrapper21859 = function(arg0, arg1, arg2) {
1845
+ const ret = makeMutClosure(arg0, arg1, 3959, __wbg_adapter_57);
1863
1846
  return ret;
1864
1847
  };
1865
- imports.wbg.__wbindgen_closure_wrapper22044 = function(arg0, arg1, arg2) {
1866
- const ret = makeMutClosure(arg0, arg1, 4088, __wbg_adapter_60);
1848
+ imports.wbg.__wbindgen_closure_wrapper22371 = function(arg0, arg1, arg2) {
1849
+ const ret = makeMutClosure(arg0, arg1, 4107, __wbg_adapter_60);
1867
1850
  return ret;
1868
1851
  };
1869
- imports.wbg.__wbindgen_closure_wrapper27146 = function(arg0, arg1, arg2) {
1870
- const ret = makeMutClosure(arg0, arg1, 5467, __wbg_adapter_63);
1852
+ imports.wbg.__wbindgen_closure_wrapper27501 = function(arg0, arg1, arg2) {
1853
+ const ret = makeMutClosure(arg0, arg1, 5483, __wbg_adapter_63);
1871
1854
  return ret;
1872
1855
  };
1873
- imports.wbg.__wbindgen_closure_wrapper27781 = function(arg0, arg1, arg2) {
1874
- const ret = makeMutClosure(arg0, arg1, 5721, __wbg_adapter_66);
1856
+ imports.wbg.__wbindgen_closure_wrapper28124 = function(arg0, arg1, arg2) {
1857
+ const ret = makeMutClosure(arg0, arg1, 5746, __wbg_adapter_66);
1875
1858
  return ret;
1876
1859
  };
1877
- imports.wbg.__wbindgen_closure_wrapper29020 = function(arg0, arg1, arg2) {
1878
- const ret = makeMutClosure(arg0, arg1, 5922, __wbg_adapter_69);
1860
+ imports.wbg.__wbindgen_closure_wrapper29350 = function(arg0, arg1, arg2) {
1861
+ const ret = makeMutClosure(arg0, arg1, 5937, __wbg_adapter_69);
1879
1862
  return ret;
1880
1863
  };
1881
- imports.wbg.__wbindgen_closure_wrapper29045 = function(arg0, arg1, arg2) {
1882
- const ret = makeMutClosure(arg0, arg1, 5932, __wbg_adapter_72);
1864
+ imports.wbg.__wbindgen_closure_wrapper29375 = function(arg0, arg1, arg2) {
1865
+ const ret = makeMutClosure(arg0, arg1, 5947, __wbg_adapter_72);
1883
1866
  return ret;
1884
1867
  };
1885
- imports.wbg.__wbindgen_closure_wrapper3151 = function(arg0, arg1, arg2) {
1886
- const ret = makeMutClosure(arg0, arg1, 1144, __wbg_adapter_54);
1868
+ imports.wbg.__wbindgen_closure_wrapper3171 = function(arg0, arg1, arg2) {
1869
+ const ret = makeMutClosure(arg0, arg1, 1127, __wbg_adapter_54);
1887
1870
  return ret;
1888
1871
  };
1889
1872
  imports.wbg.__wbindgen_debug_string = function(arg0, arg1) {
package/index_bg.wasm CHANGED
Binary file
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@bitcredit/bcr-ebill-wasm",
3
3
  "type": "module",
4
- "version": "0.3.0",
4
+ "version": "0.3.1",
5
5
  "files": [
6
6
  "index_bg.wasm",
7
7
  "index.js",