So I have an AssignMessage policy which is supposed to set a FormParam called "From".
<?xml version="1.0" encoding="UTF-8" standalone="yes"?> <AssignMessage async="false" continueOnError="false" enabled="true" name="AM-Set-From"> <DisplayName>AM - Set From</DisplayName> <IgnoreUnresolvedVariables>true</IgnoreUnresolvedVariables> <AssignTo createNew="false" transport="http" type="request"/> <Set> <FormParams> <FormParam name="From"></FormParam> </FormParams> </Set> </AssignMessage>
The problem is that the request from the client already has 2 form parameters: "To" and "Body". But after this policy is executed in Edge, the only parameter is "From". So Edge is removing the given parameters and only keeping the one from the AssignMessage policy.
I tried to simulate this with your policy in my org... I don't see the issue (attached my proxy). It is a no-target proxy and will echo the message you send.
My sample request was -
$curl "http://MYORG-test.apigee.net/no-target-1" -d "To=destination&Body=hello" -X POST
and the proxy returns
To=destination&Body=hello&From=
@JosephGalley , Welcome to Apigee Community !
I think it's the content type header , Make sure you set the header below,
Content-Type: application/x-www-form-urlencoded
I can able to reproduce your issue,
With above header,
With form-data example, without above header,
Hope it helps. Keep us posted if any.
User | Count |
---|---|
5 | |
2 | |
2 | |
1 | |
1 |