Rule links and ways in
Copy page
Share a betting rule as a link, link any site's system into Kelly, and send systems in from email, a bookmark, a phone's share sheet or Zapier and Make.
A betting rule in Kelly is a formula that is true or false on each team-game, with the bet it describes: the competition, the market, the side and when it is priced. These pages cover moving a rule between people and tools. Nothing here carries a record, a price or a pick: whoever opens a rule imports it to their own account and tests it there.
Kelly share linksLink to this section
POST /v1/rules:link (Kelly MCP's make_rule_link) packs a rule into a link. It is keyless and free.
curl https://api.askkelly.ai/v1/rules:link \
-H "Content-Type: application/json" \
-d '{"formula": "=AND(home, spread_close >= 3)", "competition": "nfl", "market": "spread",
"name": "Home underdogs of 3 or more"}'The result gives:
url:https://askkelly.ai/rules/open#k1.…. The rule rides after#, which browsers never send to a server, so the link works from any page, email or chat.inputs: each number the formula compares with (spread_close >= 3isin1, value 3), in reading order. Sendinputs: ["in1=7"]with the same rule to get the link for a variant.button_html: a plain<a>link to paste on a page. It has no script, no tracking and no logo.import_arguments: the body that imports the rule as a draft through Kelly's rule import.
A link holds at most a 4,000-character formula. A field Kelly doesn't know, or a value outside its list (market is spread, moneyline, over, under or teaser), is 400 invalid_request with param naming it.
Open in Kelly linksLink to this section
Any site can link a system into Kelly without calling the API. Put the system after # in https://askkelly.ai/rules/open:
| Field | What it holds |
|---|---|
sdql, formula or text | The system: SDQL, a Kelly formula, or words. Exactly one. |
competition, market, side, bet_moment, name | The bet, as in a rule link. Optional. |
from | Your site's name, so the import knows which tool wrote the system. Optional. |
For example, https://askkelly.ai/rules/open#sdql=H%20and%20dog%20and%20line%3E%3D3&competition=nfl&from=yoursite. Encode each value as a URL component. The person sees the system and presses Send; Kelly maps each condition and shows what matched before anything is saved.
Ways in for a personLink to this section
GET /v1/me/rule-import-ways (Kelly MCP's get_my_rule_import_ways, scope read:tracker) lists every way a person can send a system to their account, each with its steps:
- Email. Their own mail-in address. Kelly reads mail sent from their sign-in address only (checked with the receiving server's DMARC or SPF result), and mails back a link to check the draft.
- Bookmarklet.
bookmarklet.hrefis ajavascript:address to drag to the bookmarks bar. It sends the selected text, or the page's main text, to a Kelly window where the person presses Send. - Share sheet. On Android, Kelly installed from Chrome appears in the share sheet for links, text and screenshots. iPhones don't list web apps there; email or paste instead.
- Chrome extension. The full build's Import this system reads the tab the person is on, when they click.
- Links. The Open in Kelly links above.
- Automation. Zapier, Make and n8n call Kelly's rule import with the person's own API key (below).
Zapier, Make and n8nLink to this section
Use each tool's HTTP step (Zapier's Webhooks by Zapier, Make's HTTP module, n8n's HTTP Request node):
- Method
POST, URLhttps://api.askkelly.ai/v1/rules:import. - Header
Authorization: Bearerand the person's own Kelly API key, stored in the tool's secret or connection field, never in the URL. - A JSON body with
text(the system as the trigger gave it),tool(the tool the system came from, in lowercase words joined by underscores),source_kindapi,viazapierormake, anddry_runfalseto keep a draft.
The answer's import ID opens in Ask Kelly ("Open my import imp_…"), where the person checks each condition and confirms. A trigger that fires on every new email or post can create many drafts; unconfirmed drafts expire after 30 days.