Skip to main content
POST
Create Image

Request contract

  • Method and path: POST /apis/v1/htmlcss-to-image/create-image
  • Availability: enabled
  • Request URL template: https://api.aisa.one/apis/v1/htmlcss-to-image/create-image
  • Runtime facts: ecf7b25fc395f7aff68b9e1c0588b3d9a8bb0e613a7bdfd59ede194deb499492
Complete OpenAPI definition Effective request and pricing declaration (including authentication and referenced schemas):

Cost and request rules

Usage-based billing; Default request estimate: $0.0143 USD (not a fixed price). Declared unit rate: $0.000001 USD per provider_credit. Account-specific pricing and final settlement may differ. Published reference values are not an account-specific quote or a settled charge. For endpoints supporting X-AISA-Cost-Mode: quote, obtain a free quote for your exact request before execution; reconcile the settled cost with response metadata and Usage Logs. USD amounts use 1,000,000 integer micro-USD per dollar.
  • Default request reference estimate (USD): 0.0143
  • Declared unit rate (USD): 1e-06
  • Billing unit: provider_credit
  • Cost contract: response_units
  • Published reference multiplier: 1.0
  • Declared maximum count/units: 10000000
  • Settlement evidence source: response_body

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

application/json
html
string
required

HTML to render. Set this or url, but not both.

Minimum string length: 1
Example:

"<div class='card'>Hello</div>"

ms_delay
integer
required

Extra render delay in milliseconds, from 0 to 10000. Zero omits the explicit delay.

Required range: 1 <= x <= 10000
media_type
enum<string>
required

CSS media type used while rendering: screen or print.

Available options:
screen
render_when_ready
enum<boolean>
required

Wait until the page signals that rendering is ready.

Available options:
false
css
string

CSS applied to supplied HTML or injected into a captured webpage.

Example:

".card { padding: 24px; }"

url
string

Absolute, internet-reachable HTTP(S) webpage URL to capture. Set this or html, but not both; use headers for authenticated pages.

Example:

"https://example.com"

headers
object

HTTP headers sent to the captured page, with at most 20 case-insensitive names.

Example:
selector
string

CSS selector for the element to capture.

Example:

"#invoice"

timezone
string

IANA timezone exposed to the rendered page.

Example:

"America/New_York"

full_screen
boolean
default:false

Capture the full scrollable page instead of only the viewport.

max_wait_ms
integer

Maximum wait from 500 to 10000 milliseconds for page loading.

Required range: 500 <= x <= 10000
color_scheme
enum<string>

Preferred browser color scheme: light or dark.

Available options:
light,
dark
device_scale
number
default:2

Device scale factor from 0.1 to 3.

Required range: 0.1 <= x <= 3
google_fonts
string[]

Google Font family names to load while rendering.

Example:
viewport_width
integer

Viewport width in pixels, from 1 to 6000. Requires viewport_height.

Required range: 1 <= x <= 6000
viewport_height
integer

Viewport height in pixels. Requires viewport_width.

Required range: x >= 1
dedupe_duration_s
integer

Reuse a matching recent render for this many seconds. Allowed durations depend on the account plan; free accounts accept 0 or 2592000 (30 days).

Required range: x >= 0

Attempt to block common consent banners.

transparent_background
boolean
default:false

Render a transparent background where supported.

additional_header_origins
string[]

Up to 20 unique exact HTTP(S) origins that may also receive headers.

Maximum array length: 20
Example:
include_headers_on_subrequests
boolean
default:false

Also include supplied headers on page subrequests.

Response

Tool result data

id
string
required
url
string
required