Storm docs logo
Search the docs.../
Explore Storm Products

Application Security Settings Update

Updates the stream security settings for an application.

Request

PropertyValue
MethodPATCH
URL/api/applications/{appName}/settings/security
Content-Typeapplication/json
AuthenticationBearer Token
Request
Code iconbash
curl -X PATCH "{BASE_URL}/api/applications/{appName}/settings/security" \
  -H "Authorization: Bearer YOUR_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"key": "value"}'

Path Parameters

ParameterTypeRequiredDescription
appNamestringYesApplication name
Request
Code iconbash
curl -X PATCH "{BASE_URL}/api/applications/{appName}/settings/security" \
  -H "Authorization: Bearer YOUR_TOKEN" \
  -H "Content-Type: application/json"

Request Body

ParameterTypeRequiredDescription
data.attributes.tokenProtectionEnabledbooleanNoEnable token protection
data.attributes.hashAlgorithmstringNoHash algorithm for tokens
data.attributes.tokenLifespanintegerNoToken lifespan in seconds
data.attributes.secretstringNoSecret key for token signing
data.attributes.domainAccessRightsarrayNoDomain access rules
data.attributes.domainAccessRights[].type"allow" | "deny"YesRule type
data.attributes.domainAccessRights[].domainstringYesDomain pattern ("*" for all)

Example Request

Example Request (Disable Token Protection)

Code iconjson
{
  "data": {
    "attributes": {
      "tokenProtectionEnabled": true,
      "hashAlgorithm": "sha256",
      "tokenLifespan": 600,
      "secret": "viewer-secret",
      "domainAccessRights": [
        {
          "type": "deny",
          "domain": "*"
        },
        {
          "type": "allow",
          "domain": "myplatform.com"
        }
      ]
    }
  }
}
Code iconjson
{
  "data": {
    "attributes": {
      "tokenProtectionEnabled": false
    }
  }
}

Response Body

Security Settings

ParameterTypeDescription
data.attributes.tokenProtectionEnabled.valuebooleanToken protection enabled status
data.attributes.tokenProtectionEnabled.editablebooleanIndicates if the field can be modified
data.attributes.tokenProtectionEnabled.lockedBystringLocked by environment variable (if present)
data.attributes.hashAlgorithm.valuestringHash algorithm for tokens
data.attributes.hashAlgorithm.editablebooleanIndicates if the field can be modified
data.attributes.hashAlgorithm.lockedBystringLocked by environment variable (if present)
data.attributes.tokenLifespan.valueintegerToken lifespan in seconds
data.attributes.tokenLifespan.editablebooleanIndicates if the field can be modified
data.attributes.tokenLifespan.lockedBystringLocked by environment variable (if present)
data.attributes.secret.valuestringSecret key for token signing
data.attributes.secret.editablebooleanIndicates if the field can be modified
data.attributes.secret.lockedBystringLocked by environment variable (if present)
data.attributes.domainAccessRightsarrayDomain access rules
data.attributes.domainAccessRights[].type.value"allow" | "deny"Rule type
data.attributes.domainAccessRights[].type.editablebooleanIndicates if the field can be modified
data.attributes.domainAccessRights[].domain.valuestringDomain pattern
data.attributes.domainAccessRights[].domain.editablebooleanIndicates if the field can be modified
messagestringResponse status message

Metadata

ParameterTypeDescription
meta.executionTimeintegerRequest processing time in milliseconds
meta.generatedAtintegerResponse generation timestamp (Unix timestamp in ms)
Successful Response (200)
Code iconjson
{
  "data": {
    "attributes": {
      "tokenProtectionEnabled": {
        "editable": true,
        "value": true
      },
      "hashAlgorithm": {
        "editable": true,
        "value": "sha256"
      },
      "tokenLifespan": {
        "editable": true,
        "value": 600
      },
      "secret": {
        "editable": true,
        "value": "viewer-secret"
      },
      "domainAccessRights": [
        {
          "type": {
            "editable": true,
            "value": "deny"
          },
          "domain": {
            "editable": true,
            "value": "*"
          }
        },
        {
          "type": {
            "editable": true,
            "value": "allow"
          },
          "domain": {
            "editable": true,
            "value": "myplatform.com"
          }
        }
      ]
    }
  },
  "meta": {
    "executionTime": 10,
    "generatedAt": 1766070953277
  },
  "message": "Security Settings have been updated"
}

Error Responses

Application Not Found (404)

ParameterTypeDescription
messagestringHuman-readable error message
Code iconjson
{
  "message": "Application not found"
}
Support Needed?

Create a free ticket and our support team will provide you necessary assistance.

Blog
Support
About us
Patents
Term of use
Privacy policy
Contact
©2026 Storm Streaming Media. All Rights Reserved.