tencent cloud

Feedback

Modifying HTTP Response Header

Last updated: 2022-08-01 15:48:29

    Overview

    You can customize, add, and delete headers in HTTP responses from nodes to clients, which will not affect the node cache. This feature can implement cross-origin access.

    Directions

    1. Log in to the EdgeOne console and click Rule engine on the left sidebar.
    2. On the rule engine page, select the target site and click to modify HTTP response header rules as needed.
      Note:

      Currently, you can configure and modify HTTP response headers only if the match condition is All (any request) or Host.

    Parameter description:

    Type Description
    Change It changes the specified header parameter to the set value.
    Note:
    • If the specified header doesn't exist, it will be added.
    • If the header already exists (even if there are multiple duplicate headers), the original header will be overwritten, and multiple duplicate headers will be merged into one for uniqueness.
    Add It adds the specified header.
    Note:
    If the header already exists (even if there are multiple duplicate headers), the original header will be overwritten, and multiple duplicate headers will be merged into one for uniqueness.
    Delete It deletes the specified header.

    Notes

    • A header parameter must be in the following format:
      • Parameter name: It can contain 1–100 digits, letters, and hyphens.
      • Parameter value: It can contain 1–1000 characters.
    • During one HTTP request header modification operation, you can add up to 30 headers of different types, which will be executed in sequence from top to bottom.
    • The following standard headers cannot be modified:
      Date
      Expires
      Content-Type
      Content-Encoding
      Content-Length
      Transfer-Encoding
      Cache-Control
      If-Modified-Since
      Last-Modified
      Connection
      Content-Range
      ETag
      Accept-Ranges
      Age
      Authentication-Info
      Proxy-Authenticate
      Retry-After
      Set-Cookie
      Vary
      WWW-Authenticate
      Content-Location
      Content-MD5
      Content-Range
      Meter
      Allow
      Error
      
    Contact Us

    Contact our sales team or business advisors to help your business.

    Technical Support

    Open a ticket if you're looking for further assistance. Our Ticket is 7x24 avaliable.

    7x24 Phone Support