This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<Step> | |
<!--the variable pathsuffix is evaluated to find the exact term "purchase"--> | |
<Condition>proxy.pathsuffix /~ "/purchase"</Condition> | |
<FaultRules/> | |
<Name>publishPurchaseDetails</Name> | |
</Step> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0"?> | |
<ProxyEndpoint name="proxy"> | |
<Flows> | |
<Flow> | |
<Request/> | |
<!==you can place policies in either the Request or Response flow. Here the JSON to XML policy is in the Response flow==> | |
<Response> | |
<!==each policy is defined as a Step. The actual policy is defined in another xml file stored in the stepdefinitions folder.==> | |
<Step> | |
<FaultRules/> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<JSONToXML name="myPolicy"> | |
<Source>request</Source> | |
<OutputVariable>response</OutputVariable> | |
<Options> | |
<InvalidCharsReplacement>_</InvalidCharsReplacement> | |
<TextNodeName>#text</TextNodeName> | |
<NullValue>I_AM_NULL</NullValue> | |
<AttributeBlockName>#attrs</AttributeBlockName> | |
<AttributePrefix>@</AttributePrefix> | |
<NamespaceBlockName>#namespaces</NamespaceBlockName> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<ResponseCache name="ResponseCache"> | |
<CacheResource>mycache</CacheResource> | |
<Scope>Global</Scope> | |
<CacheKey> | |
<Prefix>Apigee</Prefix> | |
<KeyFragment ref="request.path" /> | |
</CacheKey> | |
<SkipCacheLookup>{condition}</SkipCacheLookup> | |
<SkipCachePopulation>{condition}</SkipCachePopulation> | |
<ExpirySettings> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<XMLToJSON name="mypolicy"> | |
<Source>request</Source> | |
<OutputVariable>response</OutputVariable> | |
<Options> | |
<RecognizeNumber>true</RecognizeNumber> | |
<RecognizeBoolean>true</RecognizeBoolean> | |
<RecognizeNull>true</RecognizeNull> | |
<NullValue>NULL</NullValue> | |
<NamespaceSeparator>%</NamespaceSeparator> | |
<NamespaceBlockName>#namespaces</NamespaceBlockName> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<InvalidateCache name="InvalidateMyCache"> | |
<CacheResource>mycache</CacheResource> | |
<Scope>Global/Application/Proxy/Target</Scope> | |
<CacheContext> | |
<APIProxyName>myapp</APIProxyName> | |
<ProxyName>myproxy</ProxyName> | |
<TargetName>mytarget</TargetName> | |
<CacheContext> | |
<CacheKey> | |
<Prefix>cache-key-prefix</Prefix> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<LookupCache name="LookupMyCache"> | |
<CacheResource>mycache</CacheResource> | |
<AssignTo>{flow variable}</AssignTo> | |
<Scope>Global/Application/Proxy/Target/Exclusive</Scope> | |
<CacheKey> | |
<Prefix>UserToken</Prefix> | |
<KeyFragment ref="request.header.id1" /> | |
<KeyFragment ref="request.header.id2" /> | |
</CacheKey> | |
</LookupCache> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<XSL name="xslPolicy"> | |
<Source>...</Source> | |
<OutputVariable>...</OutputVariable> | |
<ResourceURL>xsl://sample</ResourceURL> | |
<Parameters ignoreUnresolvedVariables="true/[false]"> | |
<Parameter name="p1" value="value1"/> | |
<Parameter name="p2" ref="request.header.greeting"/> | |
</Parameters> | |
</XSL> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<Cache name="mycache"> | |
<Description>Cache description</Description> | |
<MaxElementsInMemory>100</MaxElementsInMemory> | |
<MaxElementsOnDisk>1000</MaxElementsOnDisk> | |
<OverflowToDisk>true</OverflowToDisk> | |
<Persistent>false</Persistent> | |
<ExpirySettings> | |
<TimeoutInSec>300</TimeoutInSec> | |
</ExpirySettings> | |
<Compression> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<PopulateCache name="PopulateMyCache"> | |
<CacheResource>mycache</CacheResource> | |
<Source>{flow variable}</Source> | |
<Scope>Global/Application/Proxy/Target/Exclusive</Scope> | |
<CacheKey> | |
<Prefix>cache-key-prefix</Prefix> | |
<KeyFragment ref="request.header.id1" /> | |
<KeyFragment ref="request.header.id2" /> | |
</CacheKey> | |
<ExpirySettings> |
OlderNewer