commit 06e916173f7a5c1a73c902b89fae26ac674e4ddf
parent b6bfb16ccc44ee45e2a069a25cb5e4e197b05d14
Author: Florian Dold <florian@dold.me>
Date: Tue, 20 Jun 2023 20:16:17 +0200
update wallet-core docs
Diffstat:
1 file changed, 47 insertions(+), 15 deletions(-)
diff --git a/wallet/wallet-core.md b/wallet/wallet-core.md
@@ -275,20 +275,6 @@ interface GetPlanForWalletInitiatedOperation {
```
```typescript
-/**
- * How the amount should be interpreted in a transaction
- * Effective = how the balance is change
- * Raw = effective amount without fee
- *
- * Depending on the transaction, raw can be higher than effective
- */
-export declare enum TransactionAmountMode {
- Effective = "effective",
- Raw = "raw",
-}
-
-```
-```typescript
interface GetPlanForDepositRequest extends GetPlanForWalletInitiatedOperation {
type: TransactionType.Deposit;
account: string;
@@ -1781,6 +1767,12 @@ export type PreparePeerPushCreditOp = {
```
```typescript
+export interface PreparePeerPushCreditRequest {
+ talerUri: string;
+}
+
+```
+```typescript
export interface PreparePeerPushCreditResponse {
contractTerms: PeerContractTerms;
/**
@@ -2765,6 +2757,36 @@ export interface WalletCoreVersion {
}
```
```typescript
+/**
+ * How the amount should be interpreted in a transaction
+ * Effective = how the balance is change
+ * Raw = effective amount without fee
+ *
+ * Depending on the transaction, raw can be higher than effective
+ */
+export declare enum TransactionAmountMode {
+ Effective = "effective",
+ Raw = "raw",
+}
+```
+```typescript
+export interface ConvertAmountRequest {
+ amount: AmountString;
+ type: TransactionAmountMode;
+}
+```
+```typescript
+export interface AmountResponse {
+ effectiveAmount: AmountString;
+ rawAmount: AmountString;
+}
+```
+```typescript
+export interface GetAmountRequest {
+ currency: string;
+}
+```
+```typescript
export interface TransactionsResponse {
transactions: Transaction[];
}
@@ -2816,7 +2838,7 @@ export interface TransactionCommon {
/**
* Possible transitions based on the current state.
*/
- txActions: string[];
+ txActions: TransactionAction[];
/**
* Raw amount of the transaction (exclusive of fees or other extra costs).
*/
@@ -2934,6 +2956,16 @@ export declare enum TransactionMinorState {
}
```
```typescript
+export declare enum TransactionAction {
+ Delete = "delete",
+ Suspend = "suspend",
+ Resume = "resume",
+ Abort = "abort",
+ Fail = "fail",
+ Retry = "retry",
+}
+```
+```typescript
export interface TalerErrorDetail {
code: TalerErrorCode;
when?: AbsoluteTime;