ซิงค์ข้อมูล Apigee Edge กับการสร้างรายได้

คุณกำลังดูเอกสารประกอบของ Apigee Edge
ไปที่ เอกสารประกอบของ Apigee X
info

บทนำ

ทีมการกำหนดค่า Apigee Edge จะเรียกใช้สคริปต์ที่ซิงค์กับระบบสร้างรายได้ขององค์กร รวมถึงนักพัฒนาแอปพลิเคชันและผลิตภัณฑ์ที่คุณสร้างขึ้นโดยใช้ Edge API Services ซึ่งเป็นส่วนหนึ่งของการตั้งค่าเริ่มต้นของระบบสร้างรายได้สำหรับองค์กร

หลังจากผ่านไประยะหนึ่ง (เช่น 2-3 เดือน) และเป็นระยะๆ หลังจากนั้น คุณควร ซิงค์ข้อมูลดังกล่าวกับระบบสร้างรายได้อีกครั้งเพื่อให้ข้อมูลเป็นปัจจุบัน โดยคุณสามารถซิงค์ข้อมูลต่อไปนี้ได้

การซิงค์องค์กรโดยใช้ API

หากต้องการซิงค์องค์กร ให้ส่งคำขอ GET ไปที่ /organizations/{org_name}/sync-organization เมื่อซิงค์องค์กร คุณยังซิงค์ผลิตภัณฑ์ นักพัฒนาแอป และแอปพลิเคชันทั้งหมดในองค์กรได้ด้วยโดย ระบุ childEntities=true เป็นพารามิเตอร์การค้นหาและค่า

ตัวอย่างเช่น คำขอต่อไปนี้จะซิงค์องค์กร รวมถึงผลิตภัณฑ์ นักพัฒนาแอป และแอปพลิเคชันทั้งหมดในองค์กร

$ curl -X GET \
"https://api.enterprise.apigee.com/v1/mint/organizations/{org_name}/sync-organization?childEntities=true" \
-u email:password

คำตอบควรมีลักษณะดังนี้ (แสดงเฉพาะบางส่วนของคำตอบ)

Synchronization 4G organization with mint, started at, Mon Sep 09 17:48:22 UTC 2013
Child entities sync is, true

Synchronizing {org_name}
Organization found in mint, merging...
Saving  {org_name}
Saved 
Synchronization 4G products with mint, started at, Mon Sep 09 17:45:26 UTC 2013
Found 4 products.

Synchronizing location
Product found in mint, merging...
Saving  location
Saved location

Synchronizing search
Product found in mint, merging...
Saving  search
Saved search

Synchronizing messaging
Product found in mint, merging...
Saving  messaging
Saved messaging

Synchronizing payment
Product found in mint, merging...
Saving  payment
Saved payment
Synchronization job finished at, Mon Sep 09 17:45:26 UTC 2013
Synchronization 4G products with mint, started at, Mon Sep 09 17:33:20 UTC 2013
Found 11 developers.

Synchronizing dev51@myorg.com
Developer found in mint, merging...
Saving  dev51@myorg.com
Saved dev51@myorg.com

...
Synchronization job finished at, Mon Sep 09 17:33:31 UTC 2013
Synchronization 4G products with mint, started at, Mon Sep 09 17:15:32 UTC 2013
Found 6 applications.

Synchronizing dev-four-test-app
Application found in mint, merging...
Saving  dev-four-test-app
Saved dev-four-test-app

...
Synchronization job finished at, Mon Sep 09 17:15:34 UTC 2013

การซิงค์ผลิตภัณฑ์โดยใช้ API

หากต้องการซิงค์ผลิตภัณฑ์ ให้ส่งคำขอ GET ไปที่ /organizations/{org_name}/sync-products เช่น

$ curl -X GET \
"https://api.enterprise.apigee.com/v1/mint/organizations/{org_name}/sync-products" \
-u email:password

การซิงค์นักพัฒนาแอปโดยใช้ API

หากต้องการซิงค์นักพัฒนาแอป ให้ส่งคำขอ GET ไปที่ /organizations/{org_name}/sync-developers. เช่น

$ curl -X GET \
"https://api.enterprise.apigee.com/v1/mint/organizations/{org_name}/sync-developers" \
-u email:password

การซิงค์แอปพลิเคชันโดยใช้ API

หากต้องการซิงค์แอปพลิเคชัน ให้ส่งคำขอ GET ไปที่ /organizations/{org_name}/sync-applications เช่น

$ curl -X GET \
"https://api.enterprise.apigee.com/v1/mint/organizations/{org_name}/sync-applications" \
-u email:password