{"uid":"cap_0Cq2X3acIGpM73WXwSDRM","slug":"mapbox-directions-via-gateway-apiosk-com-7d5f2b18","name":"Mapbox Directions via gateway.apiosk.com","description":"API call to mapbox","url":"https://gateway.apiosk.com/mapbox/directions","method":"GET","headers":{},"bodySchema":{"type":"object","properties":{"required":{"type":"string"},"properties":{"type":"string"}}},"responseSchema":{"code":"Ok","routes":[{"legs":[{"steps":[],"weight":155793.359,"summary":"I 80, I 80 East","distance":4538142,"duration":155332.75}],"weight":155793.359,"distance":4538142,"duration":155332.75,"geometry":"s|qeFbdejV}hhG{jbHqa|A_enIsnrGsh{H`apAekuCqv`B{xzI","weight_name":"auto"}],"waypoints":[{"name":"McAllister Street","distance":11.321,"location":[-122.420019,37.780101]},{"name":"Logan Circle Northwest","distance":11.763,"location":[-77.030091,38.910078]}]},"example":null,"exampleRequest":null,"tags":["x402"],"displayCostAmount":"0.17","displayCostAsset":"USDC","priceDynamic":false,"priceHint":null,"priceStatus":"priced","priceSource":"probe","requiresHandshake":false,"reviewCount":0,"rating":{"score":"0.00","successRate":"0.00","reviews":0,"stars":null,"state":"unrated"},"availabilityStatus":"down","priceObserved":null,"sessionDeposit":null,"pricing":{"kind":"static","summary":"$0.17/call","primary":{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.17","per":"call","confidence":"exact"},"accepted":[{"kind":"static","protocol":"x402","network":"base","amountUsd":"0.17","per":"call","confidence":"exact"}]},"paymentMethods":[{"uid":"pm_dWddRTyIQI_N52EA64_Jq","protocol":"x402","methodType":"crypto","chain":"base","mode":"charge","costAmount":"0.17","costPer":"request","priority":0,"asset":"0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913","unit":"request","depositMicros":null,"planRef":null}],"brandName":null,"brandSlug":null,"brandBaseUrl":null,"brandDocsUrl":null,"whatItDoes":"Returns turn-by-turn driving directions, route geometry, duration, and distance between two or more waypoints using the Mapbox Directions API","exampleAgentPrompt":"What's the best driving route from San Francisco, CA to Washington, DC — give me the distance, travel time, and the route geometry so I can plot it on a map.","exampleUseCases":[{"title":"Calculate delivery time between locations","prompt":"I need to know how long it'll take my driver to get from the warehouse to each customer's address today — can you map out the routes and give me the total drive times?"},{"title":"Plan multi-stop road trip itinerary","prompt":"I'm planning a road trip from Seattle to Los Angeles with stops in Portland, San Francisco, and San Diego — what's the best route order and how far is each leg?"},{"title":"Generate ETA for field service dispatch","prompt":"My technician is heading to three service calls across the city — plot the most efficient driving route between them and tell me how long each drive should take."}],"resultDescription":"Returns a JSON object with an 'Ok' status code, an array of routes each containing legs with steps, total weight, distance (in meters), duration (in seconds), and an encoded polyline geometry string, plus waypoint details including matched street names and precise coordinates.","failureModes":["Invalid or missing coordinate parameters return an error response","Unreachable routes between waypoints (e.g. across oceans without ferry routing) may return no routes","Malformed request parameters cause API rejection","Rate limiting or upstream Mapbox API errors may cause failures","Payment of 0.12 USDC required per call; failed payment returns 402"],"whenToPreferThis":"Use this endpoint when you need Mapbox-powered driving directions with encoded polyline geometry, step-by-step route legs, and precise distance/duration data — especially when integrating with Mapbox map rendering or when you need the x402 micropayment-compatible API gateway. Prefer over raw Mapbox API when you want a pre-authenticated pay-per-call model without managing Mapbox API keys.","instructions":null,"reviewSummary":null,"reviewSummaryHighlights":null,"reviewSummaryConcerns":null,"reviewSummaryGeneratedAt":null,"activationCount":0,"lastUsedAt":null,"lastSuccessfullyRanAt":null,"lastHealthCheckAt":"2026-09-15T09:26:42.202Z","isFirstParty":false}