### Response 200 example for GET /plants Source: https://help.b2proxy.com/api-reference/endpoint/get Example of a successful response containing a JSON array of plant objects with name and tag fields. ```json [ { "name": "", "tag": "" } ] ``` -------------------------------- ### Response 400 example for GET /plants Source: https://help.b2proxy.com/api-reference/endpoint/get Example of an error response with an error code and message. ```json { "error": 123, "message": "" } ``` -------------------------------- ### Bash: Install Node.js and package on Linux Source: https://help.b2proxy.com/ai-tools/cursor Alternative installation commands for Linux using apt. Installs Node.js and npm, then installs a package globally. ```bash sudo apt install nodejs npm npm install -g package-name ``` -------------------------------- ### Bash: Install Node.js and package on macOS Source: https://help.b2proxy.com/ai-tools/cursor Alternative installation commands for macOS using Homebrew. Installs Node.js and then installs a package globally. ```bash brew install node npm install -g package-name ``` -------------------------------- ### Start preview server: mint dev Source: https://help.b2proxy.com/quickstart Starts the Mintlify development server from the docs directory. The live site is available at http://localhost:3000 and updates automatically as you edit files. ```bash mint dev ``` -------------------------------- ### Request example (cURL POST) Source: https://help.b2proxy.com/ai-tools/cursor Shows a cURL POST request to create a user, demonstrating the Mintlify RequestExample component. ```bash curl -X POST 'https://api.example.com/users' \ -H 'Content-Type: application/json' \ -d '{"name": "John Doe", "email": "john@example.com"}' ``` -------------------------------- ### PowerShell: Install Node.js and package on Windows Source: https://help.b2proxy.com/ai-tools/cursor Alternative installation commands for Windows using Chocolatey. Installs Node.js and then installs a package globally. ```powershell choco install nodejs npm install -g package-name ``` -------------------------------- ### Install Mintlify CLI globally Source: https://help.b2proxy.com/development Install the Mintlify CLI globally using npm. Requires Node.js version 19 or higher. ```bash npm i -g mint ``` -------------------------------- ### Response example (JSON Success) Source: https://help.b2proxy.com/ai-tools/cursor Shows a JSON response for a successful user creation, demonstrating the Mintlify ResponseExample component. ```json { "id": "user_123", "name": "John Doe", "email": "john@example.com", "created_at": "2024-01-15T10:30:00Z" } ``` -------------------------------- ### Go GET /plants Source: https://help.b2proxy.com/api-reference/endpoint/get Uses the net/http package to send a GET request with a Bearer token and prints the response body. ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "http://sandbox.mintlify.com/plants" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("Authorization", "Bearer ") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(string(body)) } ``` -------------------------------- ### Single code block example (config.js) Source: https://help.b2proxy.com/ai-tools/cursor Shows a single code block using the config.js filename, demonstrating the Mintlify single code block component. ```javascript const apiConfig = { baseURL: 'https://api.example.com', timeout: 5000, headers: { 'Authorization': `Bearer ${process.env.API_TOKEN}` } }; ``` -------------------------------- ### Create workspace rules in .windsurf/rules.md Source: https://help.b2proxy.com/ai-tools/windsurf Defines project context, writing standards, required page structure, and Mintlify component usage for the AI assistant. Place this file in the project root to guide Windsurf's behavior. ```markdown # Mintlify technical writing rule ## Project context - This is a documentation project on the Mintlify platform - We use MDX files with YAML frontmatter - Navigation is configured in `docs.json` - We follow technical writing best practices ## Writing standards - Use second person ("you") for instructions - Write in active voice and present tense - Start procedures with prerequisites - Include expected outcomes for major steps - Use descriptive, keyword-rich headings - Keep sentences concise but informative ## Required page structure Every page must start with frontmatter: ```yaml --- title: "Clear, specific title" description: "Concise description for SEO and navigation" --- ``` ## Mintlify components ### Callouts - `` for helpful supplementary information - `` for important cautions and breaking changes - `` for best practices and expert advice - `` for neutral contextual information - `` for success confirmations ### Code examples - When appropriate, include complete, runnable examples - Use `` for multiple language examples - Specify language tags on all code blocks - Include realistic data, not placeholders - Use `` and `` for API docs ### Procedures - Use `` component for sequential instructions - Include verification steps with `` components when relevant - Break complex procedures into smaller steps ### Content organization - Use `` for platform-specific content - Use `` for progressive disclosure - Use `` and `` for highlighting content - Wrap images in `` components with descriptive alt text ## API documentation requirements - Document all parameters with `` - Show response structure with `` - Include both success and error examples - Use `` for nested object properties - Always include authentication examples ## Quality standards - Test all code examples before publishing - Use relative paths for internal links - Include alt text for all images - Ensure proper heading hierarchy (start with h2) - Check existing patterns for consistency ``` -------------------------------- ### Inline code example Source: https://help.b2proxy.com/essentials/code Shows how to denote a word or phrase as code by enclosing it in backticks. ```markdown To denote a `word` or `phrase` as code, enclose it in backticks (`). ``` -------------------------------- ### Webhook Request Body Example Source: https://help.b2proxy.com/api-reference/endpoint/webhook Example JSON payload for the webhook. Contains fields name (string), id (integer), and tag (string). ```json { "name": "", "id": 123, "tag": "" } ``` -------------------------------- ### Java Unirest GET /plants Source: https://help.b2proxy.com/api-reference/endpoint/get Uses the Unirest library to send a GET request with a Bearer token and returns the response as a string. ```java HttpResponse response = Unirest.get("http://sandbox.mintlify.com/plants") .header("Authorization", "Bearer ") .asString(); ``` -------------------------------- ### JavaScript: Advanced configuration object Source: https://help.b2proxy.com/ai-tools/cursor Example configuration object for advanced settings, including performance and security options. Used in the 'Advanced configuration' accordion. ```javascript const config = { performance: { cache: true, timeout: 30000 }, security: { encryption: 'AES-256' } }; ``` -------------------------------- ### Obtain API token: Success response (200) Source: https://help.b2proxy.com/api-referance/sub-user-api Example of a successful response from the /wapi/token/ endpoint, returning an access token. ```json { "code":200, "message":"sucess.", "results":{ "token":"3a0f1f6b9c7f4f69a4f8a3d6" } } ``` -------------------------------- ### Install Claude Code globally Source: https://help.b2proxy.com/ai-tools/claude-code Installs Claude Code globally via npm. Requires an active Claude subscription (Pro, Max, or API access). ```bash npm install -g @anthropic-ai/claude-code ``` -------------------------------- ### JavaScript fetch GET /plants Source: https://help.b2proxy.com/api-reference/endpoint/get Uses the fetch API to make a GET request with a Bearer token and logs the JSON response. ```javascript const options = {method: 'GET', headers: {Authorization: 'Bearer '}}; fetch('http://sandbox.mintlify.com/plants', options) .then(res => res.json()) .then(res => console.log(res)) .catch(err => console.error(err)); ``` -------------------------------- ### Ruby Net::HTTP GET /plants Source: https://help.b2proxy.com/api-reference/endpoint/get Uses the Net::HTTP library to send a GET request with a Bearer token and prints the response body. ```ruby require 'uri' require 'net/http' url = URI("http://sandbox.mintlify.com/plants") http = Net::HTTP.new(url.host, url.port) request = Net::HTTP::Get.new(url) request["Authorization"] = 'Bearer ' response = http.request(request) puts response.read_body ``` -------------------------------- ### Python requests GET /plants Source: https://help.b2proxy.com/api-reference/endpoint/get Uses the requests library to fetch the plants list with a Bearer token and prints the response text. ```python import requests url = "http://sandbox.mintlify.com/plants" headers = {"Authorization": "Bearer "} response = requests.get(url, headers=headers) print(response.text) ``` -------------------------------- ### Query data usage: Success response (200) Source: https://help.b2proxy.com/api-referance/sub-user-api Example of a successful response from the /wapi/consume/chart/ endpoint, returning traffic consumption data within a specified time range. ```json { "code":200, "message":"sucess.", "results":[ { "period":"2026-08-19T00:00:00+08:00", "timestamp":0, "total_traffic_count":0 } ] } ``` -------------------------------- ### GET /plants Source: https://help.b2proxy.com/api-reference/endpoint/get Fetches a list of plants. Requires a bearer token for authentication. Optionally accepts a limit query parameter to restrict the number of results. ```APIDOC ## GET /plants ### Description Retrieves a list of plants. ### Method GET ### Endpoint http://sandbox.mintlify.com/plants ### Parameters #### Query Parameters - **limit** (integer) - Optional - The maximum number of results to return ### Request Example ``` curl --request GET \ --url http://sandbox.mintlify.com/plants \ --header 'Authorization: Bearer ' ``` ### Response #### Success Response (200) - **name** (string) - Required - The name of the plant - **tag** (string) - Tag to specify the type #### Response Example ``` [ { "name": "", "tag": "" } ] ``` #### Error Response (400) - **error** (integer) - Error code - **message** (string) - Error message #### Error Response Example ``` { "error": 123, "message": "" } ``` ### Authorizations - **Authorization** (string, header, required) - Bearer authentication header of the form `Bearer `, where `` is your auth token. ``` -------------------------------- ### Preview documentation locally with mint dev Source: https://help.b2proxy.com/development Run the Mintlify development server to preview your documentation locally. Navigate to your docs directory containing docs.json first. The preview will be available at http://localhost:3000. ```bash mint dev ``` -------------------------------- ### cURL request to GET /plants Source: https://help.b2proxy.com/api-reference/endpoint/get Sends a GET request to the plants endpoint using cURL with a Bearer token in the Authorization header. ```bash curl --request GET \ --url http://sandbox.mintlify.com/plants \ --header 'Authorization: Bearer ' ``` -------------------------------- ### PHP cURL GET /plants Source: https://help.b2proxy.com/api-reference/endpoint/get Uses PHP cURL to send a GET request with a Bearer token and outputs the response or an error. ```php "http://sandbox.mintlify.com/plants", CURLOPT_RETURNTRANSFER => true, CURLOPT_ENCODING => "", CURLOPT_MAXREDIRS => 10, CURLOPT_TIMEOUT => 30, CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1, CURLOPT_CUSTOMREQUEST => "GET", CURLOPT_HTTPHEADER => [ "Authorization: Bearer " ], ]); $response = curl_exec($curl); $err = curl_error($curl); curl_close($curl); if ($err) { echo "cURL Error #:" . $err; } else { echo $response; } ``` -------------------------------- ### Go http POST to create a plant Source: https://help.b2proxy.com/api-reference/endpoint/create Sends a POST request using the net/http package with a JSON body and required headers. Prints the response body. ```go package main import ( "fmt" "strings" "net/http" "io" ) func main() { url := "http://sandbox.mintlify.com/plants" payload := strings.NewReader("{\n \"name\": \"\",\n \"id\": 123,\n \"tag\": \"\"\n}") req, _ := http.NewRequest("POST", url, payload) req.Header.Add("Authorization", "Bearer ") req.Header.Add("Content-Type", "application/json") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(string(body)) } ``` -------------------------------- ### Create .cursor directory Source: https://help.b2proxy.com/ai-tools/cursor Creates the .cursor directory in the documentation repository root, required for project rules. ```bash mkdir -p .cursor ``` -------------------------------- ### Create a snippet file with default export Source: https://help.b2proxy.com/essentials/reusable-snippets Create a file in the 'snippets' directory with content to reuse. Optionally include variables like {word} that can be filled via props when imported. ```mdx Hello world! This is my content I want to reuse across pages. My keyword of the day is {word}. ``` -------------------------------- ### Import and use the snippet in a destination file Source: https://help.b2proxy.com/essentials/reusable-snippets Import the snippet using its path and render it as a component, passing props like word. ```mdx --- title: My title description: My Description --- import MySnippet from '/snippets/path/to/my-snippet.mdx'; ## Header Lorem impsum dolor sit amet. ``` -------------------------------- ### Create .cursor/rules.md Source: https://help.b2proxy.com/ai-tools/cursor Defines project rules for Cursor to follow when writing technical documentation with Mintlify components. ```markdown # Mintlify technical writing rule You are an AI writing assistant specialized in creating exceptional technical documentation using Mintlify components and following industry-leading technical writing practices. ## Core writing principles ### Language and style requirements - Use clear, direct language appropriate for technical audiences - Write in second person ("you") for instructions and procedures - Use active voice over passive voice - Employ present tense for current states, future tense for outcomes - Avoid jargon unless necessary and define terms when first used - Maintain consistent terminology throughout all documentation - Keep sentences concise while providing necessary context - Use parallel structure in lists, headings, and procedures ### Content organization standards - Lead with the most important information (inverted pyramid structure) - Use progressive disclosure: basic concepts before advanced ones - Break complex procedures into numbered steps - Include prerequisites and context before instructions - Provide expected outcomes for each major step - Use descriptive, keyword-rich headings for navigation and SEO - Group related information logically with clear section breaks ### User-centered approach - Focus on user goals and outcomes rather than system features - Anticipate common questions and address them proactively - Include troubleshooting for likely failure points - Write for scannability with clear headings, lists, and white space - Include verification steps to confirm success ## Mintlify component reference ### Callout components #### Note - Additional helpful information Supplementary information that supports the main content without interrupting flow #### Tip - Best practices and pro tips Expert advice, shortcuts, or best practices that enhance user success #### Warning - Important cautions Critical information about potential issues, breaking changes, or destructive actions #### Info - Neutral contextual information Background information, context, or neutral announcements #### Check - Success confirmations Positive confirmations, successful completions, or achievement indicators ### Code components #### Single code block Example of a single code block: ```javascript config.js const apiConfig = { baseURL: 'https://api.example.com', timeout: 5000, headers: { 'Authorization': `Bearer ${process.env.API_TOKEN}` } }; ``` #### Code group with multiple languages Example of a code group: ```javascript Node.js const response = await fetch('/api/endpoint', { headers: { Authorization: `Bearer ${apiKey}` } }); ``` ```python Python import requests response = requests.get('/api/endpoint', headers={'Authorization': f'Bearer {api_key}'}) ``` ```curl cURL curl -X GET '/api/endpoint' \ -H 'Authorization: Bearer YOUR_API_KEY' ``` #### Request/response examples Example of request/response documentation: ```bash cURL curl -X POST 'https://api.example.com/users' \ -H 'Content-Type: application/json' \ -d '{"name": "John Doe", "email": "john@example.com"}' ``` ```json Success { "id": "user_123", "name": "John Doe", "email": "john@example.com", "created_at": "2024-01-15T10:30:00Z" } ``` ``` -------------------------------- ### Create a link with Markdown Source: https://help.b2proxy.com/essentials/markdown Wrap text in square brackets followed by parentheses to create a link. Use root-relative paths for internal links to optimize performance. ```markdown [link to google](https://google.com) ``` ```markdown [link to text](/writing-content/text) ``` ```markdown [link to text](../text) ``` -------------------------------- ### POST /plants Source: https://help.b2proxy.com/api-reference/endpoint/create Creates a new plant in the store. Requires authentication and a JSON body with plant details. ```APIDOC ## [POST] /plants ### Description Creates a new plant in the store. ### Method POST ### Endpoint /plants ### Parameters #### Path Parameters None #### Query Parameters None #### Request Body - **name** (string) - Required - The name of the plant - **id** (integer) - Required - Identification number of the plant - **tag** (string) - Optional - Tag to specify the type ### Request Example { "name": "", "id": 123, "tag": "" } ### Response #### Success Response (200) - **name** (string) - The name of the plant - **tag** (string) - Tag to specify the type #### Response Example { "name": "", "tag": "" } #### Error Response (400) - **error** (integer) - Error code - **message** (string) - Error message #### Error Response Example { "error": 123, "message": "" } ### Authorizations - **Authorization** (string, header, required) - Bearer authentication header of the form `Bearer `, where `` is your auth token. ``` -------------------------------- ### Import and use the reusable component with props Source: https://help.b2proxy.com/essentials/reusable-snippets Import the component from the snippet file and pass props to it. ```mdx --- title: My title description: My Description --- import { MyComponent } from '/snippets/custom-component.mdx'; Lorem ipsum dolor sit amet. ``` -------------------------------- ### Obtain API token: Incorrect credentials response (41003) Source: https://help.b2proxy.com/api-referance/sub-user-api Example of the error response when the username or password is incorrect, from the /api/consume/token/ endpoint. ```json { "code":41003, "message":"username or passwd error.", "results":null } ``` -------------------------------- ### Update Mintlify CLI Source: https://help.b2proxy.com/development Update the Mintlify CLI to align your local preview with the production version. ```bash npm mint update ``` -------------------------------- ### Query data usage: Unauthorized response (403) Source: https://help.b2proxy.com/api-referance/sub-user-api Example of the error response when authentication fails or the user is not logged in, returned by the /api/consume/chart/ endpoint. ```json { "code":403, "message":"unauthorized", "results":null } ``` -------------------------------- ### Run Mintlify on a custom port with --port flag Source: https://help.b2proxy.com/development Use the --port flag to run Mintlify on a specific port, e.g., 3333. ```bash mint dev --port 3333 ``` -------------------------------- ### POST /plants Source: https://help.b2proxy.com/api-reference/endpoint/create Creates a new plant with the provided name and optional tag. Returns the created plant object. ```APIDOC ## POST /plants ### Description Creates a new plant with the provided name and optional tag. ### Method POST ### Endpoint http://sandbox.mintlify.com/plants ### Parameters #### Request Body - **name** (string) - Required - The name of the plant - **tag** (string) - Optional - Tag to specify the type ### Request Example { "name": "", "id": 123, "tag": "" } ### Response #### Success Response (200) - **name** (string) - The name of the plant - **tag** (string) - Tag to specify the type #### Response Example { "name": "", "tag": "" } #### Error Response (400) - **error** (number) - Error code - **message** (string) - Error message #### Error Response Example { "error": 123, "message": "" } ``` -------------------------------- ### Import and use variables from a snippet Source: https://help.b2proxy.com/essentials/reusable-snippets Import variables from a snippet file and use them in the destination file. ```mdx --- title: My title description: My Description --- import { myName, myObject } from '/snippets/path/to/custom-variables.mdx'; Hello, my name is {myName} and I like {myObject.fruit}. ``` -------------------------------- ### GET /wapi/consume/chart/ Source: https://help.b2proxy.com/api-referance/sub-user-api Queries detailed traffic consumption records within a specified time range. The time range is optional and uses UTC seconds. Requires a bearer token for authentication. ```APIDOC ## [GET] /wapi/consume/chart/ ### Description This API queries detailed traffic consumption records within a specified time range. The start and end timestamps are in UTC seconds and are optional. ### Method GET ### Endpoint /wapi/consume/chart/ ### Parameters #### Header Parameters - **Authorization** (string) - Required - JWT authentication – Format: Bearer {token} #### Query Parameters - **suname** (string) - Optional - Sub-user username - **st** (integer) - Optional - Start timestamp (UTC seconds) - **et** (integer) - Optional - End timestamp (UTC seconds) ### Request Example GET /wapi/consume/chart/?suname=user&st=0&et=0 ### Response #### Success Response (200) - **code** (integer) - Response code, 200 for success - **message** (string) - Response message - **results** (array) - List of traffic consumption records, each containing: - **period** (string) - Time period (e.g., "2026-08-19T00:00:00+08:00") - **timestamp** (integer) - Timestamp - **total_traffic_count** (integer) - Total traffic count in the period #### Response Example { "code": 200, "message": "sucess.", "results": [ { "period": "2026-08-19T00:00:00+08:00", "timestamp": 0, "total_traffic_count": 0 } ] } #### Error Response (403) - **code** (integer) - Error code, 403 - **message** (string) - Error message, "unauthorized" - **results** (null) - null #### Error Response Example { "code": 403, "message": "unauthorized", "results": null } ``` -------------------------------- ### Add image with Markdown syntax Source: https://help.b2proxy.com/essentials/images Use Markdown syntax to add an image. The image file size must be less than 5MB; otherwise, host it on a service like Cloudinary or S3 and use that URL. ```markdown ![title](/path/image.jpg) ``` -------------------------------- ### JavaScript fetch POST to create a plant Source: https://help.b2proxy.com/api-reference/endpoint/create Sends a POST request using fetch with a JSON body and Authorization header. Handles the response as JSON and logs it. ```javascript const options = { method: 'POST', headers: {Authorization: 'Bearer ', 'Content-Type': 'application/json'}, body: JSON.stringify({name: '', id: 123, tag: ''}) }; fetch('http://sandbox.mintlify.com/plants', options) .then(res => res.json()) .then(res => console.log(res)) .catch(err => console.error(err)); ``` -------------------------------- ### Bash: Set API key in .env file Source: https://help.b2proxy.com/ai-tools/cursor Used in the 'Configure environment' step to store API credentials. The .env file should contain the API key in the format shown. Never commit API keys to version control. ```bash API_KEY=your_api_key_here ``` -------------------------------- ### Create CLAUDE.md for documentation standards Source: https://help.b2proxy.com/ai-tools/claude-code Optional CLAUDE.md file to train Claude Code on documentation standards. Place at the root of the documentation repository. Includes guidelines for working relationship, project context, content strategy, frontmatter, writing standards, Git workflow, and prohibited actions. ```markdown # Mintlify documentation ## Working relationship - You can push back on ideas-this can lead to better documentation. Cite sources and explain your reasoning when you do so - ALWAYS ask for clarification rather than making assumptions - NEVER lie, guess, or make up information ## Project context - Format: MDX files with YAML frontmatter - Config: docs.json for navigation, theme, settings - Components: Mintlify components ## Content strategy - Document just enough for user success - not too much, not too little - Prioritize accuracy and usability of information - Make content evergreen when possible - Search for existing information before adding new content. Avoid duplication unless it is done for a strategic reason - Check existing patterns for consistency - Start by making the smallest reasonable changes ## Frontmatter requirements for pages - title: Clear, descriptive page title - description: Concise summary for SEO/navigation ## Writing standards - Second-person voice ("you") - Prerequisites at start of procedural content - Test all code examples before publishing - Match style and formatting of existing pages - Include both basic and advanced use cases - Language tags on all code blocks - Alt text on all images - Relative paths for internal links ## Git workflow - NEVER use --no-verify when committing - Ask how to handle uncommitted changes before starting - Create a new branch when no clear branch exists for changes - Commit frequently throughout development - NEVER skip or disable pre-commit hooks ## Do not - Skip frontmatter on any MDX file - Use absolute URLs for internal links - Include untested code examples - Make assumptions - always ask for clarification ``` -------------------------------- ### Python requests POST to create a plant Source: https://help.b2proxy.com/api-reference/endpoint/create Uses the requests library to send a POST request with the plant payload. Prints the response text. ```python import requests url = "http://sandbox.mintlify.com/plants" payload = { "name": "", "id": 123, "tag": "" } headers = { "Authorization": "Bearer ", "Content-Type": "application/json" } response = requests.post(url, json=payload, headers=headers) print(response.text) ``` -------------------------------- ### cURL request to create a plant Source: https://help.b2proxy.com/api-reference/endpoint/create Sends a POST request to create a plant with a JSON body. Requires Authorization and Content-Type headers. ```bash curl --request POST \ --url http://sandbox.mintlify.com/plants \ --header 'Authorization: Bearer ' \ --header 'Content-Type: application/json' \ --data ' { "name": "", "id": 123, "tag": "" } ' ``` -------------------------------- ### Navigation With Folder Configuration Source: https://help.b2proxy.com/essentials/navigation Navigation configuration for a page located in a folder. The 'pages' array uses a path like 'your-folder/your-page' to reference the MDX file. ```json { "navigation": { "tabs": [ { "tab": "Docs", "groups": [ { "group": "Group Name", "pages": ["your-folder/your-page"] } ] } ] } } ``` -------------------------------- ### Render LaTeX with the Latex component Source: https://help.b2proxy.com/essentials/markdown Use the `` component to render LaTeX expressions in Mintlify. ```html 8 x (vk x H1 - H2) = (0,1) ``` -------------------------------- ### Regular Navigation Configuration Source: https://help.b2proxy.com/essentials/navigation Basic navigation structure with a single tab and group. The 'pages' array lists page names without the .mdx extension. ```json { "navigation": { "tabs": [ { "tab": "Docs", "groups": [ { "group": "Getting Started", "pages": ["quickstart"] } ] } ] } } ``` -------------------------------- ### Java HelloWorld code block with language and filename Source: https://help.b2proxy.com/essentials/code A fenced code block with the language 'java' and a filename 'HelloWorld.java' to enable syntax highlighting. ```java ```java HelloWorld.java class HelloWorld { public static void main(String[] args) { System.out.println("Hello, World!"); } } ``` ``` -------------------------------- ### Validate links with mint broken-links Source: https://help.b2proxy.com/development Use the CLI to validate links in your documentation and identify broken links. ```bash mint broken-links ``` -------------------------------- ### Java Unirest POST to create a plant Source: https://help.b2proxy.com/api-reference/endpoint/create Uses Unirest to send a POST request with the JSON body and required headers. Returns a response as string. ```java HttpResponse response = Unirest.post("http://sandbox.mintlify.com/plants") .header("Authorization", "Bearer ") .header("Content-Type", "application/json") .body("{\n \"name\": \"\",\n \"id\": 123,\n \"tag\": \"\"\n}") .asString(); ``` -------------------------------- ### Java HelloWorld code block with filename Source: https://help.b2proxy.com/essentials/code A fenced code block with the language 'java' and a filename 'HelloWorld.java' to enable syntax highlighting. ```java class HelloWorld { public static void main(String[] args) { System.out.println("Hello, World!"); } } ``` -------------------------------- ### Ruby Net::HTTP POST to create a plant Source: https://help.b2proxy.com/api-reference/endpoint/create Uses Net::HTTP to send a POST request with the JSON body and required headers. Prints the response body. ```ruby require 'uri' require 'net/http' url = URI("http://sandbox.mintlify.com/plants") http = Net::HTTP.new(url.host, url.port) request = Net::HTTP::Post.new(url) request["Authorization"] = 'Bearer ' request["Content-Type"] = 'application/json' request.body = "{\n \"name\": \"\",\n \"id\": 123,\n \"tag\": \"\"\n}" response = http.request(request) puts response.read_body ``` -------------------------------- ### Delete plant with Go net/http Source: https://help.b2proxy.com/api-reference/endpoint/delete Uses the net/http package to send a DELETE request. Requires a Bearer token and the plant ID. Prints the response body. ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "http://sandbox.mintlify.com/plants/{id}" req, _ := http.NewRequest("DELETE", url, nil) req.Header.Add("Authorization", "Bearer ") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(string(body)) } ``` -------------------------------- ### Add superscript and subscript with HTML Source: https://help.b2proxy.com/essentials/markdown Use HTML `` and `` tags to create superscript and subscript text, as Markdown does not support these natively. ```html superscript ``` ```html subscript ``` -------------------------------- ### Remove Mintlify CLI globally Source: https://help.b2proxy.com/development Remove the currently-installed version of the Mintlify CLI, as part of troubleshooting the sharp module error. ```bash npm remove -g mint ``` -------------------------------- ### Response 200 - Plant created Source: https://help.b2proxy.com/api-reference/endpoint/create Successful response body for a created plant, showing the name and tag fields. ```json { "name": "", "tag": "" } ``` -------------------------------- ### Force light mode toggle configuration Source: https://help.b2proxy.com/essentials/settings Sets modeToggle to always show light mode and hides the toggle. ```json "modeToggle": { "default": "light", "isHidden": true } ```