Skip to content

Spec drift: baozi — off-chain metadata endpoint (GET /api/markets/metadata) never called, causing empty descriptions and images #541

@realfishsam

Description

@realfishsam

Summary

Baozi exposes an off-chain REST endpoint GET /api/markets/metadata that provides human-readable market descriptions, image URLs, and topic categories for on-chain markets. PMXT's Baozi adapter fetches market data entirely from the Solana on-chain state and never calls this metadata endpoint, resulting in empty description and image fields for all Baozi markets.

Impact

MEDIUM — all Baozi markets in PMXT display with no description and no image, making them appear incomplete compared to markets from other venues. Topic category data is also missing (see related category mismatch issue).

Details

  • Missing endpoint: GET /api/markets/metadata (off-chain Baozi REST API)
  • Data provided: market description (string), image URL, topic category, creator info
  • On-chain data: program accounts provide price/liquidity/resolution data but no human-readable metadata
  • Current adapter: core/src/exchanges/baozi/fetcher.ts only reads from Solana RPC — no HTTP call to the metadata endpoint
  • The metadata endpoint takes a list of market addresses and returns metadata objects keyed by address

Required Fix

  1. Add an HTTP call to GET /api/markets/metadata in the Baozi fetcher, passing the market addresses fetched from Solana
  2. Merge the metadata (description, image, category) onto each market object before normalization
  3. Use the topic category from metadata to fix the category field mismatch (see related issue)

Metadata

Metadata

Assignees

No one assigned

    Labels

    spec-driftCached OpenAPI spec out of date vs venue's live docs

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions