Hi guys, i need help on state matcher on header i ...
# help
g
Hi guys, i need help on state matcher on header i created something like this on header
Copy code
"headers": {
            "x-auth-token": {
              "contains": "{{state context='CssC123834' property='authTokenCss'}}"
            }
          },
but somehow it not works, how to use it on header?
in body request matcher it works like charm but using this format
Copy code
"customMatcher": {
            "name": "state-matcher",
            "parameters": {
              "hasContext": "CssC123834",
              "property": {
                "userIdCss": {
                  "equalTo": "{{jsonPath request.body '$.user_id'}}"
                }
              }
            }
          }
but how to make it works on header?
so the issue is just like this it not handle the handlebar correctly
t
@Dirk Bolte can you help here?
d
already checking 🙂
t
Thanks!
g
oh broo i made it
Copy code
"customMatcher": {
                    "name": "state-matcher",
                    "parameters": {
                        "hasContext": "CssC123834",
                        "property": {
                            "userIdCss": {
                                "equalTo": "{{jsonPath request.body '$.user_id'}}"
                            },
                            "authTokenCss": {
                                "equalTo": "{{request.headers.x-auth-token}}"
                            }
                        }
                    }
                },
👍 1
🎉 2
so sorry to take your time guys 🙇
d
thanks for posting it - will add it to the documentation
g
yapp thankyouu @Dirk Bolte 🙇