<!-- XE-16989 · [Low] SDK structs silently drop server fields: GetProviders, GetPending, GetChain, ChatChallenge · testnet -->
*Markdown view of <https://bounty.xe.network/XE-16989>. The page is the record; this is the same page for reading.*

XE-16989 · Bounty

# \[Low\] SDK structs silently drop server fields: GetProviders, GetPending, GetChain, ChatChallenge

Triaging
[xe#700](https://github.com/xeprotocol/xe/issues/700)
filed 2026-11-17 08:12 UTC
by kecedanzz77-bit

Verdict
:   published when the fix ships

Tier
:   published when the fix ships

Claimed
:   —

Area
:   SDK / docs / web

Duplicate of
:   —

Tracked
:   —

Updated
:   2026-11-22 23:26 UTC

Told
:   2026-11-22 23:26 UTC

### Patches

None linked.

### History

- [770296](https://bounty.xe.network/log/770296) 2026-11-22 23:27 UTC reply.mirror\_failed
- [770229](https://bounty.xe.network/log/770229) 2026-11-22 23:26 UTC proposal.adopted
- [770228](https://bounty.xe.network/log/770228) 2026-11-22 23:26 UTC reply.sent
- [769507](https://bounty.xe.network/log/769507) 2026-11-22 23:26 UTC proposal.adopted
- [769506](https://bounty.xe.network/log/769506) 2026-11-22 23:26 UTC ticket.status new → triaging
- [769187](https://bounty.xe.network/log/769187) 2026-11-22 23:25 UTC proposal.adopted
- [769186](https://bounty.xe.network/log/769186) 2026-11-22 23:25 UTC ticket.award
- [768072](https://bounty.xe.network/log/768072) 2026-11-22 23:25 UTC proposal.adopted
- [768071](https://bounty.xe.network/log/768071) 2026-11-22 23:25 UTC ticket.facts area
- [768070](https://bounty.xe.network/log/768070) 2026-11-22 23:25 UTC proposal.adopted
- [768069](https://bounty.xe.network/log/768069) 2026-11-22 23:25 UTC ticket.facts
- [768068](https://bounty.xe.network/log/768068) 2026-11-22 23:25 UTC proposal.adopted

[Full history](https://bounty.xe.network/log?ref=XE-16989) · [JSON](https://bounty.xe.network/v1/tickets/XE-16989) · [markdown](https://bounty.xe.network/XE-16989.md)

### Report

## Summary

Four SDK structs silently drop fields the server sends, so SDK/CLI users cannot see data the API already provides: provider lease-count caps and ad staleness, pending-send timestamps, chain block finality, and chat-challenge expiry.

## Root Cause (one finding, 4 instances)

1. **`max_concurrent_leases` \+ `timestamp`:** server `node.ProviderInfo` (`node/node.go:1092`, 11 fields) vs SDK `client.ProviderInfo` (`client/client.go:178`, 9 fields). SDK/CLI provider selection cannot see the lease-count cap or ad staleness.
2. **`Timestamp`:** server `pendingEntry` (`api/handler.go:579`) enriches every pending send with the send block's timestamp; SDK decodes into `core.PendingSend` (`core/types.go`), which has no Timestamp field.
3. **`finalized`:** server wraps chain blocks in `blockView` (`api/handler.go:509`, embeds `*core.Block` \+ `Finalized`); SDK decodes into plain `[]*core.Block`, so callers cannot tell finalized from unfinalized blocks.
4. **`expires_at`:** server `handleChatChallenge` (`api/chat_auth.go:134`) returns `challenge` \+ `expires_at` (120s TTL); SDK `ChatChallenge` (`client/chat.go:45`) reads only `challenge`, so callers cannot know when the proof expires.

## Verification

Executed PoC against the real `api.Handler` (httptest \+ fake backend):

```
raw /providers body contains "max_concurrent_leases":5,...,"timestamp":1700000000000000000
  — client.ProviderInfo has MaxConcurrentLeases/Timestamp fields: false (struct has 9 fields, server sends 11)
raw /pending/... body contains "Timestamp":1700000000000000000 — core.PendingSend has Timestamp field: false
raw chain block has "finalized":true (SDK decodes into plain []*core.Block)
raw challenge has expires_at (SDK reads only challenge; TTL invisible to caller)
```

## Note on related reports

Searched `GetProviders timestamp max_concurrent_leases`, `pending Timestamp client`, `finalized GetChain client drops`, `client SDK drops fields` — no hits. #277 is docs-only (notes the server Timestamp exists; does not cover the SDK struct gap). #567 (conflict 10-cap) is unrelated.

## Suggested fix

Add the missing fields to the SDK structs (`ProviderInfo`, `PendingSend`, chain block view, `ChatChallenge` response).

### Thread

**Joseph Denne**team2026-11-22 23:26 UTCdesk

Thanks for the report. It is being handled.
