mirror of
https://github.com/luxfi/bridge.git
synced 2026-09-24 00:26:46 +00:00
Covers the SDK side of the layered cosigner contract while issue #386's backend implementation is in progress: 1. Omits cosigners[] entirely when no layered providers configured (backwards compat — no behavior change for existing tenants). 2. Forwards utila intent in snake_case, public IDs only. 3. Forwards fireblocks intent in snake_case, public IDs only. 4. Forwards both utila + fireblocks together (belt + suspenders). 5. Omits optional sub-fields (api_host, vault_id) when unset — no 'foo: undefined' on the wire. Each test that forwards an intent also asserts the full request body contains zero secret-like substrings (private_key, api_secret, jwt, token, service_account_private_key) — defense in depth against any future regression where a consumer's bridge.config.ts accidentally forwards a secret. Pairs with the 16 server-side validator tests in app/server/src/domain/ __tests__/cosigners.test.ts — together they pin the wire contract from both ends. Total SDK tests: 53 → 58. All passing.