Skip to content

Kasada ​

POST /v1/solve/kasada

By default, send only the site url. The server runs p.js → /fp → ips.js → /mfc → /tl and returns business headers in data.kpsdk_head.

payload.action switches to a short path. Missing, empty, or verify / kpsdk-head / headers / biz-headers all run the full pipeline.

payload ​

FieldAliasesMeaning
actionmodeverify (default) / mfc / cd / extract-salt
basePathbase_path / sdkPath / sdk_pathTenant prefix, e.g. https://host/{uuid}/{uuid}. Can also be stripped from url by dropping /mfc /tl /fp /p.js /ips.js
versionDefault j-1.2.904, written to x-kpsdk-v
hx_kpsdk_hIf set, skip GET /mfc
fcx_kpsdk_fcKept when passed with h
ctx_kpsdk_ctTogether with st, takes the short path and skips POST /tl
stx_kpsdk_stSee above
saltFor x-kpsdk-cd. Defaults to a value parsed from p.js
pjsscriptp.js source, used to extract salt
pjs_urlpjsUrlRemote p.js for extract-salt
workTimework_timePassed into cd
id / duration / clockOffsetMsclock_offset_msOptional cd fields
include_fcWhen true, write /mfc fc into kpsdk_head

The full pipeline also needs top-level url (home page or an already-known tenant prefix).

Default: full pipeline ​

json
{
  "url": "https://www.wizzair.com/",
  "timeout": 90000,
  "payload": { "version": "j-1.2.904" }
}

Skip home-page parsing when the tenant path is known:

json
{
  "url": "https://www.wizzair.com/",
  "timeout": 90000,
  "payload": {
    "basePath": "https://www.wizzair.com/149e9513-01fa-4fb0-aad4-566afd725d1b/2d206a39-8ed7-437e-a3be-862e0f06eea3"
  }
}

data (full pipeline) ​

json
{
  "kpsdk_head": {
    "x-kpsdk-ct": "...",
    "x-kpsdk-h": "...",
    "x-kpsdk-v": "j-1.2.904",
    "x-kpsdk-cd": "..."
  },
  "basePath": "https://www.wizzair.com/{uuid}/{uuid}",
  "ct": "...",
  "st": 123,
  "h": "...",
  "fc": "...",
  "version": "j-1.2.904",
  "cookie": "...",
  "tl_status": 200,
  "mfc_status": 200,
  "tl_body_len": 12345
}

Spread kpsdk_head onto later business requests. fc stays out of kpsdk_head unless include_fc is set.

If the page has no Kasada path: INVALID_INPUT, asking for payload.basePath.

Existing ct / st (short path) ​

When payload has both ct and st, /tl is skipped; only h and cd are filled in:

json
{
  "url": "https://www.wizzair.com/",
  "payload": {
    "ct": "...",
    "st": 123,
    "basePath": "https://www.wizzair.com/{uuid}/{uuid}"
  }
}

Returns { kpsdk_head, basePath, mfc_status }.

action=mfc ​

GET /mfc only, for h:

json
{
  "url": "https://www.wizzair.com/{uuid}/{uuid}",
  "payload": { "action": "mfc" }
}

data: { h, fc, status, basePath, version }. Missing url / basePath → INVALID_INPUT.

action=cd ​

Compute x-kpsdk-cd locally (no network; salt must be resolvable, it will not fetch p.js for you):

json
{
  "payload": {
    "action": "cd",
    "ct": "...",
    "st": 123,
    "salt": "..."
  }
}

data: { cd, salt }. Missing ct / st → INVALID_INPUT.

action=extract-salt ​

json
{
  "payload": {
    "action": "extract-salt",
    "pjs": "/* p.js source */"
  }
}

Or pass pjs_url and let the server fetch it. data is the salt extraction result (including salt).