Apigeex consolidation of two nonProd orgs

Hi  – We are trying to consolidate our ApigeeX qa & Perf orgs into one single org but just create two different environments. Is there a way that we could still support the old apikeys that we created in different qa org & migrate them to perf org with new qa environment? If we cannot migrate them , Is there an option to at least have different apikeys by environments even though the apps, Developers & products are same? Also do we have the list of steps or tasks to take care when we do such migration of  environments from one org to other?

0 2 138
2 REPLIES 2

Hi,

You can export and import Developers, Apps (including keys), API Products and Proxies between Apigee X orgs using the apigeecli tool: https://github.com/srinandan/apigeecli.

For example, to export from an existing organization:

mkdir -p export_dir/apis
cd export_dir
apigeecli -t $TOKEN -o apigeex-source apis export -f apis
apigeecli -t $TOKEN -o apigeex-source products export
apigeecli -t $TOKEN -o apigeex-source developers export
apigeecli -t $TOKEN -o apigeex-source apps export

To import into new organization:

apigeecli -t $TOKEN -o apigeex-destination apis import -f apis
apigeecli -t $TOKEN -o apigeex-destination products import -f products.json
apigeecli -t $TOKEN -o apigeex-destination developers import -f developers.json
apigeecli -t $TOKEN -o apigeex-destination apps import -f apps.json -d developers.json

There is one minor caveat, that is the exported API proxy will have the revision suffix added (e.g. myproxy-v1_7.zip) so you'll want to rename that zip file before importing so that the API Product works properly.

Former Community Member
Not applicable

With apigeecli v1.104, the revision suffix is no longer added.

Also, all components can be exported via a single command 

apigeecli orgs export -o ${SOURCE_ORG} -f export_dir -t ${token}

and similarly for import.