Browser Feature Transformations

Execute Browser feature transformations

Changed on

Zephr HTML Features can be run in the browser by calling this API directly or using the Zephr Browser SDK. For compatibility with CDN, any web headers (Referrer, User-Agent) will be accepted and passed onto the rule engine.

Providing a JWT

Supply it as a jwt query parameter, an X-Blaize-Jwt header, an X-Zephr-Jwt header, an Authorization: Bearer header, or a blaize_jwt cookie. If more than one is present, the first found in that order is used.

post/zephr/feature-transformations

Request

  • Base URL: https://demo-site
  • URL: https://demo-site/zephr/feature-transformations
  • Auth: one of:
    • API key in cookie blaize_session
    • API key in query parameter jwt
    • API key in header x-blaize-jwt
    • API key in header x-zephr-jwt
    • HTTP bearer
    • API key in cookie blaize_jwt

Headers

Cookiestring

The session cookie.

Request body

sessionstring

The Zephr Session ID.

refererstring

Browser referer

pathstring

Request path, defaults to "/". If available, include the content ID as a query parameter. For example, /story.html?content_id=abc-123.

giftTokenstring

Token to provide access to content for one session.

customDataobject

Custom data to be used in Feature HTML browser rule. Accepts a JSON object

Example request

{
  "featureIds": [
    "featureX"
  ],
  "session": "xxx-xxx-xxx",
  "referer": "https://www.zephr.com/",
  "path": "/x.html",
  "content_metadata": {
    "content_id": "xxx-xxx-xxx"
  },
  "giftToken": "xxx-xxx-xxx",
  "customData": {
    "key": "value"
  }
}

Response

OK

Changes

    • breaking

      the / request property type changed from string to no type

    • warning

      removed the request property

    • warning

      removed the optional property from the response with the status

    • warning

      removed the optional property / from the response with the status

    • info

      added the optional property / to the response with the status