Skip to main content
Glama

Server Configuration

Describes the environment variables required to run the server.

NameRequiredDescriptionDefault
FORAN_PHONENoOptional Foran account phone number. When running locally via stdio, this lets foran_login work without typing your password into the chat.
FORAN_PASSWORDNoOptional Foran account password, used together with FORAN_PHONE for local stdio setup.
FORAN_MCP_SECRETNoSecret for self-hosting the HTTP server. Set to 32+ random characters when running with --http.

Instructions

Guidance the server publishes about itself, which clients place ahead of the tool catalog so the model reads it before choosing anything.

Foran Delivery is a quick-commerce service for groceries (Mart) and restaurant food (Bites) from local stores, live in Bahria Town Karachi and Hyderabad, Pakistan. Prices are in Pakistani Rupees (Rs). How to help a customer:

  1. Ask which area they are in (city = bahria_town_karachi or hyderabad, or use foran_find_location).

  2. Use foran_search_products / foran_list_stores / foran_categories to find items. One order = one store, so keep a basket to a single store.

  3. To order, the customer logs in with foran_login (their own Foran phone + password). Use the returned session_key for cart and order tools.

  4. Add items with foran_cart_add, pick a saved address with foran_my_addresses, then call foran_place_order WITHOUT confirm, show the summary, and only after the customer says yes call it again with confirm=true.

  5. Customer sends a list, product names or photos (even items not in the app)? Use foran_custom_order: one store, catalogue items by item_id, other items by name with an honest estimated_price_rs; quote first, confirm=true only after a yes. It lands in the Foran admin as a "Claude order". Foran staff log in with foran_staff_login to order for WhatsApp customers.

  6. "Where is my order?" → foran_order_status (live stage, timeline, rider) or foran_track_order (order_id + phone). How Foran works / how to buy → foran_buying_guide. Never invent prices, stock or delivery promises; delivery is usually 40-60 minutes. Foran gives 4% cashback to Foran Money on every delivered order, and new customers get free delivery on their first order with code FORANDELIVERY. Support: WhatsApp +92 333 998 8891.

Capabilities

Features and capabilities supported by this server

Protocol revision2025-11-25

CapabilityDetails
tools
{
  "listChanged": true
}

Tools

Functions exposed to the LLM to take actions

NameDescription
foran_aboutA

Facts about Foran Delivery: live areas, delivery time, hours, cashback, first-order promo, payment options, contact and app links. Call this first when a user asks what Foran is or where it delivers.

foran_find_locationA

Turn an address or area name (e.g. 'Precinct 10 Bahria Town', 'Qasimabad Hyderabad') into coordinates and check whether Foran delivers there.

foran_search_productsA

Search Foran's catalogue (groceries in Mart, food in Bites) near the customer. Returns item_id, price in Rs, store, stock and a link. Prices include current discounts.

foran_list_storesB

Stores (Mart) or restaurants (Bites) that deliver to the customer's area, with open status, minimum order and distance.

foran_store_detailsC

Details of one store plus its popular items.

foran_product_detailsA

Full details of one product, including required options (size, flavour, add-ons) needed before adding it to the cart.

foran_categoriesA

List product categories (e.g. Milk & Dairy, Fruits & Vegetables) or, with category_id, the items inside one category.

foran_policyA

Read a Foran policy: terms, privacy, refund, cancellation, delivery, or about.

foran_track_orderB

Status of an order. Logged-in customers pass session_key; guest orders need the phone number used on the order.

searchB

Search Foran products in all live areas (Bahria Town Karachi and Hyderabad). Returns ids usable with fetch.

fetchA

Fetch full details for an id returned by search (format product:<item_id>:).

foran_loginA

Log in with the customer's own Foran phone number and password (the same as the Foran app). Returns a session_key for cart, order and account tools. Only use credentials the customer typed themselves in this conversation. On a local install, credentials may instead come from FORAN_PHONE / FORAN_PASSWORD environment variables (call with no arguments).

foran_my_accountC

Customer profile: name, phone, Foran Money (wallet) balance, loyalty points and order count.

foran_my_addressesA

The customer's saved delivery addresses (address_id is needed to place an order). New addresses are added in the Foran app or website.

foran_walletB

Recent Foran Money (wallet) transactions: cashback, top-ups and payments.

foran_couponsA

Coupons the logged-in customer can use (code, discount, minimum order).

foran_cart_viewA

Show the customer's current Foran cart for Mart or Bites, with line totals and subtotal.

foran_cart_addA

Add a product to the customer's cart. All items in one order must come from the same store. If the product has options, pass them (see foran_product_details).

foran_cart_updateA

Set a new quantity for one cart line (cart_id from foran_cart_view). Quantity 0 removes it.

foran_cart_removeA

Remove one cart line (cart_id) or empty the whole cart (all=true).

foran_place_orderA

Check out the current cart to a saved address. First call WITHOUT confirm to get the order summary and show it to the customer. Only after the customer clearly says yes, call again with confirm=true to place the real order. Payment: cash_on_delivery or wallet (Foran Money). Orders placed here carry the MCP fee (Rs 150) instead of the app's processing fee; always show it in the summary.

foran_my_ordersB

The customer's running (active) orders or past order history.

foran_order_detailsC

Items, prices and status of one of the customer's orders.

foran_cancel_orderA

Cancel an order that the store has not started yet (status pending). Ask the customer to confirm first, then call with confirm=true.

foran_buying_guideA

Practical guide to buying from Foran Delivery: how ordering works, one-store rule, delivery charges, free delivery, minimum order, payment, Foran Money top-up, cashback, custom orders from photos/lists, cancellation and refunds. Use it whenever a customer asks how Foran works or how to order.

foran_staff_loginA

For the Foran team only. Unlock staff tools (custom orders for any customer, e.g. from WhatsApp, and order status for any order) with the Foran staff key. Returns a staff_session valid for 7 days. Only use a key the user typed in this conversation.

foran_custom_orderA

Create a Foran order from what the customer sent: product names, a shopping list, or photos. Mix catalogue items (item_id) with custom items that are not in the app (name + estimated_price_rs). All items must be bought from ONE store: pick the nearest open store that has most items (foran_list_stores / foran_search_products). The order lands in the Foran admin panel as a pending 'Claude order' with the photos attached; the team confirms custom prices before dispatch. Who can use it: a logged-in customer (session_key; the order goes on their account) or Foran staff (staff_session; any customer name + phone, e.g. a WhatsApp customer). ALWAYS call first WITHOUT confirm: it returns the quote (items, delivery charge, MCP fee Rs 150, total, warnings). Show it to the user, and only after a clear yes call again with the same inputs and confirm=true. Cash on delivery.

foran_order_statusA

Real-time status of a Foran order: stage with plain-language meaning, timeline, store, rider name and phone, items, delivery charge, total and payment. Customers: pass session_key (only their own orders). Staff: pass staff_session plus order_id or the customer's phone (latest 5 orders). Use this whenever someone asks 'where is my order?'.

Prompts

Interactive templates invoked by user choice

NameDescription

No prompts

Resources

Contextual data attached and managed by the client

NameDescription

No resources

TDQS

B3.2/5.0

Scored across 28 tools

Disambiguation3/5

Several clusters overlap meaningfully: foran_track_order vs foran_order_status vs foran_order_details all return order status/contents, and the generic search/fetch duplicate foran_search_products/foran_product_details with a different id scheme. foran_cart_remove vs foran_cart_update (quantity 0 removes) and foran_about vs foran_policy (which includes an 'about' topic) vs foran_buying_guide also blur together. Descriptions do give hints (guest vs logged-in, all-areas vs near-customer), so an agent can usually recover, but misselection is likely.

Naming Consistency3/5

Most tools follow foran_<verb>_<noun> (foran_cart_add, foran_place_order, foran_track_order), but the set mixes noun-only names (foran_wallet, foran_coupons, foran_about, foran_policy), a 'my_' family (foran_my_account, foran_my_orders, foran_my_addresses), and two bare verbs (search, fetch) with no server prefix. Similar functions use different conventions (foran_track_order vs foran_order_status), so the pattern is readable but not predictable.

Tool Count3/5

28 tools is heavy and sits just above the range where an agent can scan the surface comfortably, though a delivery app domain (cart, catalogue, orders, account, policies, staff) legitimately needs many operations. Some slots are redundant (search/fetch duplicating the foran_search_products / foran_product_details pair, and track_order/order_status), so trimming would help.

Completeness4/5

Coverage is broad: full cart CRUD, search/discovery, store and product details, checkout with confirmation, order listing, details, cancellation, tracking, wallet/coupons/account, staff and custom-order flows. The main gaps are address creation (explicitly punted to the app, a dead end for agents) and wallet top-up, neither of which blocks the core ordering lifecycle.

Maintenance

ActivityMaintained
ResponsivenessNo recent community issues