Base URL: https://htmlmix.pro/api/
Auth Type: Bearer Token
All requests must include the Authorization header:
Authorization: Bearer YOUR_API_TOKEN
| Code | Message | Description |
|---|---|---|
400 |
Missing required parameters | Occurs when source is not provided. |
400 |
The action parameter was not passed. |
Occurs when actions is not specified correctly.
|
401 |
Invalid API token or user not found | Occurs when the API token is missing or invalid. |
403 |
The quota of requests has been depleted | Quota for API usage is exhausted. |
403 |
Subscription expired | Subscription has ended, access denied. |
429 |
Too Many Requests | Exceeded request limit (1 request per 60 sec). |
Method: POST
URL:
https://htmlmix.pro/api?action=getRandomizeLetter
| № | Parameter | Type | Required | Default Value | Description |
|---|---|---|---|---|---|
| 1 | source |
string | yes | — | HTML template code to process. |
| 2 | modeMorphing |
array | no | Parameters for morphing letter. | |
| 2.1 | randomTableLayot |
integer | no | 0 | Random table layout (0 - off, 1 - on). |
| 2.2 | splitInversion |
integer | no | 0 | Split words into two parts and then invert each one and add a style direction: rtl; unicode-bidi: bidi-override; display: inline-block; (0 - off, 1 - on). |
| 2.3 | wrapLettersInTags |
integer | no | 0 | Wrap words in a span tag (0 - off, 1 - on). |
| 2.4 | synonymsAI |
integer | no | 0 | Generate synonyms of your text in a template using AI (0 - off, 1 - on). |
| 2.5 | zeroFront |
integer | no | 0 | Inserting special tags with styles that will contain a random symbol or trending words of the selected region. (0 - off, 1 - on). |
| 3 | settings |
array | no | Parameters with different settings. | |
| 3.1 | separateCssClasses |
integer | no | 1 | Separate CSS classes into individual classes (0 - off, 1 - on). |
| 3.2 | inlineStylesToClasses |
integer | no | 0 | Convert inline styles to classes (0 - off, 1 - on). |
| 3.3 | insertGarbageCode |
integer | no | 1 | Insert random "garbage" code (0 - off, 1 - on). |
| 3.4 | insertGarbageCodeProbability |
integer | no | 15 | Probability % of inserting "garbage" code (1 - 100). |
| 3.5 | randomChangeTags |
integer | no | 1 | Random tag replacement in the entire template (0 - off, 1 - on). |
| 3.6 | randomizeFonts |
integer | no | 0 | Random font replacement in the template. Only standard fonts that are compatible for all devices are used (0 - off, 1 - on). |
| 3.7 | changeNameClass |
integer | no | 1 | Classes and ID renamed to random names (0 - off, 1 - on). |
| 3.8 | fileCountGen |
integer | no | 10 | Number of generated letters. |
| 3.9 | colorChangeRange |
integer | no | 8 | Color change range (0-16). |
| 3.10 | paddingChangeRange |
integer | no | 2 | Padding change range. |
| 3.11 | temperature |
float | no | 0.6 | AI creativity level. |
| 3.12 | startMacros |
string | no | "[%%" | Macro start template. |
| 3.13 | endMacros |
string | no | "%%]" | Macro end template. |
| 3.14 | startSpintax |
string | no | "{" | Spintax start template. |
| 3.15 | separatorSpintax |
string | no | "|" | Spintax separator template. |
| 3.16 | endSpintax |
string | no | "}" | Spintax end template. |
| 3.17 | listLinks |
string | no | "" | A list of your links that will be used when converting the template to an image. |
| 3.18 | garbageToLink |
integer | no | 1 | Convert garbage text to links (0 - off, 1 - on). |
| 3.19 | addRandomComments |
integer | no | 1 | Add random comments to HTML (0 - off, 1 - on). |
| 3.20 | selectedAttributes |
array | no | ["background", "background-color", "bgcolor", "border-bottom-color", "border-bottom-width", "border-color", "border-radius", "border-top-color", "border-top-width", "border-width", "box-shadow", "cellpadding", "cellspacing", "color", "height", "letter-spacing", "line-height", "margin", "margin-bottom", "margin-left", "margin-right", "margin-top", "max-height", "padding", "padding-bottom", "padding-left", "padding-right", "padding-top", "text-decoration", "valign", "width", "word-spacing"] | List of attributes that will be processed. |
| 3.21 | selectedGarbageTags |
array | no | ["span", "bdi", "bdo", "data", "samp", "var", "abbr", "time", "dfn", "code", "kbd", "sub", "sup", "rp", "rt", "u", "i", "em", "b", "strong", "small", "cite", "mark", "del", "ins", "s", "font", "label", "wbr", "big", "tt"] | List of HTML tags to use for garbage code. Only these tags will be randomly inserted when insertGarbageCode is enabled. Total: 32 tags available. |
| 3.22 | addPreviewText |
integer | no | 0 | Add preview text to the letter (0 - off, 1 - on). |
| 3.23 | previewTextAI |
integer | no | 0 | AI randomization for preview text (0 - off, 1 - on). |
| 3.24 | previewTextCustom |
string | no | "" | Custom preview text. |
| 3.25 | takeSequentially |
integer | no | 0 | Take links or text sequentially (0 - off, 1 - on). |
| 3.26 | addRandomAuth |
integer | no | 0 | Add random authentication to links (0 - off, 1 - on). |
| 4 | additionalSettings |
array | no | Parameters with different additional settings. | |
| 4.1 | splitInversionWordsLength |
integer | no | 6 | Length of words that will be processed if inversion is enabled. |
| 4.2 | probabilityInvers |
integer | no | 40 | Probability of word processing in percent. |
| 4.3 | zeroFrontLengthCharacters |
integer | no | 2 | Number of characters after which the zerofront will be executed. |
| 4.4 | insertTrends |
integer | no | 0 | Using google trends instead of random characters when working zerofront (0 - off, 1 - on). |
| 4.5 | regionTrends |
string | no | "US" | Google Trends Region. Can take one of the following values: "BR", "CA", "CN", "CZ", "DE", "DK", "ES", "FR", "GB", "IN", "JP", "NL", "NO", "NZ", "PL", "RU", "SE", "UA", "US" |
| 4.6 | valueStopWords |
string | no | "" | Words that will be ignored during processing. |
| 4.7 | addSchemaCalendar |
integer | no | 0 | Add schema.org calendar to the letter (0 - off, 1 - on). |
| 5 | trustLinks |
array | no | Options using trusted links. | |
| 5.1 | insertTrustLink |
integer | no | 0 | Enables the option to insert trusted links (0 - off, 1 - on). |
| 5.2 | insertTrustWiki |
integer | no | 0 | Insert a link from Wikipedia (0 - off, 1 - on). |
| 5.3 | insertTrustWikiText |
integer | no | 0 | Inserts invisible text from a wikipedia link (0 - off, 1 - on). |
| 5.4 | insertTrustReddit |
integer | no | 0 | Insert a link from Reddit (0 - off, 1 - on) |
| 5.5 | insertTrustRedditText |
integer | no | 0 | Inserts invisible text from a Reddit link (0 - off, 1 - on). |
| 5.6 | trustLinkHidden |
integer | no | 1 | Hide inserted link (0 - off, 1 - on). |
| 5.7 | insertTrustLinkLengthMin |
integer | no | 10 | The minimum number of blank lines before the inserted link (0-100). |
| 5.8 | insertTrustLinkLengthMax |
integer | no | 30 | The maximum number of blank lines before the inserted link (0-999). |
| 5.9 | insertTrustLinkKeywordWiki |
string | no | "" | Keyword for inserting a link from wikipedia. If not found by keyword then random link will be inserted. |
| 5.10 | insertTrustLinkKeywordReddit |
string | no | "" | Keyword for inserting a link from Reddit. If not found by keyword then random link will be inserted. |
| 5.11 | listTrustLinks |
string | no | "" | List own trust links format https://trust.com your_anchor\n |
| 5.12 | languageInsertTextWiki |
string | no | "en" | The language of wikipedia. |
| 5.13 | trustLinkPosition |
string | no | "bottom" | The position of the trust link (bottom, top, random). |
| 6 | imagesFunctions |
array | no | Options to convert email to image and upload images to trusted hosting. | |
| 6.1 | convertTemplateToImage |
integer | no | 0 | Converts letter to a base64 image (0 - off, 1 - on). |
| 6.2 |
convertTemplateToImageUploadHosting
|
integer | no | 0 | Upload the converted image to a trusted hosting (0 - off, 1 - on). |
| 6.3 |
uploadImgToHosting
|
integer | no | 0 | Automatically upload all images from the letter to a trusted hosting service (0 - off, 1 - on). |
| 6.4 | uploadServices |
array | no | ["GoogleCloud", "AmazonAWS", "Backblaze", "BunnyStorage"] | List of services to upload images to. Can take one of the following values: "GoogleCloud", "AmazonAWS", "Backblaze", "BunnyStorage", "Cloudflare", "Bitbucket", "AzureStorage" |
| 6.5 | convertImgToBackground |
integer | no | 0 | Converts images to background images (0 - off, 1 - on). |
curl -X POST "https://htmlmix.pro/api?action=getRandomizeLetter" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"source": "Your html",
"modeMorphing": {
"randomTableLayot": 1,
"splitInversion": 1,
"zeroFront": 1,
"synonymsAI": 1
},
"settings": {
"startMacros": "[%%",
"endMacros": "%%]",
"startSpintax": "{",
"separatorSpintax": "|",
"endSpintax": "}",
"temperature": 0.6,
"insertGarbageCode": 1,
"insertGarbageCodeProbability": 15,
"selectedGarbageTags": ["span", "strong", "em", "mark", "del", "font"],
"garbageToLink": 1,
"addRandomComments": 1
},
"additionalSettings": {
"zeroFrontLengthCharacters": 4,
"insertTrends": 1,
"regionTrends": "US",
"valueStopWords": ""
},
"trustLinks": {
"insertTrustLink": 1,
"insertTrustWiki": 1,
"trustLinkHidden": 0,
"insertTrustLinkLengthMin": 10,
"insertTrustLinkLengthMax": 30,
"insertTrustLinkKeywordWiki": "Bank",
"languageInsertTextWiki": "en"
},
"imagesFunctions": {
"convertTemplateToImage": 1,
"convertTemplateToImageUploadHosting": 0,
"uploadImgToHosting": 1
}
}'
import requests
url = "https://htmlmix.pro/api?action=getRandomizeLetter"
headers = {
"Authorization": "Bearer YOUR_API_TOKEN",
"Content-Type": "application/json"
}
data = {
"source": "Your html",
"modeMorphing": {
"randomTableLayot": 1,
"splitInversion": 1,
"zeroFront": 1,
"synonymsAI": 1
},
"settings": {
"startMacros": "[%%",
"endMacros": "%%]",
"temperature": 0.6,
"insertGarbageCode": 1,
"insertGarbageCodeProbability": 15,
"selectedGarbageTags": ["span", "div", "strong", "em"],
"garbageToLink": 1,
"addRandomComments": 1
},
"additionalSettings": {
"zeroFrontLengthCharacters": 4,
"insertTrends": 1,
"regionTrends": "US",
"valueStopWords": ""
},
"trustLinks": {
"insertTrustLink": 1,
"insertTrustWiki": 1,
"trustLinkHidden": 0,
"insertTrustLinkLengthMin": 10,
"insertTrustLinkLengthMax": 30,
"insertTrustLinkKeywordWiki": "Bank",
"languageInsertTextWiki": "en"
},
"imagesFunctions": {
"convertTemplateToImage": 1,
"convertTemplateToImageUploadHosting": 0,
"uploadImgToHosting": 1
}
}
response = requests.post(url, json=data, headers=headers)
print(response.json())
{
"status": "success",
"html": ["html-1","html-2","html-3"....]
}
Method: POST
URL:
https://htmlmix.pro/api?action=getUserInfo
curl -X POST "https://htmlmix.pro/api?action=getUserInfo" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
import requests
url = "https://htmlmix.pro/api?action=getUserInfo"
headers = {
"Authorization": "Bearer YOUR_API_TOKEN",
"Content-Type": "application/json"
}
response = requests.post(url, headers=headers)
print(response.json())
{
"status": "success",
"user": {
"subscription_end_date": "2028-01-15",
"quota_api": 9992
}
}