Skip to main content

Overview

The cURL Import feature lets you create tool configurations instantly from curl commands. Instead of manually filling in the URL, method, headers, parameters, and body, paste a curl command and GetMCP parses it automatically — then shows you an interactive preview to review and adjust before importing. This is useful when:
  • You have a working curl command from an API’s documentation
  • You’ve captured a request from your browser’s developer tools
  • You’re migrating existing API integrations to GetMCP

How to Use

Tool creation method selector — choose Paste cURL
1

Open the cURL Import Dialog

Navigate to your server’s Tools tab, click Add Tool, then select Import from cURL. You can also use the Re-import from cURL button inside any existing tool editor to overwrite its configuration.
2

Paste the cURL Command

Paste your curl command into the textarea. Multi-line commands with \ continuations are supported. Example:
cURL Import Dialog with example command
3

Click Parse cURL

Click the Parse cURL button. GetMCP parses the command and shows an interactive preview with the detected method, URL, headers, auth, and a parameter table you can edit before importing.
4

Review the Interactive Preview

The preview shows the detected method, auth, URL, and an editable parameter table. You can:
  • Toggle each parameter’s Required flag
  • Change the auto-detected Type
  • Remove parameters you don’t need
cURL parse preview showing detected parametersWhen satisfied, click Import & Continue to create the tool, or Back to edit the cURL command.

What Gets Parsed

Authentication Detection

GetMCP detects the authentication type from the curl command and pre-selects it in the Auth Type field. Credentials are not imported — you must enter your actual API key, token, or password manually after the import.
After importing, go to the server’s Authentication tab to enter your production credentials. For tool testing in the admin panel, enter your test/sandbox credentials in the Test Credentials section of the same tab.

Auto-Detected Parameter Types

GetMCP inspects the parsed values and assigns types automatically. You can change any type in the interactive preview before importing. Nested JSON objects are recursively flattened into parameters up to 3 levels deep, with correct types assigned to each leaf.

Supported cURL Formats

The parser handles the full range of real-world curl commands:
  • Single-linecurl -X POST https://api.com/data -H "Auth: Bearer xxx" -d '{"key":"val"}'
  • Multi-line with \ — standard format from API docs and browser DevTools
  • Single and double quotes — both styles around arguments
  • curl prefix optional — paste with or without the leading curl
  • Multiple -H flags — on the same or separate lines
  • -G flag — forces GET method; any -d data is mapped as Query String parameters instead of body
  • Bash $'...' strings--data-raw $'{"key":"value"}' with escape sequences
  • Escaped characters\', \", \\ handled correctly
  • Auth variantsBearer, Basic, X-API-Key, apikey, api-key, token
--data-binary @filename (file upload) is not supported. GetMCP will show a friendly error message if this flag is detected.

Re-import from cURL

The Re-import from cURL button is available inside any existing tool editor — not just during initial creation. Use it to overwrite the tool’s current configuration from a new curl command. This is useful when an API endpoint changes or you want to refresh the configuration from updated documentation.

Tips

Copy curl commands directly from your browser’s developer tools (Network tab → right-click a request → Copy as cURL). This captures the exact headers, auth, and body that the site uses.
After import, replace hardcoded values in the parameter table with descriptive names. For example, rename a detected user_id parameter and mark it as required so the AI client always provides it.
Avoid pasting curl commands containing production credentials into shared environments. Although credentials are not imported or stored, they are visible in the curl command text while the import dialog is open.