• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

safe-global / safe-client-gateway / 8784763765 / 2
89%
main: 89%

Build:
DEFAULT BRANCH: main
Ran 22 Apr 2024 01:22PM UTC
Files 1223
Run time 38s
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

22 Apr 2024 01:17PM UTC coverage: 93.074% (-0.3%) from 93.416%
8784763765.2

push

github

web-flow
Add support for Swap orders in tx confirmation route (#1435)

Adds support for CoW Swap Orders in `POST chains/:chainId/safes/:safeAddress/views/transaction-confirmation` route. If a CoW Swap Order is found, the type of the Transaction Confirmation View would be of `COW_SWAP_ORDER`.

A `COW_SWAP_ORDER` confirmation view would have, in addition to what is returned by a `GENERIC` view, the properties of an `Order` (which can also be found on the transaction decoding done for the History and Queue endpoints).

The Cow Swap Confirmation view is returned if:
- The Order data was successfully retrieved
- The Token data (buy and sell) were successfully retrieved and is considered valid (e.g. with decimal information)
- The Order is considered valid (by the Safe{Wallet} standards) – e.g. order kind should not be `unknown`.

```
POST chains/:chainId/safes/:safeAddress/views/transaction-confirmation

{
  "type": COW_SWAP_ORDER",
  "method": "string",
  "parameters": "DataDecodedParameter[]",
  "uid": "string",
  "status": "presignaturePending | open | fulfilled | cancelled | expired | unknown",
  "kind": "buy | sell",
  "orderClass": "market | limit | liquidity | unknown",
  "validUntil": "number (timestamp)",
  "sellAmount": "string (raw amount, no decimals)",
  "buyAmount": "string (raw amount, no decimals)",
  "executedSellAmount": "string (raw amount, no decimals)",
  "executedBuyAmount": "string (raw amount, no decimals)",
  "explorerUrl": "URL (string format URL)",
  "executedSurplusFee": "string | null",
  "sellToken": "TokenInfo (object with properties of TokenInfo)",
  "buyToken": "TokenInfo (object with properties of TokenInfo)"
}
```

Changes:

- Adds a new `ConfirmationView` type – `CowSwapConfirmationView`.
- The `CowSwapConfirmationView` contains the baseline data expected for the Transaction Confirmation View screen plus the CoW Swap Order data if it was successfully retrieved.

1966 of 2412 branches covered (81.51%)

Branch coverage included in aggregate %.

13704 of 14424 relevant lines covered (95.01%)

152.1 hits per line

Source Files on job run-test:cov - 8784763765.2
  • Tree
  • List 1223
  • Changed 70
  • Source Changed 5
  • Coverage Changed 155
Coverage ∆ File Lines Relevant Covered Missed Hits/Line Branch Hits Branch Misses
  • Back to Build 8784763765
  • becda8f8 on github
  • Prev Job for on main (#8783016962.1)
  • Next Job for on main (#8785390646.1)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc