[[["容易理解","easyToUnderstand","thumb-up"],["確實解決了我的問題","solvedMyProblem","thumb-up"],["其他","otherUp","thumb-up"]],[["難以理解","hardToUnderstand","thumb-down"],["資訊或程式碼範例有誤","incorrectInformationOrSampleCode","thumb-down"],["缺少我需要的資訊/範例","missingTheInformationSamplesINeed","thumb-down"],["翻譯問題","translationIssue","thumb-down"],["其他","otherDown","thumb-down"]],["上次更新時間:2025-09-05 (世界標準時間)。"],[[["\u003cp\u003eThis page details shared flows, which are reusable functionalities within Apigee and Apigee hybrid, similar in concept to API proxies.\u003c/p\u003e\n"],["\u003cp\u003eA shared flow bundle includes base configuration, policies, resources (like scripts and JAR files), and the shared flows themselves, all structured in a specific directory format.\u003c/p\u003e\n"],["\u003cp\u003eThe base configuration of a shared flow bundle, found in a file named after the bundle, defines the bundle's contents, tracks revision history, and contains elements like \u003ccode\u003eConfigurationVersion\u003c/code\u003e, \u003ccode\u003eDescription\u003c/code\u003e, and lists of \u003ccode\u003ePolicies\u003c/code\u003e and \u003ccode\u003eResources\u003c/code\u003e.\u003c/p\u003e\n"],["\u003cp\u003eThe \u003ccode\u003eSharedFlow\u003c/code\u003e configuration determines the execution sequence of flow elements, with each \u003ccode\u003e<Step>\u003c/code\u003e specifying a policy to be called, such as Spike Arrest, using its corresponding \u003ccode\u003e<Name>\u003c/code\u003e.\u003c/p\u003e\n"],["\u003cp\u003eShared flow bundles contain a single shared flow and must have a unique name within an organization.\u003c/p\u003e\n"]]],[],null,["# Shared flow bundle configuration reference\n\n*This page\napplies to **Apigee** and **Apigee hybrid**.*\n\n\n*View [Apigee Edge](https://docs.apigee.com/api-platform/get-started/what-apigee-edge) documentation.*\n\nA shared flow is reusable functionality similar to an API proxy. For more information,\nsee [Creating reusable shared flows](/apigee/docs/api-platform/fundamentals/shared-flows).\n\nShared flow bundle directory structure\n--------------------------------------\n\nThe shared flow bundle directory structure, shown below, is similar to the\n[API proxy configuration directory structure](/apigee/docs/api-platform/reference/api-proxy-configuration-reference#apiproxystructure).\n\nA shared flow bundle configuration consists of the following contents:\n\nBase configuration\n------------------\n\nThe base configuration file is located at the bundle's root directory. Its name is the name of\nthe bundle. \n\n```world-of-warcraft-toc\n/sharedflowbundle/traffic-management-shared.xml\n```\n\nThe base configuration defines the contents of the shared flow bundle, along with information\nfor tracking the bundle's revision history. \n\n```transact-sql\n\u003cSharedFlowBundle revision=\"2\" name=\"traffic-management-shared\"\u003e\n \u003cConfigurationVersion majorVersion=\"4\" minorVersion=\"0\"/\u003e\n \u003cCreatedAt\u003e1478637529218\u003c/CreatedAt\u003e\n \u003cCreatedBy\u003egladys@example.com\u003c/CreatedBy\u003e\n \u003cDescription\u003eShared flow to moderate API traffic\u003c/Description\u003e\n \u003cDisplayName\u003etraffic-management-shared\u003c/DisplayName\u003e\n \u003cLastModifiedAt\u003e1481573374023\u003c/LastModifiedAt\u003e\n \u003cLastModifiedBy\u003egladys@example.com\u003c/LastModifiedBy\u003e\n \u003cPolicies\u003e\n \u003cPolicy\u003eAuth-Flow-Callout\u003c/Policy\u003e\n \u003cPolicy\u003eExtract-Token\u003c/Policy\u003e\n \u003cPolicy\u003eSpike-Arrest\u003c/Policy\u003e\n \u003c/Policies\u003e\n \u003cResources\u003e\n \u003cResource\u003ejsc://extract-token.js\u003c/Resource\u003e\n \u003c/Resources\u003e\n \u003cSharedFlows\u003e\n \u003cSharedFlow\u003edefault\u003c/SharedFlow\u003e\n \u003c/SharedFlows\u003e\n\u003c/SharedFlowBundle\u003e\n```\n\n### Base configuration attributes\n\n### Base configuration elements\n\nPolicies\n--------\n\n```text\n/sharedflowbundle/policies\n```\n\nAs in an API proxy, in a shared flow bundle the `/policies` directory contains\nconfiguration XML for all policies available to be attached to the shared flow in the bundle.\nPolicies share a subset of elements, though this subset is augmented with elements that are\nspecific to the policy. For more about how to configure a policy,\n[Policy reference overview](/apigee/docs/api-platform/reference/policies/reference-overview-policy).\n\nResources\n---------\n\n```text\n/sharedflowbundle/resources\n```\n\nResources are scripts, code, and XSL transformations that can be attached to shared flows\nusing policies. These appear in the Scripts section of the shared flow editor in the management\nUI.\n\nSee [Managing resources](/apigee/docs/api-platform/develop/resource-files) for the supported\nresource types.\n\nShared flows\n------------\n\n```world-of-warcraft-toc\n/sharedflowbundle/sharedflows/default.xml\n```\n\nThe SharedFlow configuration defines the sequence in which flow elements should be executed.\nThe `\u003cSharedFlow\u003e` element's `\u003cStep\u003e` child elements each specify a part of the sequence,\nsuch as a call to a policy.\n\nThe following SharedFlow configuration specifies three policies to be executed in a\ntop-to-bottom sequence (left to right in the management console), with the [SpikeArrest policy](/apigee/docs/api-platform/reference/policies/spike-arrest-policy) first and a\n[FlowCallout policy](/apigee/docs/api-platform/reference/policies/flow-callout-policy)\nlast. \n\n```text\n\u003cSharedFlow name=\"default\"\u003e\n \u003cStep\u003e\n \u003cName\u003eSpike-Arrest\u003c/Name\u003e\n \u003c/Step\u003e\n \u003cStep\u003e\n \u003cName\u003eExtract-Token\u003c/Name\u003e\n \u003c/Step\u003e\n \u003cStep\u003e\n \u003cName\u003eAuth-Flow-Callout\u003c/Name\u003e\n \u003c/Step\u003e\n\u003c/SharedFlow\u003e\n```\n\n### Shared flow configuration attributes\n\n### Shared flow configuration elements"]]