Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion scripts/prompts/prompt_test_wapupay.md
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,7 @@ as the refund address. Show me the funding instructions but DO NOT pay yet.
- Invokes `wapupay_create_order(amount_ars="10000", alias="test.alias.mp", receiver_name="Test Receiver", refund_address="lq1qqw4...k6lng")`
- Returns `tentative_id`, `status` (`FUNDING_ISSUED`), `address_destination` (Liquid `lq1…/ex1…/VJL…`),
`asset_id` (USDT on Liquid), `funding_amount_usdt`, `total_amount_usdt`,
`total_funding_amount_base_units`, `funding_expires_at`, `pay_instructions`, `qr_code_path`
`total_funding_amount_base_units`, `expires_at`, `pay_instructions`, `qr_code_path`
- ⚠️ The agent shows the funding address/QR **but must NOT call `lw_send_asset`** — keep this dry

---
Expand Down
2 changes: 1 addition & 1 deletion src/aqua/__init__.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
"""Agentic AQUA - Manage Liquid Network and Bitcoin wallets through AI assistants."""

__version__ = "0.5.1b1"
__version__ = "0.5.2"
2 changes: 1 addition & 1 deletion src/aqua/server.py
Original file line number Diff line number Diff line change
Expand Up @@ -1143,7 +1143,7 @@
"funding instructions. Returns address_destination (Liquid), asset_id, "
"funding_amount_usdt, total_amount_usdt, "
"total_funding_amount_base_units (for USDT), funding_amount_sat (for LBTC), "
"funding_expires_at and a QR. Pay the TOTAL with lw_send_asset (amount "
"expires_at and a QR. Pay the TOTAL with lw_send_asset (amount "
"and unit depend on funding_method — follow pay_instructions); "
"WapuPay then makes a P2P payer settle ARS to the bank account. Does NOT broadcast the "
"payment itself — confirm the quote with the user first via wapupay_quote."
Expand Down
4 changes: 2 additions & 2 deletions src/aqua/tools.py
Original file line number Diff line number Diff line change
Expand Up @@ -1233,7 +1233,7 @@ def wapupay_create_order(
`wapupay_fund_order` — no silent failure.

The result includes `address_destination` (a Liquid address),
`funding_amount_usdt`, `total_amount_usdt`, `funding_expires_at`, and a
`funding_amount_usdt`, `total_amount_usdt`, `expires_at`, and a
`pay_instructions` field that tells you the exact amount and unit to send —
follow it. For the default `USDT` rail, pay the TOTAL with `lw_send_asset`
(amount = `total_funding_amount_base_units`, the exact total_amount_usdt in
Expand Down Expand Up @@ -1263,7 +1263,7 @@ def wapupay_create_order(
Returns:
The order record incl. tentative_id, status, address_destination,
asset_id, funding_amount_usdt, total_amount_usdt,
total_funding_amount_base_units, funding_expires_at, funded,
total_funding_amount_base_units, expires_at, funded,
pay_instructions, and qr_code_path (QR of the funding address).
"""
result = get_wapupay_manager().create_order(
Expand Down
8 changes: 3 additions & 5 deletions src/aqua/wapupay.py
Original file line number Diff line number Diff line change
Expand Up @@ -236,7 +236,6 @@ def _to_decimal(value: str | int | float | Decimal) -> Decimal:
"address_destination",
"asset_id",
"expires_at",
"funding_expires_at",
"refund_address",
"funding_transaction_id",
"executed_transaction_id",
Expand Down Expand Up @@ -337,7 +336,6 @@ class WapuPayOrder:
address_destination: Optional[str] = None
asset_id: Optional[str] = None
expires_at: Optional[str] = None
funding_expires_at: Optional[str] = None
refund_address: Optional[str] = None
funding_transaction_id: Optional[str] = None
executed_transaction_id: Optional[str] = None
Expand Down Expand Up @@ -748,7 +746,7 @@ def create_order(

Returns the order record including ``address_destination`` (Liquid),
``asset_id``, ``funding_amount_usdt`` / ``total_amount_usdt`` and
``funding_expires_at`` — plus ``total_funding_amount_base_units`` (USDT
``expires_at`` — plus ``total_funding_amount_base_units`` (USDT
rail) or ``funding_amount_sat`` (L-BTC rail). The caller pays the amount
named in ``pay_instructions`` with ``lw_send_asset`` — this method never
broadcasts.
Expand Down Expand Up @@ -927,9 +925,9 @@ def _funded_result(order: "WapuPayOrder") -> dict:
return result

expires_note = (
f" Funding window: expires at {order.funding_expires_at} UTC"
f" Funding window: expires at {order.expires_at} UTC"
f" (convert to the user's local timezone before displaying)."
if order.funding_expires_at
if order.expires_at
else ""
)
payout_note = (
Expand Down
4 changes: 2 additions & 2 deletions tests/test_wapupay.py
Original file line number Diff line number Diff line change
Expand Up @@ -222,7 +222,7 @@ def side_effect(req, timeout=None):
"address_destination": "lq1qqfunding0address",
"asset_id": "ce091c998b83c78bb71a632313ba3760f1763d9cfcffae02258ffa9865a37bd2",
"funding_amount_usdt": 6.99,
"funding_expires_at": "2026-05-24T14:35:00Z",
"expires_at": "2026-05-24T14:35:00Z",
}

# L-BTC funding rail: WapuPay returns a real funding_amount_sat (sats to send)
Expand Down Expand Up @@ -250,7 +250,7 @@ def side_effect(req, timeout=None):
"funding_amount_sat": 25127,
"funding_amount_usdt": 15.65,
"total_amount_usdt": 15.78,
"funding_expires_at": "2026-07-17T20:22:10Z",
"expires_at": "2026-07-17T20:22:10Z",
}


Expand Down