← Back to Catalog
Latias
RARE Pokemon

Latias

Estimated Value $0.00
Set POP Series 7
Language en
Rarity RARE
Edition Standard
Login to Buy

Active Listings

Database query walkthrough

Card active listings query

Asks for buyable listings for the exact card variant opened on the detail page.

Django path
frontend.services.catalog_service.list_active_listings_for_variant
Tables touched
MarketListing, InventoryItem, CardVariant, Card, CardGame, CardSet, CardImage, User
  1. Use the selected card_variant_id from the detail URL as the lookup value.
  2. Ask for listings whose InventoryItem points to that variant.
  3. Filter to ACTIVE listings with quantity_available greater than zero.
  4. Ask for seller and card metadata rows through the listing relationship.
  5. Order by lowest unit price first, then id for stable buy options.
ORM shape
MarketListing.objects.filter(
    inventory_item__card_variant_id=variant_id,
    status=ACTIVE,
    quantity_available__gt=0,
).select_related(...).order_by('unit_price', 'id')

📭

No active listings for this card right now.

Price History

Database query walkthrough

Price history query

Asks for the newest stored price snapshots for the exact card variant.

Django path
frontend.services.catalog_service.build_price_history
Tables touched
PriceSnapshot, CardVariant
  1. Use the current card variant id from the detail card data.
  2. Ask for PriceSnapshot rows with that card_variant_id.
  3. Order snapshots by newest captured_at value, then newest id for stable results.
  4. Limit the answer to the 24 newest snapshots.
  5. Read date, price, and source name from the returned rows.
ORM shape
PriceSnapshot.objects.filter(card_variant_id=variant_id)
    .order_by('-captured_at', '-id')[:24]

📊

No price history available yet.

Similar Cards

Database query walkthrough

Similar cards query

Asks for nearby catalog variants using simple database metadata.

Django path
frontend.services.catalog_service.list_similar_cards
Tables touched
CardVariant, Card, CardGame, CardSet, CardImage
  1. Use the opened card's game and rarity as the similarity criteria.
  2. Ask for CardVariant rows with the same game and rarity.
  3. Filter out rows that belong to the currently opened Card id.
  4. Ask for related card, game, set, and image data through the variant relationship.
  5. Order by card name and id, then limit the answer to six cards.
ORM shape
CardVariant.objects.select_related(...)
    .filter(card__game__name=card['game'], rarity=card['rarity'])
    .exclude(card_id=card['id'])
    .order_by('card__name', 'id')[:6]