Purpose
Find open Uber Eats delivery options for a supplied destination, including restaurant search results and alcohol/beer delivery, and optionally stage selected items in the cart without submitting checkout.
When to Use
Use when the caller provides a delivery address and product or cuisine requirements such as ramen and beer. The destination must be resolved first because Uber Eats encodes a location payload, including a provider reference and coordinates, in the pl query parameter.
Workflow
- Resolve the destination once. Navigate to
https://www.ubereats.com/{locale}(the observed locale isjp-en), enter{address}ininput#location-typeahead-home-input, wait for suggestions, and select the matchingli#location-typeahead-home-item-0or the exact matching suggestion. Read the resulting URL'splparameter; preserve that encoded value for all subsequent navigations. Do not guess the provider reference or coordinates. - Search the requested food category directly with one navigation:
https://www.ubereats.com/{locale}/search?eventSource=searchTextV2&pl={pl}&q={query}&sc=SEARCH_SUGGESTION&searchEntered={query}&searchType=GLOBAL_SEARCH&vertical=ALLAdddiningMode=DELIVERYwhen needed. After the page loads, run the restaurant extractor below. Keep only cards whose text indicates delivery and does not indicate closed/unavailable; return the store URL and visible availability, fees, ETA, and cuisine details. - For beer or other alcohol, navigate directly to
https://www.ubereats.com/feeds/alcohol_feedand, when supported by the locale, use the locale-prefixed equivalent or a discovered alcohol-feed link. Store links from this feed can be opened directly with?diningMode=DELIVERY&pl={pl}&surfaceName=VERTICAL_FEED_ALCOHOL. Run the alcohol extractor below and retain beer-containing item/category text rather than assuming every alcohol item is beer. - Open selected store URLs directly. Store pages use an opaque final path identifier; preserve the complete store URL returned by the search/feed rather than constructing or guessing an ID. Add selected items with the stable
button[data-testid='add-to-cart-button']; useselectfor required options andbutton[data-testid='item-stepper-inc']for quantity changes when present. - Stage choices only: inspect the cart through
[data-testid='go-to-checkout-button']and the surrounding cart container, verify store, item, quantity, and subtotal, and stop before clicking the checkout control or submitting an order. Alcohol purchases may require sign-in, age verification, or other eligibility checks; do not bypass them.
Restaurant search extractor
Run as evaluate() on the loaded search page:
(() =>
[...document.querySelectorAll('a[data-testid="store-card"]')]
.map((a) => {
const text = (a.innerText || "").trim();
const lines = text
.split(/\n+/)
.map((x) => x.trim())
.filter(Boolean);
const unavailable =
/closed|unavailable|not accepting|currently unavailable|temporarily closed/i.test(
text,
);
return {
name: lines[0] || "",
href: a.href,
text: text.slice(0, 1200),
open: !unavailable,
delivery: /delivery|deliver/i.test(text),
};
})
.filter((x) => x.name))();Alcohol/beer extractor
Run as evaluate() on the loaded alcohol feed or alcohol store page. It handles store cards and visible item/category links without assuming a single card structure:
(() => {
const nodes = [
...document.querySelectorAll('a[data-testid="store-card"],a[href*="/store/"]'),
];
const seen = new Set();
return nodes
.map((a) => {
const href = a.href || "";
const text = (a.innerText || "").trim();
if (!href || seen.has(href) || !text) return null;
seen.add(href);
const lines = text
.split(/\n+/)
.map((x) => x.trim())
.filter(Boolean);
return {
name: lines[0] || "",
href,
text: text.slice(0, 1600),
open: !/closed|unavailable|not accepting|temporarily closed/i.test(text),
beer: /\bbeer\b|ビール|lager|ale|stout|pilsner|ipa/i.test(text),
alcohol: /alcohol|liquor|酒|ビール|ワイン|wine|sake/i.test(text),
};
})
.filter((x) => x && x.alcohol)
.filter((x) => x.open || x.beer);
})();Site-Specific Gotchas
- The destination payload is a URL-safe encoded JSON object in
pl; observed fields includeaddress,reference,referenceType,latitude, andlongitude. Reuse the exact encoded value produced by Uber Eats for the current destination. - Address autocomplete may reject an English or Japanese freeform entry; retry with the postal code plus local Japanese address, then choose the exact suggestion rather than the first arbitrary button.
- Search state is directly reachable with
q,searchEntered,searchType,vertical, andeventSource; avoid homepage search typing onceplis known. - Alcohol uses a separate
/feeds/alcohol_feedsurface and may omit the/jp-enlocale prefix in observed links. Preserve the returned store href and append the destination payload rather than guessing a locale or store identifier. - Store slugs are human-readable but the trailing store ID is opaque. Use the href emitted by
a[data-testid="store-card"]or the alcohol feed. - Store item pages can contain frozen versions, modifiers, and quick-view links. Match the requested item text carefully and exclude similarly named frozen or unavailable products.
- Cart controls are dynamic. Prefer
data-testidselectors; avoid generated CSS classes. Staging must end beforea[data-testid='go-to-checkout-button']is activated. - Alcohol availability, age checks, delivery hours, and inventory are destination- and time-dependent; report the visible state rather than treating a store as permanently open.
Expected Output
Return the resolved destination, the direct search/feed URLs used, and structured lists of open ramen restaurants and open alcohol stores/items with names, URLs, visible delivery/ETA/fee information, and beer matches. If choices were staged, report each store, item, modifier, quantity, and cart subtotal, explicitly stating that checkout and order submission were not performed.