Text Utilities

Clean, compare, format, validate, and transform text strings

27 endpoints in this category. All require X-API-Key header.


Clean Text

POST /api/CleanText 1 token

Clean and normalize text (trim, collapse whitespace, remove control chars).

Parameters
NameTypeRequiredDescription
text string required Text to clean
options object optional {removeExtraSpaces, removeHtml, removeControlChars, removeSpecialChars}
Request Example
JSON
{"text": "  Hello   World  ", "options": {"removeExtraSpaces": true, "removeControlChars": true}}
Response Example
JSON
{"result": "Hello World"}
Code Examples
curl -X POST "https://docbutterfly.com/api/CleanText" \
  -H "X-API-Key: df_your_api_key_here" \
  -H "Content-Type: application/json" \
  -d '{"text": "  Hello   World  ", "options": {"removeExtraSpaces": true, "removeControlChars": true}}'
using var client = new HttpClient();
client.DefaultRequestHeaders.Add("X-API-Key", "df_your_api_key_here");

var json = @"{""text"": ""  Hello   World  "", ""options"": {""removeExtraSpaces"": true, ""removeControlChars"": true}}";
var content = new StringContent(json, System.Text.Encoding.UTF8, "application/json");

var response = await client.PostAsync("https://docbutterfly.com/api/CleanText", content);
response.EnsureSuccessStatusCode();

var result = await response.Content.ReadAsStringAsync();
Console.WriteLine(result);
import requests
import json

url = "https://docbutterfly.com/api/CleanText"
headers = {
    "X-API-Key": "df_your_api_key_here",
    "Content-Type": "application/json"
}
payload = json.loads('{"text": "  Hello   World  ", "options": {"removeExtraSpaces": true, "removeControlChars": true}}')

response = requests.post(url, headers=headers, json=payload)
response.raise_for_status()

data = response.json()
print(json.dumps(data, indent=2))
┌─────────────────────────────────────────────┐
│  Power Automate - HTTP Action               │
├─────────────────────────────────────────────┤
│                                             │
│  Method:  POST                              │
│  URI:     https://docbutterfly.com/api/CleanText
│                                             │
│  Headers:                                   │
│    X-API-Key:    df_your_api_key_here       │
│    Content-Type: application/json           │
│                                             │
│  Body:                                      │
│    {
│      "text": "  Hello   World  ",
│      "options": {
│        "removeExtraSpaces": true,
│        "removeControlChars": true
│      }
│    }
│                                             │
└─────────────────────────────────────────────┘

Steps:
1. Add an HTTP action to your flow
2. Set Method to "POST"
3. Set URI to "https://docbutterfly.com/api/CleanText"
4. Add the headers shown above
5. Paste the Body JSON into the Body field
6. Replace placeholder values with dynamic content as needed
Try in Testbed

Compare Text

POST /api/CompareText 1 token

Compare two text strings and return differences.

Parameters
NameTypeRequiredDescription
text1 string required First text
text2 string required Second text
options.caseSensitive boolean optional Case-sensitive comparison (default: true)
options.trimWhitespace boolean optional Trim before comparing (default: false)
Request Example
JSON
{"text1": "Hello World", "text2": "Hello world", "options": {"caseSensitive": true}}
Code Examples
curl -X POST "https://docbutterfly.com/api/CompareText" \
  -H "X-API-Key: df_your_api_key_here" \
  -H "Content-Type: application/json" \
  -d '{"text1": "Hello World", "text2": "Hello world", "options": {"caseSensitive": true}}'
using var client = new HttpClient();
client.DefaultRequestHeaders.Add("X-API-Key", "df_your_api_key_here");

var json = @"{""text1"": ""Hello World"", ""text2"": ""Hello world"", ""options"": {""caseSensitive"": true}}";
var content = new StringContent(json, System.Text.Encoding.UTF8, "application/json");

var response = await client.PostAsync("https://docbutterfly.com/api/CompareText", content);
response.EnsureSuccessStatusCode();

var result = await response.Content.ReadAsStringAsync();
Console.WriteLine(result);
import requests
import json

url = "https://docbutterfly.com/api/CompareText"
headers = {
    "X-API-Key": "df_your_api_key_here",
    "Content-Type": "application/json"
}
payload = json.loads('{"text1": "Hello World", "text2": "Hello world", "options": {"caseSensitive": true}}')

response = requests.post(url, headers=headers, json=payload)
response.raise_for_status()

data = response.json()
print(json.dumps(data, indent=2))
┌─────────────────────────────────────────────┐
│  Power Automate - HTTP Action               │
├─────────────────────────────────────────────┤
│                                             │
│  Method:  POST                              │
│  URI:     https://docbutterfly.com/api/CompareText
│                                             │
│  Headers:                                   │
│    X-API-Key:    df_your_api_key_here       │
│    Content-Type: application/json           │
│                                             │
│  Body:                                      │
│    {
│      "text1": "Hello World",
│      "text2": "Hello world",
│      "options": {
│        "caseSensitive": true
│      }
│    }
│                                             │
└─────────────────────────────────────────────┘

Steps:
1. Add an HTTP action to your flow
2. Set Method to "POST"
3. Set URI to "https://docbutterfly.com/api/CompareText"
4. Add the headers shown above
5. Paste the Body JSON into the Body field
6. Replace placeholder values with dynamic content as needed
Try in Testbed

Concatenate Text

POST /api/ConcatenateText 1 token

Concatenate multiple strings with separator.

Parameters
NameTypeRequiredDescription
texts array required Array of strings
separator string optional Separator
Request Example
JSON
{"texts": ["Hello", "World"], "separator": " "}
Response Example
JSON
{"result": "Hello World"}
Code Examples
curl -X POST "https://docbutterfly.com/api/ConcatenateText" \
  -H "X-API-Key: df_your_api_key_here" \
  -H "Content-Type: application/json" \
  -d '{"texts": ["Hello", "World"], "separator": " "}'
using var client = new HttpClient();
client.DefaultRequestHeaders.Add("X-API-Key", "df_your_api_key_here");

var json = @"{""texts"": [""Hello"", ""World""], ""separator"": "" ""}";
var content = new StringContent(json, System.Text.Encoding.UTF8, "application/json");

var response = await client.PostAsync("https://docbutterfly.com/api/ConcatenateText", content);
response.EnsureSuccessStatusCode();

var result = await response.Content.ReadAsStringAsync();
Console.WriteLine(result);
import requests
import json

url = "https://docbutterfly.com/api/ConcatenateText"
headers = {
    "X-API-Key": "df_your_api_key_here",
    "Content-Type": "application/json"
}
payload = json.loads('{"texts": ["Hello", "World"], "separator": " "}')

response = requests.post(url, headers=headers, json=payload)
response.raise_for_status()

data = response.json()
print(json.dumps(data, indent=2))
┌─────────────────────────────────────────────┐
│  Power Automate - HTTP Action               │
├─────────────────────────────────────────────┤
│                                             │
│  Method:  POST                              │
│  URI:     https://docbutterfly.com/api/ConcatenateText
│                                             │
│  Headers:                                   │
│    X-API-Key:    df_your_api_key_here       │
│    Content-Type: application/json           │
│                                             │
│  Body:                                      │
│    {
│      "texts": [
│        "Hello",
│        "World"
│      ],
│      "separator": " "
│    }
│                                             │
└─────────────────────────────────────────────┘

Steps:
1. Add an HTTP action to your flow
2. Set Method to "POST"
3. Set URI to "https://docbutterfly.com/api/ConcatenateText"
4. Add the headers shown above
5. Paste the Body JSON into the Body field
6. Replace placeholder values with dynamic content as needed
Try in Testbed

Convert JSON to XML

POST /api/ConvertJsonToXml 1 token

Convert JSON to XML format.

Parameters
NameTypeRequiredDescription
json object required JSON object
options.rootName string optional Root element name (default: root)
options.indentation number optional Indentation spaces (default: 2)
Request Example
JSON
{"json": {"name": "John", "age": 30}, "options": {"rootName": "person"}}
Code Examples
curl -X POST "https://docbutterfly.com/api/ConvertJsonToXml" \
  -H "X-API-Key: df_your_api_key_here" \
  -H "Content-Type: application/json" \
  -d '{"json": {"name": "John", "age": 30}, "options": {"rootName": "person"}}'
using var client = new HttpClient();
client.DefaultRequestHeaders.Add("X-API-Key", "df_your_api_key_here");

var json = @"{""json"": {""name"": ""John"", ""age"": 30}, ""options"": {""rootName"": ""person""}}";
var content = new StringContent(json, System.Text.Encoding.UTF8, "application/json");

var response = await client.PostAsync("https://docbutterfly.com/api/ConvertJsonToXml", content);
response.EnsureSuccessStatusCode();

var result = await response.Content.ReadAsStringAsync();
Console.WriteLine(result);
import requests
import json

url = "https://docbutterfly.com/api/ConvertJsonToXml"
headers = {
    "X-API-Key": "df_your_api_key_here",
    "Content-Type": "application/json"
}
payload = json.loads('{"json": {"name": "John", "age": 30}, "options": {"rootName": "person"}}')

response = requests.post(url, headers=headers, json=payload)
response.raise_for_status()

data = response.json()
print(json.dumps(data, indent=2))
┌─────────────────────────────────────────────┐
│  Power Automate - HTTP Action               │
├─────────────────────────────────────────────┤
│                                             │
│  Method:  POST                              │
│  URI:     https://docbutterfly.com/api/ConvertJsonToXml
│                                             │
│  Headers:                                   │
│    X-API-Key:    df_your_api_key_here       │
│    Content-Type: application/json           │
│                                             │
│  Body:                                      │
│    {
│      "json": {
│        "name": "John",
│        "age": 30
│      },
│      "options": {
│        "rootName": "person"
│      }
│    }
│                                             │
└─────────────────────────────────────────────┘

Steps:
1. Add an HTTP action to your flow
2. Set Method to "POST"
3. Set URI to "https://docbutterfly.com/api/ConvertJsonToXml"
4. Add the headers shown above
5. Paste the Body JSON into the Body field
6. Replace placeholder values with dynamic content as needed
Try in Testbed

Convert XML to JSON

POST /api/ConvertXmlToJson 1 token

Convert XML to JSON format.

Parameters
NameTypeRequiredDescription
xml string required XML string
Request Example
JSON
{"xml": "<person><name>John</name><age>30</age></person>"}
Code Examples
curl -X POST "https://docbutterfly.com/api/ConvertXmlToJson" \
  -H "X-API-Key: df_your_api_key_here" \
  -H "Content-Type: application/json" \
  -d '{"xml": "<person><name>John</name><age>30</age></person>"}'
using var client = new HttpClient();
client.DefaultRequestHeaders.Add("X-API-Key", "df_your_api_key_here");

var json = @"{""xml"": ""<person><name>John</name><age>30</age></person>""}";
var content = new StringContent(json, System.Text.Encoding.UTF8, "application/json");

var response = await client.PostAsync("https://docbutterfly.com/api/ConvertXmlToJson", content);
response.EnsureSuccessStatusCode();

var result = await response.Content.ReadAsStringAsync();
Console.WriteLine(result);
import requests
import json

url = "https://docbutterfly.com/api/ConvertXmlToJson"
headers = {
    "X-API-Key": "df_your_api_key_here",
    "Content-Type": "application/json"
}
payload = json.loads('{"xml": "<person><name>John</name><age>30</age></person>"}')

response = requests.post(url, headers=headers, json=payload)
response.raise_for_status()

data = response.json()
print(json.dumps(data, indent=2))
┌─────────────────────────────────────────────┐
│  Power Automate - HTTP Action               │
├─────────────────────────────────────────────┤
│                                             │
│  Method:  POST                              │
│  URI:     https://docbutterfly.com/api/ConvertXmlToJson
│                                             │
│  Headers:                                   │
│    X-API-Key:    df_your_api_key_here       │
│    Content-Type: application/json           │
│                                             │
│  Body:                                      │
│    {
│      "xml": "\u003Cperson\u003E\u003Cname\u003EJohn\u003C/name\u003E\u003Cage\u003E30\u003C/age\u003E\u003C/person\u003E"
│    }
│                                             │
└─────────────────────────────────────────────┘

Steps:
1. Add an HTTP action to your flow
2. Set Method to "POST"
3. Set URI to "https://docbutterfly.com/api/ConvertXmlToJson"
4. Add the headers shown above
5. Paste the Body JSON into the Body field
6. Replace placeholder values with dynamic content as needed
Try in Testbed

Extract Email Addresses

POST /api/ExtractEmailAddresses 1 token

Extract all email addresses from text.

Parameters
NameTypeRequiredDescription
text string required Text to search
Request Example
JSON
{"text": "Contact john@example.com or jane@test.com"}
Response Example
JSON
{"emails": ["john@example.com", "jane@test.com"], "count": 2}
Code Examples
curl -X POST "https://docbutterfly.com/api/ExtractEmailAddresses" \
  -H "X-API-Key: df_your_api_key_here" \
  -H "Content-Type: application/json" \
  -d '{"text": "Contact john@example.com or jane@test.com"}'
using var client = new HttpClient();
client.DefaultRequestHeaders.Add("X-API-Key", "df_your_api_key_here");

var json = @"{""text"": ""Contact john@example.com or jane@test.com""}";
var content = new StringContent(json, System.Text.Encoding.UTF8, "application/json");

var response = await client.PostAsync("https://docbutterfly.com/api/ExtractEmailAddresses", content);
response.EnsureSuccessStatusCode();

var result = await response.Content.ReadAsStringAsync();
Console.WriteLine(result);
import requests
import json

url = "https://docbutterfly.com/api/ExtractEmailAddresses"
headers = {
    "X-API-Key": "df_your_api_key_here",
    "Content-Type": "application/json"
}
payload = json.loads('{"text": "Contact john@example.com or jane@test.com"}')

response = requests.post(url, headers=headers, json=payload)
response.raise_for_status()

data = response.json()
print(json.dumps(data, indent=2))
┌─────────────────────────────────────────────┐
│  Power Automate - HTTP Action               │
├─────────────────────────────────────────────┤
│                                             │
│  Method:  POST                              │
│  URI:     https://docbutterfly.com/api/ExtractEmailAddresses
│                                             │
│  Headers:                                   │
│    X-API-Key:    df_your_api_key_here       │
│    Content-Type: application/json           │
│                                             │
│  Body:                                      │
│    {
│      "text": "Contact john@example.com or jane@test.com"
│    }
│                                             │
└─────────────────────────────────────────────┘

Steps:
1. Add an HTTP action to your flow
2. Set Method to "POST"
3. Set URI to "https://docbutterfly.com/api/ExtractEmailAddresses"
4. Add the headers shown above
5. Paste the Body JSON into the Body field
6. Replace placeholder values with dynamic content as needed
Try in Testbed

Extract Text Between

POST /api/ExtractTextBetween 1 token

Extract text between two markers.

Parameters
NameTypeRequiredDescription
text string required Source text
startDelimiter string required Start marker
endDelimiter string required End marker
Request Example
JSON
{"text": "Hello [World] Goodbye", "startDelimiter": "[", "endDelimiter": "]"}
Response Example
JSON
{"result": "World"}
Code Examples
curl -X POST "https://docbutterfly.com/api/ExtractTextBetween" \
  -H "X-API-Key: df_your_api_key_here" \
  -H "Content-Type: application/json" \
  -d '{"text": "Hello [World] Goodbye", "startDelimiter": "[", "endDelimiter": "]"}'
using var client = new HttpClient();
client.DefaultRequestHeaders.Add("X-API-Key", "df_your_api_key_here");

var json = @"{""text"": ""Hello [World] Goodbye"", ""startDelimiter"": ""["", ""endDelimiter"": ""]""}";
var content = new StringContent(json, System.Text.Encoding.UTF8, "application/json");

var response = await client.PostAsync("https://docbutterfly.com/api/ExtractTextBetween", content);
response.EnsureSuccessStatusCode();

var result = await response.Content.ReadAsStringAsync();
Console.WriteLine(result);
import requests
import json

url = "https://docbutterfly.com/api/ExtractTextBetween"
headers = {
    "X-API-Key": "df_your_api_key_here",
    "Content-Type": "application/json"
}
payload = json.loads('{"text": "Hello [World] Goodbye", "startDelimiter": "[", "endDelimiter": "]"}')

response = requests.post(url, headers=headers, json=payload)
response.raise_for_status()

data = response.json()
print(json.dumps(data, indent=2))
┌─────────────────────────────────────────────┐
│  Power Automate - HTTP Action               │
├─────────────────────────────────────────────┤
│                                             │
│  Method:  POST                              │
│  URI:     https://docbutterfly.com/api/ExtractTextBetween
│                                             │
│  Headers:                                   │
│    X-API-Key:    df_your_api_key_here       │
│    Content-Type: application/json           │
│                                             │
│  Body:                                      │
│    {
│      "text": "Hello [World] Goodbye",
│      "startDelimiter": "[",
│      "endDelimiter": "]"
│    }
│                                             │
└─────────────────────────────────────────────┘

Steps:
1. Add an HTTP action to your flow
2. Set Method to "POST"
3. Set URI to "https://docbutterfly.com/api/ExtractTextBetween"
4. Add the headers shown above
5. Paste the Body JSON into the Body field
6. Replace placeholder values with dynamic content as needed
Try in Testbed

Extract URLs

POST /api/ExtractUrls 1 token

Extract all URLs from text.

Parameters
NameTypeRequiredDescription
text string required Text to search
Request Example
JSON
{"text": "Visit https://example.com or http://test.com"}
Code Examples
curl -X POST "https://docbutterfly.com/api/ExtractUrls" \
  -H "X-API-Key: df_your_api_key_here" \
  -H "Content-Type: application/json" \
  -d '{"text": "Visit https://example.com or http://test.com"}'
using var client = new HttpClient();
client.DefaultRequestHeaders.Add("X-API-Key", "df_your_api_key_here");

var json = @"{""text"": ""Visit https://example.com or http://test.com""}";
var content = new StringContent(json, System.Text.Encoding.UTF8, "application/json");

var response = await client.PostAsync("https://docbutterfly.com/api/ExtractUrls", content);
response.EnsureSuccessStatusCode();

var result = await response.Content.ReadAsStringAsync();
Console.WriteLine(result);
import requests
import json

url = "https://docbutterfly.com/api/ExtractUrls"
headers = {
    "X-API-Key": "df_your_api_key_here",
    "Content-Type": "application/json"
}
payload = json.loads('{"text": "Visit https://example.com or http://test.com"}')

response = requests.post(url, headers=headers, json=payload)
response.raise_for_status()

data = response.json()
print(json.dumps(data, indent=2))
┌─────────────────────────────────────────────┐
│  Power Automate - HTTP Action               │
├─────────────────────────────────────────────┤
│                                             │
│  Method:  POST                              │
│  URI:     https://docbutterfly.com/api/ExtractUrls
│                                             │
│  Headers:                                   │
│    X-API-Key:    df_your_api_key_here       │
│    Content-Type: application/json           │
│                                             │
│  Body:                                      │
│    {
│      "text": "Visit https://example.com or http://test.com"
│    }
│                                             │
└─────────────────────────────────────────────┘

Steps:
1. Add an HTTP action to your flow
2. Set Method to "POST"
3. Set URI to "https://docbutterfly.com/api/ExtractUrls"
4. Add the headers shown above
5. Paste the Body JSON into the Body field
6. Replace placeholder values with dynamic content as needed
Try in Testbed

Format Date

POST /api/FormatDate 1 token

Format a date to a specified pattern.

Parameters
NameTypeRequiredDescription
date string required Date string or ISO date
format string required Output format: YYYY-MM-DD, DD/MM/YYYY, etc
inputFormat string optional Input format if ambiguous
Request Example
JSON
{"date": "2026-01-15T10:30:00Z", "format": "DD/MM/YYYY HH:mm"}
Code Examples
curl -X POST "https://docbutterfly.com/api/FormatDate" \
  -H "X-API-Key: df_your_api_key_here" \
  -H "Content-Type: application/json" \
  -d '{"date": "2026-01-15T10:30:00Z", "format": "DD/MM/YYYY HH:mm"}'
using var client = new HttpClient();
client.DefaultRequestHeaders.Add("X-API-Key", "df_your_api_key_here");

var json = @"{""date"": ""2026-01-15T10:30:00Z"", ""format"": ""DD/MM/YYYY HH:mm""}";
var content = new StringContent(json, System.Text.Encoding.UTF8, "application/json");

var response = await client.PostAsync("https://docbutterfly.com/api/FormatDate", content);
response.EnsureSuccessStatusCode();

var result = await response.Content.ReadAsStringAsync();
Console.WriteLine(result);
import requests
import json

url = "https://docbutterfly.com/api/FormatDate"
headers = {
    "X-API-Key": "df_your_api_key_here",
    "Content-Type": "application/json"
}
payload = json.loads('{"date": "2026-01-15T10:30:00Z", "format": "DD/MM/YYYY HH:mm"}')

response = requests.post(url, headers=headers, json=payload)
response.raise_for_status()

data = response.json()
print(json.dumps(data, indent=2))
┌─────────────────────────────────────────────┐
│  Power Automate - HTTP Action               │
├─────────────────────────────────────────────┤
│                                             │
│  Method:  POST                              │
│  URI:     https://docbutterfly.com/api/FormatDate
│                                             │
│  Headers:                                   │
│    X-API-Key:    df_your_api_key_here       │
│    Content-Type: application/json           │
│                                             │
│  Body:                                      │
│    {
│      "date": "2026-01-15T10:30:00Z",
│      "format": "DD/MM/YYYY HH:mm"
│    }
│                                             │
└─────────────────────────────────────────────┘

Steps:
1. Add an HTTP action to your flow
2. Set Method to "POST"
3. Set URI to "https://docbutterfly.com/api/FormatDate"
4. Add the headers shown above
5. Paste the Body JSON into the Body field
6. Replace placeholder values with dynamic content as needed
Try in Testbed

Generate GUID

POST /api/GenerateGuid 1 token

Generate a UUID/GUID.

Parameters
NameTypeRequiredDescription
format string optional standard, noDashes, uppercase (default: standard)
Request Example
JSON
{"format": "standard"}
Response Example
JSON
{"guid": "550e8400-e29b-41d4-a716-446655440000"}
Code Examples
curl -X POST "https://docbutterfly.com/api/GenerateGuid" \
  -H "X-API-Key: df_your_api_key_here" \
  -H "Content-Type: application/json" \
  -d '{"format": "standard"}'
using var client = new HttpClient();
client.DefaultRequestHeaders.Add("X-API-Key", "df_your_api_key_here");

var json = @"{""format"": ""standard""}";
var content = new StringContent(json, System.Text.Encoding.UTF8, "application/json");

var response = await client.PostAsync("https://docbutterfly.com/api/GenerateGuid", content);
response.EnsureSuccessStatusCode();

var result = await response.Content.ReadAsStringAsync();
Console.WriteLine(result);
import requests
import json

url = "https://docbutterfly.com/api/GenerateGuid"
headers = {
    "X-API-Key": "df_your_api_key_here",
    "Content-Type": "application/json"
}
payload = json.loads('{"format": "standard"}')

response = requests.post(url, headers=headers, json=payload)
response.raise_for_status()

data = response.json()
print(json.dumps(data, indent=2))
┌─────────────────────────────────────────────┐
│  Power Automate - HTTP Action               │
├─────────────────────────────────────────────┤
│                                             │
│  Method:  POST                              │
│  URI:     https://docbutterfly.com/api/GenerateGuid
│                                             │
│  Headers:                                   │
│    X-API-Key:    df_your_api_key_here       │
│    Content-Type: application/json           │
│                                             │
│  Body:                                      │
│    {
│      "format": "standard"
│    }
│                                             │
└─────────────────────────────────────────────┘

Steps:
1. Add an HTTP action to your flow
2. Set Method to "POST"
3. Set URI to "https://docbutterfly.com/api/GenerateGuid"
4. Add the headers shown above
5. Paste the Body JSON into the Body field
6. Replace placeholder values with dynamic content as needed
Try in Testbed

Generate Password

POST /api/GeneratePassword 1 token

Generate a secure random password.

Parameters
NameTypeRequiredDescription
length number optional Password length (default: 16)
options.uppercase boolean optional Include uppercase (default: true)
options.numbers boolean optional Include numbers (default: true)
options.symbols boolean optional Include symbols (default: true)
Request Example
JSON
{"length": 20, "options": {"uppercase": true, "numbers": true, "symbols": true}}
Response Example
JSON
{"password": "Kx9#mP2&vL5@nR8!jQ4w"}
Code Examples
curl -X POST "https://docbutterfly.com/api/GeneratePassword" \
  -H "X-API-Key: df_your_api_key_here" \
  -H "Content-Type: application/json" \
  -d '{"length": 20, "options": {"uppercase": true, "numbers": true, "symbols": true}}'
using var client = new HttpClient();
client.DefaultRequestHeaders.Add("X-API-Key", "df_your_api_key_here");

var json = @"{""length"": 20, ""options"": {""uppercase"": true, ""numbers"": true, ""symbols"": true}}";
var content = new StringContent(json, System.Text.Encoding.UTF8, "application/json");

var response = await client.PostAsync("https://docbutterfly.com/api/GeneratePassword", content);
response.EnsureSuccessStatusCode();

var result = await response.Content.ReadAsStringAsync();
Console.WriteLine(result);
import requests
import json

url = "https://docbutterfly.com/api/GeneratePassword"
headers = {
    "X-API-Key": "df_your_api_key_here",
    "Content-Type": "application/json"
}
payload = json.loads('{"length": 20, "options": {"uppercase": true, "numbers": true, "symbols": true}}')

response = requests.post(url, headers=headers, json=payload)
response.raise_for_status()

data = response.json()
print(json.dumps(data, indent=2))
┌─────────────────────────────────────────────┐
│  Power Automate - HTTP Action               │
├─────────────────────────────────────────────┤
│                                             │
│  Method:  POST                              │
│  URI:     https://docbutterfly.com/api/GeneratePassword
│                                             │
│  Headers:                                   │
│    X-API-Key:    df_your_api_key_here       │
│    Content-Type: application/json           │
│                                             │
│  Body:                                      │
│    {
│      "length": 20,
│      "options": {
│        "uppercase": true,
│        "numbers": true,
│        "symbols": true
│      }
│    }
│                                             │
└─────────────────────────────────────────────┘

Steps:
1. Add an HTTP action to your flow
2. Set Method to "POST"
3. Set URI to "https://docbutterfly.com/api/GeneratePassword"
4. Add the headers shown above
5. Paste the Body JSON into the Body field
6. Replace placeholder values with dynamic content as needed
Try in Testbed

Generate Random Number

POST /api/GenerateRandomNumber 1 token

Generate random number in a range.

Parameters
NameTypeRequiredDescription
min number optional Minimum value (default: 0)
max number optional Maximum value (default: 100)
Request Example
JSON
{"min": 1, "max": 1000}
Response Example
JSON
{"number": 427}
Code Examples
curl -X POST "https://docbutterfly.com/api/GenerateRandomNumber" \
  -H "X-API-Key: df_your_api_key_here" \
  -H "Content-Type: application/json" \
  -d '{"min": 1, "max": 1000}'
using var client = new HttpClient();
client.DefaultRequestHeaders.Add("X-API-Key", "df_your_api_key_here");

var json = @"{""min"": 1, ""max"": 1000}";
var content = new StringContent(json, System.Text.Encoding.UTF8, "application/json");

var response = await client.PostAsync("https://docbutterfly.com/api/GenerateRandomNumber", content);
response.EnsureSuccessStatusCode();

var result = await response.Content.ReadAsStringAsync();
Console.WriteLine(result);
import requests
import json

url = "https://docbutterfly.com/api/GenerateRandomNumber"
headers = {
    "X-API-Key": "df_your_api_key_here",
    "Content-Type": "application/json"
}
payload = json.loads('{"min": 1, "max": 1000}')

response = requests.post(url, headers=headers, json=payload)
response.raise_for_status()

data = response.json()
print(json.dumps(data, indent=2))
┌─────────────────────────────────────────────┐
│  Power Automate - HTTP Action               │
├─────────────────────────────────────────────┤
│                                             │
│  Method:  POST                              │
│  URI:     https://docbutterfly.com/api/GenerateRandomNumber
│                                             │
│  Headers:                                   │
│    X-API-Key:    df_your_api_key_here       │
│    Content-Type: application/json           │
│                                             │
│  Body:                                      │
│    {
│      "min": 1,
│      "max": 1000
│    }
│                                             │
└─────────────────────────────────────────────┘

Steps:
1. Add an HTTP action to your flow
2. Set Method to "POST"
3. Set URI to "https://docbutterfly.com/api/GenerateRandomNumber"
4. Add the headers shown above
5. Paste the Body JSON into the Body field
6. Replace placeholder values with dynamic content as needed
Try in Testbed

Get Date Difference

POST /api/GetDateDifference 1 token

Calculate difference between two dates.

Parameters
NameTypeRequiredDescription
date1 string required First date
date2 string required Second date
unit string optional days, hours, minutes, seconds (default: days)
Request Example
JSON
{"date1": "2026-01-01", "date2": "2026-12-31", "unit": "days"}
Response Example
JSON
{"difference": 364, "unit": "days"}
Code Examples
curl -X POST "https://docbutterfly.com/api/GetDateDifference" \
  -H "X-API-Key: df_your_api_key_here" \
  -H "Content-Type: application/json" \
  -d '{"date1": "2026-01-01", "date2": "2026-12-31", "unit": "days"}'
using var client = new HttpClient();
client.DefaultRequestHeaders.Add("X-API-Key", "df_your_api_key_here");

var json = @"{""date1"": ""2026-01-01"", ""date2"": ""2026-12-31"", ""unit"": ""days""}";
var content = new StringContent(json, System.Text.Encoding.UTF8, "application/json");

var response = await client.PostAsync("https://docbutterfly.com/api/GetDateDifference", content);
response.EnsureSuccessStatusCode();

var result = await response.Content.ReadAsStringAsync();
Console.WriteLine(result);
import requests
import json

url = "https://docbutterfly.com/api/GetDateDifference"
headers = {
    "X-API-Key": "df_your_api_key_here",
    "Content-Type": "application/json"
}
payload = json.loads('{"date1": "2026-01-01", "date2": "2026-12-31", "unit": "days"}')

response = requests.post(url, headers=headers, json=payload)
response.raise_for_status()

data = response.json()
print(json.dumps(data, indent=2))
┌─────────────────────────────────────────────┐
│  Power Automate - HTTP Action               │
├─────────────────────────────────────────────┤
│                                             │
│  Method:  POST                              │
│  URI:     https://docbutterfly.com/api/GetDateDifference
│                                             │
│  Headers:                                   │
│    X-API-Key:    df_your_api_key_here       │
│    Content-Type: application/json           │
│                                             │
│  Body:                                      │
│    {
│      "date1": "2026-01-01",
│      "date2": "2026-12-31",
│      "unit": "days"
│    }
│                                             │
└─────────────────────────────────────────────┘

Steps:
1. Add an HTTP action to your flow
2. Set Method to "POST"
3. Set URI to "https://docbutterfly.com/api/GetDateDifference"
4. Add the headers shown above
5. Paste the Body JSON into the Body field
6. Replace placeholder values with dynamic content as needed
Try in Testbed

Get File Extension

POST /api/GetFileExtension 1 token

Get file extension from a filename.

Parameters
NameTypeRequiredDescription
filename string required Filename or path
Request Example
JSON
{"filename": "document.pdf"}
Response Example
JSON
{"extension": ".pdf", "extensionNoDot": "pdf"}
Code Examples
curl -X POST "https://docbutterfly.com/api/GetFileExtension" \
  -H "X-API-Key: df_your_api_key_here" \
  -H "Content-Type: application/json" \
  -d '{"filename": "document.pdf"}'
using var client = new HttpClient();
client.DefaultRequestHeaders.Add("X-API-Key", "df_your_api_key_here");

var json = @"{""filename"": ""document.pdf""}";
var content = new StringContent(json, System.Text.Encoding.UTF8, "application/json");

var response = await client.PostAsync("https://docbutterfly.com/api/GetFileExtension", content);
response.EnsureSuccessStatusCode();

var result = await response.Content.ReadAsStringAsync();
Console.WriteLine(result);
import requests
import json

url = "https://docbutterfly.com/api/GetFileExtension"
headers = {
    "X-API-Key": "df_your_api_key_here",
    "Content-Type": "application/json"
}
payload = json.loads('{"filename": "document.pdf"}')

response = requests.post(url, headers=headers, json=payload)
response.raise_for_status()

data = response.json()
print(json.dumps(data, indent=2))
┌─────────────────────────────────────────────┐
│  Power Automate - HTTP Action               │
├─────────────────────────────────────────────┤
│                                             │
│  Method:  POST                              │
│  URI:     https://docbutterfly.com/api/GetFileExtension
│                                             │
│  Headers:                                   │
│    X-API-Key:    df_your_api_key_here       │
│    Content-Type: application/json           │
│                                             │
│  Body:                                      │
│    {
│      "filename": "document.pdf"
│    }
│                                             │
└─────────────────────────────────────────────┘

Steps:
1. Add an HTTP action to your flow
2. Set Method to "POST"
3. Set URI to "https://docbutterfly.com/api/GetFileExtension"
4. Add the headers shown above
5. Paste the Body JSON into the Body field
6. Replace placeholder values with dynamic content as needed
Try in Testbed

HTML Escape

POST /api/HtmlEscape 1 token

Escape HTML special characters.

Parameters
NameTypeRequiredDescription
text string required Text to escape
Request Example
JSON
{"text": "<script>alert('XSS')</script>"}
Code Examples
curl -X POST "https://docbutterfly.com/api/HtmlEscape" \
  -H "X-API-Key: df_your_api_key_here" \
  -H "Content-Type: application/json" \
  -d '{"text": "<script>alert('\''XSS'\'')</script>"}'
using var client = new HttpClient();
client.DefaultRequestHeaders.Add("X-API-Key", "df_your_api_key_here");

var json = @"{""text"": ""<script>alert('XSS')</script>""}";
var content = new StringContent(json, System.Text.Encoding.UTF8, "application/json");

var response = await client.PostAsync("https://docbutterfly.com/api/HtmlEscape", content);
response.EnsureSuccessStatusCode();

var result = await response.Content.ReadAsStringAsync();
Console.WriteLine(result);
import requests
import json

url = "https://docbutterfly.com/api/HtmlEscape"
headers = {
    "X-API-Key": "df_your_api_key_here",
    "Content-Type": "application/json"
}
payload = json.loads('{"text": "<script>alert(\'XSS\')</script>"}')

response = requests.post(url, headers=headers, json=payload)
response.raise_for_status()

data = response.json()
print(json.dumps(data, indent=2))
┌─────────────────────────────────────────────┐
│  Power Automate - HTTP Action               │
├─────────────────────────────────────────────┤
│                                             │
│  Method:  POST                              │
│  URI:     https://docbutterfly.com/api/HtmlEscape
│                                             │
│  Headers:                                   │
│    X-API-Key:    df_your_api_key_here       │
│    Content-Type: application/json           │
│                                             │
│  Body:                                      │
│    {
│      "text": "\u003Cscript\u003Ealert(\u0027XSS\u0027)\u003C/script\u003E"
│    }
│                                             │
└─────────────────────────────────────────────┘

Steps:
1. Add an HTTP action to your flow
2. Set Method to "POST"
3. Set URI to "https://docbutterfly.com/api/HtmlEscape"
4. Add the headers shown above
5. Paste the Body JSON into the Body field
6. Replace placeholder values with dynamic content as needed
Try in Testbed

HTML Unescape

POST /api/HtmlUnescape 1 token

Unescape HTML entities.

Parameters
NameTypeRequiredDescription
text string required Text with HTML entities
Request Example
JSON
{"text": "&lt;p&gt;Hello &amp; World&lt;/p&gt;"}
Code Examples
curl -X POST "https://docbutterfly.com/api/HtmlUnescape" \
  -H "X-API-Key: df_your_api_key_here" \
  -H "Content-Type: application/json" \
  -d '{"text": "&lt;p&gt;Hello &amp; World&lt;/p&gt;"}'
using var client = new HttpClient();
client.DefaultRequestHeaders.Add("X-API-Key", "df_your_api_key_here");

var json = @"{""text"": ""&lt;p&gt;Hello &amp; World&lt;/p&gt;""}";
var content = new StringContent(json, System.Text.Encoding.UTF8, "application/json");

var response = await client.PostAsync("https://docbutterfly.com/api/HtmlUnescape", content);
response.EnsureSuccessStatusCode();

var result = await response.Content.ReadAsStringAsync();
Console.WriteLine(result);
import requests
import json

url = "https://docbutterfly.com/api/HtmlUnescape"
headers = {
    "X-API-Key": "df_your_api_key_here",
    "Content-Type": "application/json"
}
payload = json.loads('{"text": "&lt;p&gt;Hello &amp; World&lt;/p&gt;"}')

response = requests.post(url, headers=headers, json=payload)
response.raise_for_status()

data = response.json()
print(json.dumps(data, indent=2))
┌─────────────────────────────────────────────┐
│  Power Automate - HTTP Action               │
├─────────────────────────────────────────────┤
│                                             │
│  Method:  POST                              │
│  URI:     https://docbutterfly.com/api/HtmlUnescape
│                                             │
│  Headers:                                   │
│    X-API-Key:    df_your_api_key_here       │
│    Content-Type: application/json           │
│                                             │
│  Body:                                      │
│    {
│      "text": "\u0026lt;p\u0026gt;Hello \u0026amp; World\u0026lt;/p\u0026gt;"
│    }
│                                             │
└─────────────────────────────────────────────┘

Steps:
1. Add an HTTP action to your flow
2. Set Method to "POST"
3. Set URI to "https://docbutterfly.com/api/HtmlUnescape"
4. Add the headers shown above
5. Paste the Body JSON into the Body field
6. Replace placeholder values with dynamic content as needed
Try in Testbed

Parse HTML Table

POST /api/ParseHtmlTable 1 token

Parse HTML table to JSON rows.

Parameters
NameTypeRequiredDescription
html string required HTML containing a table
hasHeaders boolean optional First row is headers (default: true)
Request Example
JSON
{"html": "<table><tr><th>Name</th></tr><tr><td>John</td></tr></table>"}
Code Examples
curl -X POST "https://docbutterfly.com/api/ParseHtmlTable" \
  -H "X-API-Key: df_your_api_key_here" \
  -H "Content-Type: application/json" \
  -d '{"html": "<table><tr><th>Name</th></tr><tr><td>John</td></tr></table>"}'
using var client = new HttpClient();
client.DefaultRequestHeaders.Add("X-API-Key", "df_your_api_key_here");

var json = @"{""html"": ""<table><tr><th>Name</th></tr><tr><td>John</td></tr></table>""}";
var content = new StringContent(json, System.Text.Encoding.UTF8, "application/json");

var response = await client.PostAsync("https://docbutterfly.com/api/ParseHtmlTable", content);
response.EnsureSuccessStatusCode();

var result = await response.Content.ReadAsStringAsync();
Console.WriteLine(result);
import requests
import json

url = "https://docbutterfly.com/api/ParseHtmlTable"
headers = {
    "X-API-Key": "df_your_api_key_here",
    "Content-Type": "application/json"
}
payload = json.loads('{"html": "<table><tr><th>Name</th></tr><tr><td>John</td></tr></table>"}')

response = requests.post(url, headers=headers, json=payload)
response.raise_for_status()

data = response.json()
print(json.dumps(data, indent=2))
┌─────────────────────────────────────────────┐
│  Power Automate - HTTP Action               │
├─────────────────────────────────────────────┤
│                                             │
│  Method:  POST                              │
│  URI:     https://docbutterfly.com/api/ParseHtmlTable
│                                             │
│  Headers:                                   │
│    X-API-Key:    df_your_api_key_here       │
│    Content-Type: application/json           │
│                                             │
│  Body:                                      │
│    {
│      "html": "\u003Ctable\u003E\u003Ctr\u003E\u003Cth\u003EName\u003C/th\u003E\u003C/tr\u003E\u003Ctr\u003E\u003Ctd\u003EJohn\u003C/td\u003E\u003C/tr\u003E\u003C/table\u003E"
│    }
│                                             │
└─────────────────────────────────────────────┘

Steps:
1. Add an HTTP action to your flow
2. Set Method to "POST"
3. Set URI to "https://docbutterfly.com/api/ParseHtmlTable"
4. Add the headers shown above
5. Paste the Body JSON into the Body field
6. Replace placeholder values with dynamic content as needed
Try in Testbed

Remove Diacritics

POST /api/RemoveDiacritics 1 token

Remove accent marks from text.

Parameters
NameTypeRequiredDescription
text string required Text with diacritics
Request Example
JSON
{"text": "Hello World cafe resume"}
Response Example
JSON
{"result": "Hello World cafe resume"}
Code Examples
curl -X POST "https://docbutterfly.com/api/RemoveDiacritics" \
  -H "X-API-Key: df_your_api_key_here" \
  -H "Content-Type: application/json" \
  -d '{"text": "Hello World cafe resume"}'
using var client = new HttpClient();
client.DefaultRequestHeaders.Add("X-API-Key", "df_your_api_key_here");

var json = @"{""text"": ""Hello World cafe resume""}";
var content = new StringContent(json, System.Text.Encoding.UTF8, "application/json");

var response = await client.PostAsync("https://docbutterfly.com/api/RemoveDiacritics", content);
response.EnsureSuccessStatusCode();

var result = await response.Content.ReadAsStringAsync();
Console.WriteLine(result);
import requests
import json

url = "https://docbutterfly.com/api/RemoveDiacritics"
headers = {
    "X-API-Key": "df_your_api_key_here",
    "Content-Type": "application/json"
}
payload = json.loads('{"text": "Hello World cafe resume"}')

response = requests.post(url, headers=headers, json=payload)
response.raise_for_status()

data = response.json()
print(json.dumps(data, indent=2))
┌─────────────────────────────────────────────┐
│  Power Automate - HTTP Action               │
├─────────────────────────────────────────────┤
│                                             │
│  Method:  POST                              │
│  URI:     https://docbutterfly.com/api/RemoveDiacritics
│                                             │
│  Headers:                                   │
│    X-API-Key:    df_your_api_key_here       │
│    Content-Type: application/json           │
│                                             │
│  Body:                                      │
│    {
│      "text": "Hello World cafe resume"
│    }
│                                             │
└─────────────────────────────────────────────┘

Steps:
1. Add an HTTP action to your flow
2. Set Method to "POST"
3. Set URI to "https://docbutterfly.com/api/RemoveDiacritics"
4. Add the headers shown above
5. Paste the Body JSON into the Body field
6. Replace placeholder values with dynamic content as needed
Try in Testbed

Regex Replace

POST /api/RegexReplace 1 token

Replace text using regular expression.

Parameters
NameTypeRequiredDescription
text string required Source text
pattern string required Regex pattern
replacement string required Replacement string
flags string optional g, i, m (default: g)
Request Example
JSON
{"text": "Hello 123 World 456", "pattern": "\\d+", "replacement": "#", "flags": "g"}
Code Examples
curl -X POST "https://docbutterfly.com/api/RegexReplace" \
  -H "X-API-Key: df_your_api_key_here" \
  -H "Content-Type: application/json" \
  -d '{"text": "Hello 123 World 456", "pattern": "\\d+", "replacement": "#", "flags": "g"}'
using var client = new HttpClient();
client.DefaultRequestHeaders.Add("X-API-Key", "df_your_api_key_here");

var json = @"{""text"": ""Hello 123 World 456"", ""pattern"": ""\\d+"", ""replacement"": ""#"", ""flags"": ""g""}";
var content = new StringContent(json, System.Text.Encoding.UTF8, "application/json");

var response = await client.PostAsync("https://docbutterfly.com/api/RegexReplace", content);
response.EnsureSuccessStatusCode();

var result = await response.Content.ReadAsStringAsync();
Console.WriteLine(result);
import requests
import json

url = "https://docbutterfly.com/api/RegexReplace"
headers = {
    "X-API-Key": "df_your_api_key_here",
    "Content-Type": "application/json"
}
payload = json.loads('{"text": "Hello 123 World 456", "pattern": "\\d+", "replacement": "#", "flags": "g"}')

response = requests.post(url, headers=headers, json=payload)
response.raise_for_status()

data = response.json()
print(json.dumps(data, indent=2))
┌─────────────────────────────────────────────┐
│  Power Automate - HTTP Action               │
├─────────────────────────────────────────────┤
│                                             │
│  Method:  POST                              │
│  URI:     https://docbutterfly.com/api/RegexReplace
│                                             │
│  Headers:                                   │
│    X-API-Key:    df_your_api_key_here       │
│    Content-Type: application/json           │
│                                             │
│  Body:                                      │
│    {
│      "text": "Hello 123 World 456",
│      "pattern": "\\d\u002B",
│      "replacement": "#",
│      "flags": "g"
│    }
│                                             │
└─────────────────────────────────────────────┘

Steps:
1. Add an HTTP action to your flow
2. Set Method to "POST"
3. Set URI to "https://docbutterfly.com/api/RegexReplace"
4. Add the headers shown above
5. Paste the Body JSON into the Body field
6. Replace placeholder values with dynamic content as needed
Try in Testbed

Split Text

POST /api/SplitText 1 token

Split text by delimiter.

Parameters
NameTypeRequiredDescription
text string required Text to split
delimiter string required Delimiter
Request Example
JSON
{"text": "apple,banana,cherry", "delimiter": ","}
Response Example
JSON
{"parts": ["apple", "banana", "cherry"], "count": 3}
Code Examples
curl -X POST "https://docbutterfly.com/api/SplitText" \
  -H "X-API-Key: df_your_api_key_here" \
  -H "Content-Type: application/json" \
  -d '{"text": "apple,banana,cherry", "delimiter": ","}'
using var client = new HttpClient();
client.DefaultRequestHeaders.Add("X-API-Key", "df_your_api_key_here");

var json = @"{""text"": ""apple,banana,cherry"", ""delimiter"": "",""}";
var content = new StringContent(json, System.Text.Encoding.UTF8, "application/json");

var response = await client.PostAsync("https://docbutterfly.com/api/SplitText", content);
response.EnsureSuccessStatusCode();

var result = await response.Content.ReadAsStringAsync();
Console.WriteLine(result);
import requests
import json

url = "https://docbutterfly.com/api/SplitText"
headers = {
    "X-API-Key": "df_your_api_key_here",
    "Content-Type": "application/json"
}
payload = json.loads('{"text": "apple,banana,cherry", "delimiter": ","}')

response = requests.post(url, headers=headers, json=payload)
response.raise_for_status()

data = response.json()
print(json.dumps(data, indent=2))
┌─────────────────────────────────────────────┐
│  Power Automate - HTTP Action               │
├─────────────────────────────────────────────┤
│                                             │
│  Method:  POST                              │
│  URI:     https://docbutterfly.com/api/SplitText
│                                             │
│  Headers:                                   │
│    X-API-Key:    df_your_api_key_here       │
│    Content-Type: application/json           │
│                                             │
│  Body:                                      │
│    {
│      "text": "apple,banana,cherry",
│      "delimiter": ","
│    }
│                                             │
└─────────────────────────────────────────────┘

Steps:
1. Add an HTTP action to your flow
2. Set Method to "POST"
3. Set URI to "https://docbutterfly.com/api/SplitText"
4. Add the headers shown above
5. Paste the Body JSON into the Body field
6. Replace placeholder values with dynamic content as needed
Try in Testbed

Split Text by Regex

POST /api/SplitTextRegex 1 token

Split text using a regular expression.

Parameters
NameTypeRequiredDescription
text string required Text to split
pattern string required Regex pattern
Request Example
JSON
{"text": "apple123banana456cherry", "pattern": "\\d+"}
Code Examples
curl -X POST "https://docbutterfly.com/api/SplitTextRegex" \
  -H "X-API-Key: df_your_api_key_here" \
  -H "Content-Type: application/json" \
  -d '{"text": "apple123banana456cherry", "pattern": "\\d+"}'
using var client = new HttpClient();
client.DefaultRequestHeaders.Add("X-API-Key", "df_your_api_key_here");

var json = @"{""text"": ""apple123banana456cherry"", ""pattern"": ""\\d+""}";
var content = new StringContent(json, System.Text.Encoding.UTF8, "application/json");

var response = await client.PostAsync("https://docbutterfly.com/api/SplitTextRegex", content);
response.EnsureSuccessStatusCode();

var result = await response.Content.ReadAsStringAsync();
Console.WriteLine(result);
import requests
import json

url = "https://docbutterfly.com/api/SplitTextRegex"
headers = {
    "X-API-Key": "df_your_api_key_here",
    "Content-Type": "application/json"
}
payload = json.loads('{"text": "apple123banana456cherry", "pattern": "\\d+"}')

response = requests.post(url, headers=headers, json=payload)
response.raise_for_status()

data = response.json()
print(json.dumps(data, indent=2))
┌─────────────────────────────────────────────┐
│  Power Automate - HTTP Action               │
├─────────────────────────────────────────────┤
│                                             │
│  Method:  POST                              │
│  URI:     https://docbutterfly.com/api/SplitTextRegex
│                                             │
│  Headers:                                   │
│    X-API-Key:    df_your_api_key_here       │
│    Content-Type: application/json           │
│                                             │
│  Body:                                      │
│    {
│      "text": "apple123banana456cherry",
│      "pattern": "\\d\u002B"
│    }
│                                             │
└─────────────────────────────────────────────┘

Steps:
1. Add an HTTP action to your flow
2. Set Method to "POST"
3. Set URI to "https://docbutterfly.com/api/SplitTextRegex"
4. Add the headers shown above
5. Paste the Body JSON into the Body field
6. Replace placeholder values with dynamic content as needed
Try in Testbed

Change Text Case

POST /api/TextChangeCase 1 token

Change text case (upper, lower, title, camel, etc).

Parameters
NameTypeRequiredDescription
text string required Text to transform
caseType string required upper, lower, title, sentence, camel, pascal, snake, kebab
Request Example
JSON
{"text": "hello world example", "caseType": "title"}
Response Example
JSON
{"result": "Hello World Example"}
Code Examples
curl -X POST "https://docbutterfly.com/api/TextChangeCase" \
  -H "X-API-Key: df_your_api_key_here" \
  -H "Content-Type: application/json" \
  -d '{"text": "hello world example", "caseType": "title"}'
using var client = new HttpClient();
client.DefaultRequestHeaders.Add("X-API-Key", "df_your_api_key_here");

var json = @"{""text"": ""hello world example"", ""caseType"": ""title""}";
var content = new StringContent(json, System.Text.Encoding.UTF8, "application/json");

var response = await client.PostAsync("https://docbutterfly.com/api/TextChangeCase", content);
response.EnsureSuccessStatusCode();

var result = await response.Content.ReadAsStringAsync();
Console.WriteLine(result);
import requests
import json

url = "https://docbutterfly.com/api/TextChangeCase"
headers = {
    "X-API-Key": "df_your_api_key_here",
    "Content-Type": "application/json"
}
payload = json.loads('{"text": "hello world example", "caseType": "title"}')

response = requests.post(url, headers=headers, json=payload)
response.raise_for_status()

data = response.json()
print(json.dumps(data, indent=2))
┌─────────────────────────────────────────────┐
│  Power Automate - HTTP Action               │
├─────────────────────────────────────────────┤
│                                             │
│  Method:  POST                              │
│  URI:     https://docbutterfly.com/api/TextChangeCase
│                                             │
│  Headers:                                   │
│    X-API-Key:    df_your_api_key_here       │
│    Content-Type: application/json           │
│                                             │
│  Body:                                      │
│    {
│      "text": "hello world example",
│      "caseType": "title"
│    }
│                                             │
└─────────────────────────────────────────────┘

Steps:
1. Add an HTTP action to your flow
2. Set Method to "POST"
3. Set URI to "https://docbutterfly.com/api/TextChangeCase"
4. Add the headers shown above
5. Paste the Body JSON into the Body field
6. Replace placeholder values with dynamic content as needed
Try in Testbed

Validate Email

POST /api/ValidateEmail 1 token

Validate an email address format.

Parameters
NameTypeRequiredDescription
email string required Email to validate
Request Example
JSON
{"email": "user@example.com"}
Response Example
JSON
{"valid": true}
Code Examples
curl -X POST "https://docbutterfly.com/api/ValidateEmail" \
  -H "X-API-Key: df_your_api_key_here" \
  -H "Content-Type: application/json" \
  -d '{"email": "user@example.com"}'
using var client = new HttpClient();
client.DefaultRequestHeaders.Add("X-API-Key", "df_your_api_key_here");

var json = @"{""email"": ""user@example.com""}";
var content = new StringContent(json, System.Text.Encoding.UTF8, "application/json");

var response = await client.PostAsync("https://docbutterfly.com/api/ValidateEmail", content);
response.EnsureSuccessStatusCode();

var result = await response.Content.ReadAsStringAsync();
Console.WriteLine(result);
import requests
import json

url = "https://docbutterfly.com/api/ValidateEmail"
headers = {
    "X-API-Key": "df_your_api_key_here",
    "Content-Type": "application/json"
}
payload = json.loads('{"email": "user@example.com"}')

response = requests.post(url, headers=headers, json=payload)
response.raise_for_status()

data = response.json()
print(json.dumps(data, indent=2))
┌─────────────────────────────────────────────┐
│  Power Automate - HTTP Action               │
├─────────────────────────────────────────────┤
│                                             │
│  Method:  POST                              │
│  URI:     https://docbutterfly.com/api/ValidateEmail
│                                             │
│  Headers:                                   │
│    X-API-Key:    df_your_api_key_here       │
│    Content-Type: application/json           │
│                                             │
│  Body:                                      │
│    {
│      "email": "user@example.com"
│    }
│                                             │
└─────────────────────────────────────────────┘

Steps:
1. Add an HTTP action to your flow
2. Set Method to "POST"
3. Set URI to "https://docbutterfly.com/api/ValidateEmail"
4. Add the headers shown above
5. Paste the Body JSON into the Body field
6. Replace placeholder values with dynamic content as needed
Try in Testbed

Validate GUID

POST /api/ValidateGuid 1 token

Validate a GUID/UUID format.

Parameters
NameTypeRequiredDescription
guid string required GUID to validate
Request Example
JSON
{"guid": "550e8400-e29b-41d4-a716-446655440000"}
Code Examples
curl -X POST "https://docbutterfly.com/api/ValidateGuid" \
  -H "X-API-Key: df_your_api_key_here" \
  -H "Content-Type: application/json" \
  -d '{"guid": "550e8400-e29b-41d4-a716-446655440000"}'
using var client = new HttpClient();
client.DefaultRequestHeaders.Add("X-API-Key", "df_your_api_key_here");

var json = @"{""guid"": ""550e8400-e29b-41d4-a716-446655440000""}";
var content = new StringContent(json, System.Text.Encoding.UTF8, "application/json");

var response = await client.PostAsync("https://docbutterfly.com/api/ValidateGuid", content);
response.EnsureSuccessStatusCode();

var result = await response.Content.ReadAsStringAsync();
Console.WriteLine(result);
import requests
import json

url = "https://docbutterfly.com/api/ValidateGuid"
headers = {
    "X-API-Key": "df_your_api_key_here",
    "Content-Type": "application/json"
}
payload = json.loads('{"guid": "550e8400-e29b-41d4-a716-446655440000"}')

response = requests.post(url, headers=headers, json=payload)
response.raise_for_status()

data = response.json()
print(json.dumps(data, indent=2))
┌─────────────────────────────────────────────┐
│  Power Automate - HTTP Action               │
├─────────────────────────────────────────────┤
│                                             │
│  Method:  POST                              │
│  URI:     https://docbutterfly.com/api/ValidateGuid
│                                             │
│  Headers:                                   │
│    X-API-Key:    df_your_api_key_here       │
│    Content-Type: application/json           │
│                                             │
│  Body:                                      │
│    {
│      "guid": "550e8400-e29b-41d4-a716-446655440000"
│    }
│                                             │
└─────────────────────────────────────────────┘

Steps:
1. Add an HTTP action to your flow
2. Set Method to "POST"
3. Set URI to "https://docbutterfly.com/api/ValidateGuid"
4. Add the headers shown above
5. Paste the Body JSON into the Body field
6. Replace placeholder values with dynamic content as needed
Try in Testbed

Validate JSON

POST /api/ValidateJson 1 token

Validate a JSON string.

Parameters
NameTypeRequiredDescription
json string required JSON string to validate
Request Example
JSON
{"json": "{\"name\":\"John\",\"age\":30}"}
Code Examples
curl -X POST "https://docbutterfly.com/api/ValidateJson" \
  -H "X-API-Key: df_your_api_key_here" \
  -H "Content-Type: application/json" \
  -d '{"json": "{\"name\":\"John\",\"age\":30}"}'
using var client = new HttpClient();
client.DefaultRequestHeaders.Add("X-API-Key", "df_your_api_key_here");

var json = @"{""json"": ""{\""name\"":\""John\"",\""age\"":30}""}";
var content = new StringContent(json, System.Text.Encoding.UTF8, "application/json");

var response = await client.PostAsync("https://docbutterfly.com/api/ValidateJson", content);
response.EnsureSuccessStatusCode();

var result = await response.Content.ReadAsStringAsync();
Console.WriteLine(result);
import requests
import json

url = "https://docbutterfly.com/api/ValidateJson"
headers = {
    "X-API-Key": "df_your_api_key_here",
    "Content-Type": "application/json"
}
payload = json.loads('{"json": "{\"name\":\"John\",\"age\":30}"}')

response = requests.post(url, headers=headers, json=payload)
response.raise_for_status()

data = response.json()
print(json.dumps(data, indent=2))
┌─────────────────────────────────────────────┐
│  Power Automate - HTTP Action               │
├─────────────────────────────────────────────┤
│                                             │
│  Method:  POST                              │
│  URI:     https://docbutterfly.com/api/ValidateJson
│                                             │
│  Headers:                                   │
│    X-API-Key:    df_your_api_key_here       │
│    Content-Type: application/json           │
│                                             │
│  Body:                                      │
│    {
│      "json": "{\u0022name\u0022:\u0022John\u0022,\u0022age\u0022:30}"
│    }
│                                             │
└─────────────────────────────────────────────┘

Steps:
1. Add an HTTP action to your flow
2. Set Method to "POST"
3. Set URI to "https://docbutterfly.com/api/ValidateJson"
4. Add the headers shown above
5. Paste the Body JSON into the Body field
6. Replace placeholder values with dynamic content as needed
Try in Testbed

Validate URL

POST /api/ValidateUrl 1 token

Validate a URL format.

Parameters
NameTypeRequiredDescription
url string required URL to validate
Request Example
JSON
{"url": "https://example.com/path?query=value"}
Code Examples
curl -X POST "https://docbutterfly.com/api/ValidateUrl" \
  -H "X-API-Key: df_your_api_key_here" \
  -H "Content-Type: application/json" \
  -d '{"url": "https://example.com/path?query=value"}'
using var client = new HttpClient();
client.DefaultRequestHeaders.Add("X-API-Key", "df_your_api_key_here");

var json = @"{""url"": ""https://example.com/path?query=value""}";
var content = new StringContent(json, System.Text.Encoding.UTF8, "application/json");

var response = await client.PostAsync("https://docbutterfly.com/api/ValidateUrl", content);
response.EnsureSuccessStatusCode();

var result = await response.Content.ReadAsStringAsync();
Console.WriteLine(result);
import requests
import json

url = "https://docbutterfly.com/api/ValidateUrl"
headers = {
    "X-API-Key": "df_your_api_key_here",
    "Content-Type": "application/json"
}
payload = json.loads('{"url": "https://example.com/path?query=value"}')

response = requests.post(url, headers=headers, json=payload)
response.raise_for_status()

data = response.json()
print(json.dumps(data, indent=2))
┌─────────────────────────────────────────────┐
│  Power Automate - HTTP Action               │
├─────────────────────────────────────────────┤
│                                             │
│  Method:  POST                              │
│  URI:     https://docbutterfly.com/api/ValidateUrl
│                                             │
│  Headers:                                   │
│    X-API-Key:    df_your_api_key_here       │
│    Content-Type: application/json           │
│                                             │
│  Body:                                      │
│    {
│      "url": "https://example.com/path?query=value"
│    }
│                                             │
└─────────────────────────────────────────────┘

Steps:
1. Add an HTTP action to your flow
2. Set Method to "POST"
3. Set URI to "https://docbutterfly.com/api/ValidateUrl"
4. Add the headers shown above
5. Paste the Body JSON into the Body field
6. Replace placeholder values with dynamic content as needed
Try in Testbed

Verify URL Available

POST /api/VerifyUrlAvailable 1 token

Check if a URL is reachable.

Parameters
NameTypeRequiredDescription
url string required URL to check
timeout number optional Timeout in ms (default: 10000)
Request Example
JSON
{"url": "https://example.com", "timeout": 5000}
Response Example
JSON
{"available": true, "statusCode": 200, "responseTime": 245}
Code Examples
curl -X POST "https://docbutterfly.com/api/VerifyUrlAvailable" \
  -H "X-API-Key: df_your_api_key_here" \
  -H "Content-Type: application/json" \
  -d '{"url": "https://example.com", "timeout": 5000}'
using var client = new HttpClient();
client.DefaultRequestHeaders.Add("X-API-Key", "df_your_api_key_here");

var json = @"{""url"": ""https://example.com"", ""timeout"": 5000}";
var content = new StringContent(json, System.Text.Encoding.UTF8, "application/json");

var response = await client.PostAsync("https://docbutterfly.com/api/VerifyUrlAvailable", content);
response.EnsureSuccessStatusCode();

var result = await response.Content.ReadAsStringAsync();
Console.WriteLine(result);
import requests
import json

url = "https://docbutterfly.com/api/VerifyUrlAvailable"
headers = {
    "X-API-Key": "df_your_api_key_here",
    "Content-Type": "application/json"
}
payload = json.loads('{"url": "https://example.com", "timeout": 5000}')

response = requests.post(url, headers=headers, json=payload)
response.raise_for_status()

data = response.json()
print(json.dumps(data, indent=2))
┌─────────────────────────────────────────────┐
│  Power Automate - HTTP Action               │
├─────────────────────────────────────────────┤
│                                             │
│  Method:  POST                              │
│  URI:     https://docbutterfly.com/api/VerifyUrlAvailable
│                                             │
│  Headers:                                   │
│    X-API-Key:    df_your_api_key_here       │
│    Content-Type: application/json           │
│                                             │
│  Body:                                      │
│    {
│      "url": "https://example.com",
│      "timeout": 5000
│    }
│                                             │
└─────────────────────────────────────────────┘

Steps:
1. Add an HTTP action to your flow
2. Set Method to "POST"
3. Set URI to "https://docbutterfly.com/api/VerifyUrlAvailable"
4. Add the headers shown above
5. Paste the Body JSON into the Body field
6. Replace placeholder values with dynamic content as needed
Try in Testbed