[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[libeufin] 02/02: Give CLI Taler-refund command.
From: |
gnunet |
Subject: |
[libeufin] 02/02: Give CLI Taler-refund command. |
Date: |
Tue, 31 Mar 2020 18:41:48 +0200 |
This is an automated email from the git hooks/post-receive script.
marcello pushed a commit to branch master
in repository libeufin.
commit 44ce3b084f676f2fe43d9e7a0906538177c2cbf3
Author: Marcello Stanisci <address@hidden>
AuthorDate: Tue Mar 31 18:41:30 2020 +0200
Give CLI Taler-refund command.
---
cli/python/libeufin-cli | 15 ++++++++++++---
nexus/src/main/kotlin/tech/libeufin/nexus/Main.kt | 2 +-
2 files changed, 13 insertions(+), 4 deletions(-)
diff --git a/cli/python/libeufin-cli b/cli/python/libeufin-cli
index 72a2d44..a753791 100755
--- a/cli/python/libeufin-cli
+++ b/cli/python/libeufin-cli
@@ -443,10 +443,19 @@ def crz(obj, account_id, date_range, nexus_base_url):
"nexus-base-url"
)
def refund(ctx, account_id, bank_account_id, nexus_base_url):
+ nexus_url = urljoin(
+ nexus_base_url,
"/ebics/taler/{}/accounts/{}/refund-invalid-payments".format(
+ account_id, bank_account_id
+ )
+ )
+ try:
+ resp = post(nexus_url, json=body)
+ except Exception:
+ print("Could not reach the Nexus")
+ return
+ print(resp.content.decode("utf-8"))
-
-
-@taler.command(help="Separate payments with Taler-subject from the rest")
+@taler.command(help="Flag Taler-invalid incoming payments.")
@click.pass_obj
@click.option(
"--account-id",
diff --git a/nexus/src/main/kotlin/tech/libeufin/nexus/Main.kt
b/nexus/src/main/kotlin/tech/libeufin/nexus/Main.kt
index 726fbfe..7ee52e7 100644
--- a/nexus/src/main/kotlin/tech/libeufin/nexus/Main.kt
+++ b/nexus/src/main/kotlin/tech/libeufin/nexus/Main.kt
@@ -630,7 +630,7 @@ fun main() {
return@get
}
- post("/ebics/taler/{id}/{acctid}/refund-invalid-payments") {
+
post("/ebics/taler/{id}/accounts/{acctid}/refund-invalid-payments") {
transaction {
val subscriber = expectIdTransaction(call.parameters["id"])
val acctid =
expectAcctidTransaction(call.parameters["acctid"])
--
To stop receiving notification emails like this one, please contact
address@hidden.