worthbak / inventory-checker-app

A macOS app for checking Apple Store inventory
https://worthbak.github.io/inventory-checker-app/
GNU General Public License v3.0
115 stars 24 forks source link

Updated Model #s for MacBook M2 Air #39

Closed omarshahine closed 2 years ago

omarshahine commented 2 years ago

I did not get all of them, but added Silver back and also the 24GB SKUs. Not sure why the SKU pattern changes so I had to include extra bits after the (country.skuCode) in some cases

func M2MBAirDataForCountry(_ country: Country) -> SKUData {

let orderedSkus = [
    // 8GB/256GB
    "MLY33\(country.skuCode)/A",
    "MLXW3\(country.skuCode)/A",
    "MLY13\(country.skuCode)/A",
    "MLXY3\(country.skuCode)/A",

    // 8GB/512GB
    "MLY43\(country.skuCode)/A",
    "MLXX3\(country.skuCode)/A",
    "MLY23\(country.skuCode)/A",
    "MLY03\(country.skuCode)/A",

    // 16GB/1TB
    "MN703\(country.skuCode)A13/A",
    "MNQP3\(country.skuCode)A4/A",
    "MN6Y3\(country.skuCode)A4/A",
    "MLY03\(country.skuCode)A4/A",

    // 24GB/1TB
    "MLY43\(country.skuCode)A7/A",
    "MLXX3\(country.skuCode)A16/A",
    "MLY23\(country.skuCode)A7/A",
    "MLY03\(country.skuCode)A16/A",

    // 24GB/2TB
    "MLY43\(country.skuCode)A17/A",
    "MLXX3\(country.skuCode)A8/A",
    "MLY23\(country.skuCode)A8/A",
    "MLY03\(country.skuCode)A17/A"
]

let skusToName = [
    // 8GB/256GB
    "MLY33\(country.skuCode)/A": "M2 (8c CPU, 8c GPU) 8GB/256GB Midnight",
    "MLXW3\(country.skuCode)/A": "M2 (8c CPU, 8c GPU) 8GB/256GB Space Gray",
    "MLY13\(country.skuCode)/A": "M2 (8c CPU, 8c GPU) 8GB/256GB Starlight",
    "MLXY3\(country.skuCode)/A": "M2 (8c CPU, 8c GPU) 8GB/256GB Silver",

    // 8GB/512GB
    "MLY43\(country.skuCode)/A": "M2 (8c CPU, 10c GPU) 8GB/512GB Midnight",
    "MLXX3\(country.skuCode)/A": "M2 (8c CPU, 10c GPU) 8GB/512GB Space Gray",
    "MLY23\(country.skuCode)/A": "M2 (8c CPU, 10c GPU) 8GB/512GB Starlight",
    "MLY03\(country.skuCode)/A": "M2 (8c CPU, 10c GPU) 8GB/512GB Silver",

    // 16GB/1TB
    "MN703\(country.skuCode)A13/A": "M2 (8c CPU, 10c GPU) 16GB/1TB Midnight",
    "MNQP3\(country.skuCode)A4/A": "M2 (8c CPU, 10c GPU) 16GB/1TB Space Gray",
    "MN6Y3\(country.skuCode)A4/A": "M2 (8c CPU, 10c GPU) 16GB/1TB Starlight",
    "MLY03\(country.skuCode)A4/A": "M2 (8c CPU, 10c GPU) 16GB/1TB Silver",

    // 24GB/1TB
    "MLY43\(country.skuCode)A7/A": "M2 (8c CPU, 10c GPU) 24GB/1TB Midnight",
    "MLXX3\(country.skuCode)A16/A": "M2 (8c CPU, 10c GPU) 24GB/1TB Space Gray",
    "MLY23\(country.skuCode)A7/A": "M2 (8c CPU, 10c GPU) 24GB/1TB Starlight",
    "MLY03\(country.skuCode)A16/A": "M2 (8c CPU, 10c GPU) 24GB/1TB Silver",

    // 24GB/2TB
    "MLY43\(country.skuCode)A17/A": "M2 (8c CPU, 10c GPU) 24GB/2TB Midnight",
    "MLXX3\(country.skuCode)A8/A": "M2 (8c CPU, 10c GPU) 24GB/2TB Space Gray",
    "MLY23\(country.skuCode)A8/A": "M2 (8c CPU, 10c GPU) 24GB/2TB Starlight",
    "MLY03\(country.skuCode)A17/A": "M2 (8c CPU, 10c GPU) 24GB/2TB Silver"
]

return SKUData(orderedSKUs: orderedSkus, lookup: skusToName)
worthbak commented 2 years ago

Apple only stocks a handful of SKUs in-store, and InventoryWatch can only query for those SKUs. As far as I'm aware, Apple is only stocking the SKUs currently in the app (the two base-models in all four colors, and one "ultimate" model in all colors but silver). This tweet has an image from an Apple Store in Japan that lists these three models: https://twitter.com/yuki629d/status/1547780851760766977?s=20&t=1pMwv-Nvbm_JBgA8WnsCLw

I'll keep any eye on it, though - Apple may add more configs in the future.

omarshahine commented 2 years ago

At some point they will stock all of them, I guess I'm not sure why you would not want all the possible SKU options as one day they will be in the store and folks will want them.

omarshahine commented 2 years ago

Oh, I see what you mean. There is a difference between "ship to store" and "in store"

worthbak commented 2 years ago

Yeah, exactly - any built-to-order model can be shipped to a store for pickup, but only certain configurations are stocked in stores regularly, and those configs are what this app tracks.