Skip to content

feat: add guide on how to become a market maker#19

Open
denbite wants to merge 1 commit intodefuse-protocol:mainfrom
denbite:add-guide-for-becoming-market-maker
Open

feat: add guide on how to become a market maker#19
denbite wants to merge 1 commit intodefuse-protocol:mainfrom
denbite:add-guide-for-becoming-market-maker

Conversation

@denbite
Copy link

@denbite denbite commented Feb 24, 2026

No description provided.

@coderabbitai
Copy link

coderabbitai bot commented Feb 24, 2026

Walkthrough

This pull request adds comprehensive documentation for running a market-maker solver on NEAR Intents, including a new navigation entry in the documentation structure and a detailed implementation guide covering prerequisites, architecture, setup steps, code organization, and customization options.

Changes

Cohort / File(s) Summary
Documentation Structure
docs.json
Added navigation group "Getting started" under Market Makers tab, linking to the new market-maker guide.
Market-Maker Guide
integration/market-makers/become-market-maker-guide.mdx
New comprehensive MDX guide explaining how to run a market-maker solver, including architecture overview, setup instructions (clone, configure, deposit, run), code organization breakdown, customization options, and links to related resources.

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~5 minutes

Poem

🐰 A guide for makers, oh what a sight,
With solvers and intents taking flight,
From setup to code, all laid out clear,
Market-making wisdom is finally here!
✨🥕

🚥 Pre-merge checks | ✅ 2 | ❌ 1

❌ Failed checks (1 inconclusive)

Check name Status Explanation Resolution
Description check ❓ Inconclusive No pull request description was provided by the author, making it impossible to evaluate relevance to the changeset. Add a brief description explaining the purpose of the market maker guide and any key information reviewers should know.
✅ Passed checks (2 passed)
Check name Status Explanation
Title check ✅ Passed The pull request title accurately describes the main change—adding a guide on becoming a market maker, which is clearly reflected in both the documentation file and navigation updates.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 4

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (1)
docs.json (1)

87-110: ⚠️ Potential issue | 🟠 Major

Navigation tabs should be “Home” and “API reference”.

This new page is added under the “Market Makers” tab, but the guidelines require only two tabs. Please relocate the page under the “Home” tab (or adjust the tab structure) to comply.

As per coding guidelines, Configure two navigation tabs in docs.json: 'Home' and 'API reference'.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@docs.json` around lines 87 - 110, The docs.json currently defines a "tab":
"Market Makers" with several groups/pages; per guidelines you must have only two
top-level tabs 'Home' and 'API reference'—update the navigation so the entry
containing the "Market Makers" groups/pages (e.g. pages like
"integration/market-makers/introduction" and all "integration/market-makers/*"
entries under groups "Market Makers", "Message Bus", "Getting started") is moved
under the 'Home' tab (or reorganize into two top-level objects named exactly
'Home' and 'API reference'), remove or rename the existing "tab": "Market
Makers" key, and ensure any links and group objects are preserved under the new
'Home' tab so the docs.json contains only the two required tabs.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In `@docs.json`:
- Around line 105-110: The "Getting started" nested group object in docs.json
(the object with "group": "Getting started" and its "pages" array) is missing a
Font Awesome icon; update that JSON object to add an "icon" property (e.g.,
"icon": "fa-compass" or another appropriate fa- name) so the nested group
includes a Font Awesome icon as required by the navigation guidelines.

In `@integration/market-makers/become-market-maker-guide.mdx`:
- Around line 7-8: The page uses absolute internal links (e.g.,
"/integration/market-makers/message-bus/introduction"); update all internal MDX
links in become-market-maker-guide.mdx (also lines ~26-28) to use relative paths
instead (for example "./message-bus/introduction" or
"../message-bus/introduction" as appropriate), ensuring every internal href that
starts with "/integration/..." is converted to the correct relative path and
that link targets remain valid.
- Around line 137-145: Replace the standalone curl health-check example with a
CodeGroup containing three language variants: a bash variant titled "curl" that
shows `curl http://localhost:3000`, a TypeScript variant (title "TypeScript")
that uses fetch to GET the same URL and logs the JSON, and a Python variant
(title "Python") that uses requests.get(...).json() and prints the result;
locate the existing curl snippet in
integration/market-makers/become-market-maker-guide.mdx and wrap/replace it with
the <CodeGroup> component containing the three code blocks.
- Around line 7-9: Rewrite the two opening sentences (the paragraph starting
"Market makers on NEAR Intents are solvers -- programs that listen for swap
requests...") into second-person voice so the reader is addressed directly (use
"you" and "your"), e.g., explain that you will set up and run an example solver
that connects to the Message Bus, receives live quote requests, and
automatically responds to ones you can fill, and end with a line telling the
reader what they will have by the end; keep the content and meaning the same but
change phrasing to second-person throughout.

---

Outside diff comments:
In `@docs.json`:
- Around line 87-110: The docs.json currently defines a "tab": "Market Makers"
with several groups/pages; per guidelines you must have only two top-level tabs
'Home' and 'API reference'—update the navigation so the entry containing the
"Market Makers" groups/pages (e.g. pages like
"integration/market-makers/introduction" and all "integration/market-makers/*"
entries under groups "Market Makers", "Message Bus", "Getting started") is moved
under the 'Home' tab (or reorganize into two top-level objects named exactly
'Home' and 'API reference'), remove or rename the existing "tab": "Market
Makers" key, and ensure any links and group objects are preserved under the new
'Home' tab so the docs.json contains only the two required tabs.

ℹ️ Review info

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 6e27aea and 4c09165.

📒 Files selected for processing (2)
  • docs.json
  • integration/market-makers/become-market-maker-guide.mdx

Comment on lines +105 to +110
{
"group": "Getting started",
"pages": [
"integration/market-makers/become-market-maker-guide"
]
},
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟡 Minor

Add a Font Awesome icon to the new “Getting started” group.

Nested groups should include an icon.

🧭 Suggested update
-          {
-            "group": "Getting started",
-            "pages": [
-              "integration/market-makers/become-market-maker-guide"
-            ]
-          },
+          {
+            "group": "Getting started",
+            "icon": "rocket",
+            "pages": [
+              "integration/market-makers/become-market-maker-guide"
+            ]
+          },

As per coding guidelines, Use nested groups with Font Awesome icons for navigation in docs.json.

📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
{
"group": "Getting started",
"pages": [
"integration/market-makers/become-market-maker-guide"
]
},
{
"group": "Getting started",
"icon": "rocket",
"pages": [
"integration/market-makers/become-market-maker-guide"
]
},
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@docs.json` around lines 105 - 110, The "Getting started" nested group object
in docs.json (the object with "group": "Getting started" and its "pages" array)
is missing a Font Awesome icon; update that JSON object to add an "icon"
property (e.g., "icon": "fa-compass" or another appropriate fa- name) so the
nested group includes a Font Awesome icon as required by the navigation
guidelines.

Comment on lines +7 to +8
Market makers on NEAR Intents are solvers -- programs that listen for swap requests, decide whether to fill them, and respond with signed quotes. In this guide, you'll set up and run an example solver that connects to the [Message Bus](/integration/market-makers/message-bus/introduction), receives live quote requests, and automatically responds to the ones it can fill.

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟡 Minor

Switch internal links to relative paths.

Internal links currently use absolute paths (e.g., /integration/...). Please convert all internal links on this page to relative paths.

🔧 Example adjustments
-...connects to the [Message Bus](/integration/market-makers/message-bus/introduction)...
+...connects to the [Message Bus](./message-bus/introduction)...

-...transmitted to the [Verifier contract](/integration/verifier-contract/introduction)...
+...transmitted to the [Verifier contract](../verifier-contract/introduction)...

As per coding guidelines, Use relative paths for all internal links in MDX documentation files.

Also applies to: 26-28

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@integration/market-makers/become-market-maker-guide.mdx` around lines 7 - 8,
The page uses absolute internal links (e.g.,
"/integration/market-makers/message-bus/introduction"); update all internal MDX
links in become-market-maker-guide.mdx (also lines ~26-28) to use relative paths
instead (for example "./message-bus/introduction" or
"../message-bus/introduction" as appropriate), ensuring every internal href that
starts with "/integration/..." is converted to the correct relative path and
that link targets remain valid.

Comment on lines +7 to +9
Market makers on NEAR Intents are solvers -- programs that listen for swap requests, decide whether to fill them, and respond with signed quotes. In this guide, you'll set up and run an example solver that connects to the [Message Bus](/integration/market-makers/message-bus/introduction), receives live quote requests, and automatically responds to the ones it can fill.

By the end, you'll have a working solver running locally and a clear understanding of how to customize it.
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟡 Minor

Rewrite the opening definition in second-person voice.

The intro is written in third-person; please address the reader directly.

✏️ Suggested rewrite
-Market makers on NEAR Intents are solvers -- programs that listen for swap requests, decide whether to fill them, and respond with signed quotes. In this guide, you'll set up and run an example solver that connects to the [Message Bus](/integration/market-makers/message-bus/introduction), receives live quote requests, and automatically responds to the ones it can fill.
+As a market maker on NEAR Intents, you run a solver — a program that listens for swap requests, decides whether to fill them, and responds with signed quotes. In this guide, you'll set up and run an example solver that connects to the [Message Bus](/integration/market-makers/message-bus/introduction), receives live quote requests, and automatically responds to the ones you can fill.

As per coding guidelines, Write in second-person voice ('you') in all documentation content.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@integration/market-makers/become-market-maker-guide.mdx` around lines 7 - 9,
Rewrite the two opening sentences (the paragraph starting "Market makers on NEAR
Intents are solvers -- programs that listen for swap requests...") into
second-person voice so the reader is addressed directly (use "you" and "your"),
e.g., explain that you will set up and run an example solver that connects to
the Message Bus, receives live quote requests, and automatically responds to
ones you can fill, and end with a line telling the reader what they will have by
the end; keep the content and meaning the same but change phrasing to
second-person throughout.

Comment on lines +137 to +145
Check the health endpoint to confirm the solver is running:

```bash
curl http://localhost:3000
```

```json
{"ready": true}
```
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟡 Minor

Wrap the health-check example in a CodeGroup with curl/TypeScript/Python variants.

The curl-only example should be presented as a multi-language CodeGroup.

🧩 Suggested structure
-```bash
-curl http://localhost:3000
-```
+<CodeGroup>
+```bash title="curl"
+curl http://localhost:3000
+```
+```ts title="TypeScript"
+const res = await fetch("http://localhost:3000");
+console.log(await res.json());
+```
+```py title="Python"
+import requests
+print(requests.get("http://localhost:3000").json())
+```
+</CodeGroup>

As per coding guidelines, Use component with curl, TypeScript, and Python code variants for code examples.

📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
Check the health endpoint to confirm the solver is running:
```bash
curl http://localhost:3000
```
```json
{"ready": true}
```
Check the health endpoint to confirm the solver is running:
<CodeGroup>
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@integration/market-makers/become-market-maker-guide.mdx` around lines 137 -
145, Replace the standalone curl health-check example with a CodeGroup
containing three language variants: a bash variant titled "curl" that shows
`curl http://localhost:3000`, a TypeScript variant (title "TypeScript") that
uses fetch to GET the same URL and logs the JSON, and a Python variant (title
"Python") that uses requests.get(...).json() and prints the result; locate the
existing curl snippet in integration/market-makers/become-market-maker-guide.mdx
and wrap/replace it with the <CodeGroup> component containing the three code
blocks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant