{"openapi":"3.1.0","info":{"title":"GLIN US Import Preflight API","version":"1.0.0","description":"One-call pre-import screening for AI trade agents."},"servers":[{"url":"https://ozeejewwpjmabshxyitc.supabase.co/functions/v1/glin-us-import-preflight-x402-v1"}],"paths":{"/import/preflight":{"get":{"operationId":"usImportPreflight","summary":"US Import Preflight — counterparty + tariff","description":"Enter counterparty, HTS code/product text and origin. Returns OFAC+UK+UN sanctions, GLEIF legal identity, USITC tariff evidence and USTR China Section 301 additional-duty evidence with PROCEED_TO_COMPLIANCE_REVIEW, REVIEW or BLOCK. $0.02 USDC.","parameters":[{"name":"counterparty","in":"query","required":true,"schema":{"type":"string","minLength":2,"maxLength":180}},{"name":"hts","in":"query","required":true,"schema":{"type":"string","minLength":2,"maxLength":120},"example":"8517.13.00.00","description":"Use a full 10-digit code for a numeric estimate. Shorter codes and product text are candidates only; do not pad a buyer code automatically."},{"name":"origin","in":"query","required":true,"schema":{"type":"string","minLength":2,"maxLength":2}},{"name":"customsValueUsd","in":"query","required":false,"schema":{"type":"number","minimum":0,"maximum":1000000000},"description":"Optional customs value in USD for known-duty estimate"},{"name":"buyerBaseRatePercent","in":"query","required":false,"schema":{"type":"number","minimum":0,"maximum":1000},"description":"Compare your GENERAL/BASE_ONLY percent rate quote to exact official USITC HTS"}],"responses":{"200":{"description":"US import preflight decision","content":{"application/json":{"schema":{"type":"object","required":["ok","product","weapon","decision","buyerDecision","reasons","request","counterparty","tariff","financialImpact","criticalUnknowns","nextActions","sources","scope","priceUsd"],"properties":{"ok":{"type":"boolean"},"product":{"type":"string"},"weapon":{"type":"string"},"decision":{"type":"string","enum":["PROCEED_TO_COMPLIANCE_REVIEW","REVIEW","BLOCK"]},"buyerDecision":{"type":"string","enum":["PROCEED_WITH_REMAINING_CHECKS","HOLD_AND_REVIEW","DO_NOT_PROCEED"]},"reasons":{"type":"array"},"request":{"type":"object"},"counterparty":{"type":"object"},"tariff":{"type":"object"},"financialImpact":{"type":"object"},"buyerQuoteAudit":{"type":"object"},"criticalUnknowns":{"type":"array"},"nextActions":{"type":"array"},"sources":{"type":"array"},"scope":{"type":"object"},"priceUsd":{"type":"number"}}}}}},"400":{"description":"Invalid input"},"402":{"description":"x402 payment required"}}}},"/trade/import-gate":{"get":{"operationId":"usTradeImportGate","summary":"US Trade Import Gate","description":"Enter counterparty, HTS code/product text and origin. Returns OFAC+UK+UN sanctions, GLEIF legal identity, USITC tariff evidence and USTR China Section 301 additional-duty evidence with PROCEED_TO_COMPLIANCE_REVIEW, REVIEW or BLOCK. $0.02 USDC.","parameters":[{"name":"counterparty","in":"query","required":true,"schema":{"type":"string","minLength":2,"maxLength":180}},{"name":"hts","in":"query","required":true,"schema":{"type":"string","minLength":2,"maxLength":120},"example":"8517.13.00.00","description":"Use a full 10-digit code for a numeric estimate. Shorter codes and product text are candidates only; do not pad a buyer code automatically."},{"name":"origin","in":"query","required":true,"schema":{"type":"string","minLength":2,"maxLength":2}},{"name":"customsValueUsd","in":"query","required":false,"schema":{"type":"number","minimum":0,"maximum":1000000000},"description":"Optional customs value in USD for known-duty estimate"},{"name":"buyerBaseRatePercent","in":"query","required":false,"schema":{"type":"number","minimum":0,"maximum":1000},"description":"Compare your GENERAL/BASE_ONLY percent rate quote to exact official USITC HTS"}],"responses":{"200":{"description":"US import preflight decision","content":{"application/json":{"schema":{"type":"object","required":["ok","product","weapon","decision","buyerDecision","reasons","request","counterparty","tariff","financialImpact","criticalUnknowns","nextActions","sources","scope","priceUsd"],"properties":{"ok":{"type":"boolean"},"product":{"type":"string"},"weapon":{"type":"string"},"decision":{"type":"string","enum":["PROCEED_TO_COMPLIANCE_REVIEW","REVIEW","BLOCK"]},"buyerDecision":{"type":"string","enum":["PROCEED_WITH_REMAINING_CHECKS","HOLD_AND_REVIEW","DO_NOT_PROCEED"]},"reasons":{"type":"array"},"request":{"type":"object"},"counterparty":{"type":"object"},"tariff":{"type":"object"},"financialImpact":{"type":"object"},"buyerQuoteAudit":{"type":"object"},"criticalUnknowns":{"type":"array"},"nextActions":{"type":"array"},"sources":{"type":"array"},"scope":{"type":"object"},"priceUsd":{"type":"number"}}}}}},"400":{"description":"Invalid input"},"402":{"description":"x402 payment required"}}}},"/trade/entry-decision":{"get":{"operationId":"usTradeEntryDecision","summary":"US Trade Entry Decision — buy / hold / block before importing","description":"Enter counterparty, HTS code/product text and origin. Returns OFAC+UK+UN sanctions, GLEIF legal identity, USITC tariff evidence and USTR China Section 301 additional-duty evidence with PROCEED_TO_COMPLIANCE_REVIEW, REVIEW or BLOCK. $0.02 USDC.","parameters":[{"name":"counterparty","in":"query","required":true,"schema":{"type":"string","minLength":2,"maxLength":180}},{"name":"hts","in":"query","required":true,"schema":{"type":"string","minLength":2,"maxLength":120},"example":"8517.13.00.00","description":"Use a full 10-digit code for a numeric estimate. Shorter codes and product text are candidates only; do not pad a buyer code automatically."},{"name":"origin","in":"query","required":true,"schema":{"type":"string","minLength":2,"maxLength":2}},{"name":"customsValueUsd","in":"query","required":false,"schema":{"type":"number","minimum":0,"maximum":1000000000},"description":"Optional customs value in USD for known-duty estimate"},{"name":"buyerBaseRatePercent","in":"query","required":false,"schema":{"type":"number","minimum":0,"maximum":1000},"description":"Compare your GENERAL/BASE_ONLY percent rate quote to exact official USITC HTS"}],"responses":{"200":{"description":"US import preflight decision","content":{"application/json":{"schema":{"type":"object","required":["ok","product","weapon","decision","buyerDecision","reasons","request","counterparty","tariff","financialImpact","criticalUnknowns","nextActions","sources","scope","priceUsd"],"properties":{"ok":{"type":"boolean"},"product":{"type":"string"},"weapon":{"type":"string"},"decision":{"type":"string","enum":["PROCEED_TO_COMPLIANCE_REVIEW","REVIEW","BLOCK"]},"buyerDecision":{"type":"string","enum":["PROCEED_WITH_REMAINING_CHECKS","HOLD_AND_REVIEW","DO_NOT_PROCEED"]},"reasons":{"type":"array"},"request":{"type":"object"},"counterparty":{"type":"object"},"tariff":{"type":"object"},"financialImpact":{"type":"object"},"buyerQuoteAudit":{"type":"object"},"criticalUnknowns":{"type":"array"},"nextActions":{"type":"array"},"sources":{"type":"array"},"scope":{"type":"object"},"priceUsd":{"type":"number"}}}}}},"400":{"description":"Invalid input"},"402":{"description":"x402 payment required"}}}},"/trade/landed-cost-decision":{"get":{"operationId":"usImportLandedCostComplianceDecision","summary":"US Import Landed Cost & Compliance Decision","description":"Combines counterparty sanctions/legal identity, USITC/USTR duty evidence, caller logistics costs and seller quote audit. Returns a known-cost floor, unresolved duty layers and HOLD/PROCEED guidance. $0.03 USDC.","parameters":[{"name":"counterparty","in":"query","required":true,"schema":{"type":"string"}},{"name":"hts","in":"query","required":true,"schema":{"type":"string"},"example":"8517.13.00.00","description":"Full 10-digit HTS needed for a numeric identified-cost floor. Shorter inputs stay unresolved; no automatic code padding."},{"name":"origin","in":"query","required":false,"schema":{"type":"string"}},{"name":"customsValueUsd","in":"query","required":true,"schema":{"type":"number","minimum":0}},{"name":"freightUsd","in":"query","required":false,"schema":{"type":"number","minimum":0}},{"name":"insuranceUsd","in":"query","required":false,"schema":{"type":"number","minimum":0}},{"name":"brokerageUsd","in":"query","required":false,"schema":{"type":"number","minimum":0}},{"name":"otherFeesUsd","in":"query","required":false,"schema":{"type":"number","minimum":0}},{"name":"sellerQuotedLandedCostUsd","in":"query","required":false,"schema":{"type":"number","minimum":0}}],"responses":{"200":{"description":"Landed-cost/compliance decision"},"402":{"description":"x402 payment required"}}}}}}