import Foundation /// Demo configuration. /// /// Do NOT hardcode live credentials here — this file is tracked in git. Put your /// real merchant API key/secret in an untracked `Config.local.swift` (git-ignored) /// that defines `ConfigSecrets`, e.g.: /// /// enum ConfigSecrets { /// static let apiKey = "…" /// static let apiSecret = "…" /// } /// /// If `Config.local.swift` is absent the placeholders below are used and calls /// will fail auth — that's intentional, so a build never ships real secrets. enum Config { /// TruePay Core base URL (no trailing slash). UAT: https://api.sandbox.truepay.ompay.om static let baseURL = "https://api.truepay.ompay.om" /// Merchant API credentials (the same headers the sandbox uses). /// Sourced from the untracked Config.local.swift; placeholders otherwise. static let apiKey = ConfigSecrets.apiKey static let apiSecret = ConfigSecrets.apiSecret /// Your Apple Merchant ID. Three places must agree or Apple Pay will not even open: /// 1. this value, /// 2. `com.apple.developer.in-app-payments` in TruePayApplePayDemo.entitlements, /// 3. the App ID's Apple Pay capability (so the provisioning profile carries it). /// It must ALSO match the certificate uploaded to TruePay and the merchant's /// appleMerchantIdentifier there — that one is the KDF input for decrypting the token, /// and it only matters AFTER Apple Pay hands back a token. /// For OMPAY testing: merchant.com.ompay.tp (team 9C48KB4AR3) static let merchantIdentifier = "merchant.com.ompay.tp" /// Storefront / payment display. static let merchantDisplayName = "OMPAY TruePay Demo" static let countryCode = "OM" static let currencyCode = "OMR" /// Networks the merchant accepts. static let supportedNetworks: [String] = ["visa", "masterCard"] }