Skip to content

Instantly share code, notes, and snippets.

@theabhishek2511
Created June 13, 2017 06:51
Show Gist options
  • Save theabhishek2511/6516bbf4626b9c2e450e681a8b64bb7d to your computer and use it in GitHub Desktop.
Save theabhishek2511/6516bbf4626b9c2e450e681a8b64bb7d to your computer and use it in GitHub Desktop.

Basic

There are two parts of creating the text. First, you call API 1 to edit the text and obtain an ID. Next, you call API 2 and render the text. After that, a link to the image can be formed using the ID you obtained.

API 1

POST https://cooltext.com/PostChange -H 'content-type: application/x-www-form-urlencoded'

Known Params:

All params are URL encoded.

Parameter Possible Values Comments
LogoID integer 4 is for Burning text. can figure out the rest using website?
Text String url encoded i guess?
FontSize integer default is 70
Color1_color color code face color. default for Burning is red (#FF0000)
Integer1 integer? depends on your LogoID values. for Burning it is the fire angle, default is 15.
Boolean1 'on' or 'off' transparency
Integer9 integer Alignment, i.e. topleft, topcenter, topright, etc. goes from 0 to 8.
Integer13 integer or 'on' width. 'on' means automatic.
Integer12 integer or 'on' height. 'on' means automatic.
BackgroundColor_color color code BG Color. has no effect if Boolean1 is 'on'. default is white (#FFFFFF)

Response:

Key Type Comments
logoId int the logo id you used in your request
newId int your cooltext image's ID.
renderLocation string direct URL to the cooltext image.
Will not work until you call API 2. Will only stay for one hour, so after you call API 2, save the image.
isAnimated boolean whether the image is animated.

API 2

POST https://cooltext.com/Render -H 'content-type: application/x-www-form-urlencoded'

Known Params:

All params are URL encoded.

Parameter Possible Values Comments
logoId integer the newId you got from API 1

Response:

Key Type Comments
redirectLocation string this is used by the website internally to redirect after rendering is done. you can ignore this.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment