Skip to main content

parse_headers

Function parse_headers 

Source
fn parse_headers(
    raw: &Value,
) -> Result<(Vec<(String, String)>, Vec<(String, String)>, Vec<String>), String>
Expand description

Parses the headers config key. Two accepted shapes:

  • structured: {add: ["Name: value", ...], set: {name: value}, remove: [name]}
  • deprecated flat map: {name: value} — treated as set (as APISIX does).