addedInput schema / additionalProperties
Added value: +false
addedInput schema / properties / input
Added value: +{
+ "additionalProperties": true,
+ "description": "Operation payload for assembleClaims (claim fields) or signHmac (token parts).",
+ "properties": {
+ "alg": {
+ "description": "HMAC algorithm for signHmac when no header.alg is given (default HS256). Asymmetric algorithms are rejected server-side.",
+ "enum": [
+ "HS256",
+ "HS384",
+ "HS512"
+ ],
+ "type": "string"
+ },
+ "aud": {
+ "description": "Audience claim (assembleClaims).",
+ "type": "string"
+ },
+ "customClaims": {
+ "description": "Extra claims merged last (assembleClaims); JSON object or JSON object string. Never overrides a standard claim already set.",
+ "type": [
+ "object",
+ "string"
+ ]
+ },
+ "exp": {
+ "description": "Expiry (assembleClaims): treated as seconds-from-iat when 1000000000 or less, else absolute epoch.",
+ "type": [
+ "integer",
+ "string"
+ ]
+ },
+ "header": {
+ "description": "JOSE header for signHmac; alg here wins over the top-level alg. typ defaults to JWT.",
+ "type": "object"
+ },
+ "iat": {
+ "description": "Issued-at (assembleClaims); defaults to now (or epoch 0 if now absent).",
+ "type": [
+ "integer",
+ "string"
+ ]
+ },
+ "iss": {
+ "description": "Issuer claim (assembleClaims).",
+ "type": "string"
+ },
+ "jti": {
+ "description": "Token ID claim (assembleClaims).",
+ "type": "string"
+ },
+ "nbf": {
+ "description": "Not-before (assembleClaims): delta-from-iat when 1000000000 or less, else absolute epoch.",
+ "type": [
+ "integer",
+ "string"
+ ]
+ },
+ "now": {
+ "description": "Current epoch seconds used to resolve iat and exp/nbf deltas (assembleClaims).",
+ "type": "integer"
+ },
+ "payload": {
+ "description": "Claim set object to sign (signHmac). Required for signHmac.",
+ "type": "object"
+ },
+ "secret": {
+ "description": "HMAC secret (UTF-8) for signHmac. Required for signHmac.",
+ "type": "string"
+ },
+ "sub": {
+ "description": "Subject claim (assembleClaims).",
+ "type": "string"
+ }
+ },
+ "type": "object"
+}
addedInput schema / properties / now
Added value: +{
+ "description": "Current time in epoch seconds for exp/nbf/iat checks on decode. Omit to compare against epoch 0 (relative-time strings only).",
+ "type": [
+ "integer",
+ "null"
+ ]
+}
addedInput schema / properties / operation / description
Added value: +"Action to run. decode: parse a token (no signature check). validate: verify an HMAC signature plus claim validity. signHmac: mint an HMAC-signed token. assembleClaims: build a claim payload. presets: list curated claim-set presets. standardClaims: list RFC 7519 registered-claim docs."
addedInput schema / properties / operation / enum
Added value: +[
+ "decode",
+ "validate",
+ "signHmac",
+ "assembleClaims",
+ "presets",
+ "standardClaims"
+]
addedInput schema / properties / options
Added value: +{
+ "additionalProperties": false,
+ "description": "Claim-check settings for validate (ignored for other operations).",
+ "properties": {
+ "expectedAudience": {
+ "description": "If set, aud must equal or contain this.",
+ "type": "string"
+ },
+ "expectedIssuer": {
+ "description": "If set, iss must equal this exactly.",
+ "type": "string"
+ },
+ "leeway": {
+ "default": 0,
+ "description": "Clock-skew tolerance in seconds applied to exp/nbf.",
+ "minimum": 0,
+ "type": "integer"
+ },
+ "now": {
+ "description": "Current time in epoch seconds for exp/nbf/iat checks.",
+ "type": "integer"
+ }
+ },
+ "type": "object"
+}
addedInput schema / properties / secret
Added value: +{
+ "description": "Shared HMAC secret (UTF-8) used by validate to recompute the signature. Required for HMAC validation; ignored otherwise.",
+ "type": "string"
+}
addedInput schema / properties / token / description
Added value: +"Compact JWS string (header.payload.signature). Required for decode and validate; ignored otherwise."
changedInput schema / required
Previous value: -[
- "operation",
- "token"
-]New value: +[
+ "operation"
+]
changedOutput schema / (root)
Previous value: -nullNew value: +{
+ "properties": {
+ "operation": {
+ "description": "The operation that was executed.",
+ "type": "string"
+ },
+ "result": {
+ "description": "Operation-specific output. decode: {header,payload,signature,raw,claims,warnings,error}. validate: {valid,errors,header,payload,signatureValid,claimsValid}. signHmac: {token,header,payload}. assembleClaims: {claims,warnings}. presets: {presets[]}. standardClaims: {claims[]}.",
+ "properties": {
+ "claims": {
+ "description": "decode/assembleClaims: the parsed or built claim object (iss/sub/aud/exp/nbf/iat/jti plus a custom map; exp/nbf/iat expand to epoch/iso/relative on decode). standardClaims: an array of registered-claim doc objects.",
+ "type": [
+ "object",
+ "array"
+ ]
+ },
+ "claimsValid": {
+ "description": "True if all non-signature claim checks passed (validate).",
+ "type": "boolean"
+ },
+ "error": {
+ "description": "Always null on success (decode).",
+ "type": [
+ "string",
+ "null"
+ ]
+ },
+ "errors": {
+ "description": "Signature and claim failures (validate).",
+ "items": {
+ "type": "string"
+ },
+ "type": "array"
+ },
+ "header": {
+ "description": "Decoded JOSE header (decode/validate/signHmac).",
+ "type": "object"
+ },
+ "payload": {
+ "description": "Decoded or signed claim set (decode/validate/signHmac).",
+ "type": "object"
+ },
+ "presets": {
+ "description": "Curated claim-set presets (presets operation), each with id, name, description, header, payload.",
+ "items": {
+ "type": "object"
+ },
+ "type": "array"
+ },
+ "raw": {
+ "description": "The three base64url segments as received (decode).",
+ "properties": {
+ "header": {
+ "description": "base64url header segment.",
+ "type": "string"
+ },
+ "payload": {
+ "description": "base64url payload segment.",
+ "type": "string"
+ },
+ "signature": {
+ "description": "base64url signature segment.",
+ "type": "string"
+ }
+ },
+ "type": "object"
+ },
+ "signature": {
+ "description": "Raw base64url signature segment (decode).",
+ "type": "string"
+ },
+ "signatureValid": {
+ "description": "HMAC signature result; null for asymmetric algorithms not verified server-side (validate).",
+ "type": [
+ "boolean",
+ "null"
+ ]
+ },
+ "token": {
+ "description": "The signed compact JWS (signHmac).",
+ "type": "string"
+ },
+ "valid": {
+ "description": "True only if the signature verified AND no claim errors (validate).",
+ "type": "boolean"
+ },
+ "warnings": {
+ "description": "Advisory notes, e.g. alg none or expired token (decode/assembleClaims).",
+ "items": {
+ "type": "string"
+ },
+ "type": "array"
+ }
+ },
+ "type": "object"
+ },
+ "success": {
+ "description": "Always true on a 2xx response.",
+ "type": "boolean"
+ }
+ },
+ "type": "object"
+}