Nachdem Sie Google Cloud und die Apigee-Benutzeroberfläche konfiguriert und die Laufzeit installiert und konfiguriert haben, können Sie sehen, wie sie zusammenwirken.
1. Einen neuen API-Proxy mithilfe der Apigee-Benutzeroberfläche erstellen
In diesem Abschnitt wird beschrieben, wie Sie einen neuen API-Proxy in der Benutzeroberfläche mithilfe des API-Proxy-Assistenten erstellen.
Apigee in der Cloud Console
So erstellen Sie einen neuen API-Proxy mit Apigee in der Cloud Console:
Wählen Sie Ihre Organisation links oben im Drop-down-Menü aus.
Wählen Sie in der Hauptansicht Proxy-Entwicklung > API-Proxys aus.
Klicken Sie auf Erstellen. Der API-Proxy-Assistent wird gestartet.
Wählen Sie Reverse-Proxy (wird am häufigsten verwendet) aus.
Die Ansicht Proxy-Details wird angezeigt.
Konfigurieren Sie den Proxy mit den folgenden Einstellungen:
Proxyname: Geben Sie myproxy ein. In den verbleibenden Schritten in diesem Abschnitt wird davon ausgegangen, dass dies Ihre Proxy-ID ist.
Basispfad: Wird automatisch auf / festgelegt, gefolgt vom Proxynamen, der in diesem Beispiel /myproxy lautet. Der Basispfad ist Teil der URL, die zum Senden von Anfragen an Ihre API verwendet wird. Apigee verwendet die URL, um eingehende Anfragen zuzuordnen und an den richtigen API-Proxy weiterzuleiten.
(Optional) Beschreibung: Geben Sie eine Beschreibung für den neuen API-Proxy ein, z. B. "Apigee Hybrid mit einem einfachen Proxy testen".
Ziel (vorhandene API): Geben Sie "https://mocktarget.apigee.net" ein. Dies definiert die Ziel-URL, die Apigee für eine Anfrage an den API-Proxy aufruft. Der simulierte Zieldienst wird bei Apigee gehostet und gibt einfache Daten zurück. Ein API-Schlüssel oder ein Zugriffstoken sind nicht erforderlich.
Die Details Ihres API-Proxys sollten so aussehen:
Klicken Sie auf Weiter.
Unter Bereitstellen (optional) haben Sie die Möglichkeit, im Feld Bereitstellungsumgebungen eine oder mehrere Umgebungen auszuwählen, in denen Sie Ihren Proxy bereitstellen können.
Wenn Sie den Proxy zu diesem Zeitpunkt nicht bereitstellen möchten, lassen Sie das Feld Bereitstellungsumgebungen leer. Sie können den Proxy später jederzeit bereitstellen.
Klicken Sie auf Erstellen.
Apigee generiert den Proxy (manchmal auch als Proxy-Bundle bezeichnet).
Apigee zeigt die Ansicht Proxy-Zusammenfassung an.
Wenn Sie den Proxy bereitstellen, wird im Abschnitt Bereitstellungen die Nummer der Überarbeitung angezeigt, die 1 ist, wenn Sie das erste Mal bereitstellen. In der Spalte Status werden mit einer grünen Statusanzeige die Umgebungen angezeigt, in denen der Proxy bereitgestellt wird.
Darunter sehen Sie im Abschnitt Überarbeitungen alle Änderungen, die an diesem Proxy vorgenommen wurden. Wenn Sie auf eines der ANSICHTS-Elemente in der Spalte Endpunktzusammenfassung klicken, wird der Abschnitt Endpunkt angezeigt:
Proxy-Endpunkte: Der Basispfad, den Sie für den Proxy festgelegt haben. In diesem Beispiel ist das /myproxy.
Zielendpunkte: Der Basispfad, den Sie für das Ziel festlegen. In diesem Beispiel ist das https://mocktarget.apigee.net.
Klassisches Apigee
So erstellen Sie einen neuen API-Proxy mit dem klassischen Apigee:
Wählen Sie Ihre Organisation links oben im Drop-down-Menü aus.
Wählen Sie in der Hauptansicht Develop > API Proxies aus.
Klicken Sie auf Neu erstellen. Der API-Proxy-Assistent wird gestartet.
Wählen Sie Reverse-Proxy (wird am häufigsten verwendet) aus.
Die Ansicht Proxy-Details wird angezeigt.
Konfigurieren Sie den Proxy mit den folgenden Einstellungen:
Proxy Name: Geben Sie "myproxy" ein. In den verbleibenden Schritten in diesem Abschnitt wird davon ausgegangen, dass dies Ihre Proxy-ID ist.
Proxy-Basispfad: Wird automatisch auf "/myproxy" festgelegt. Der Proxy-Basispfad ist Teil der URL, die zum Senden von Anfragen an Ihre API verwendet wird. Apigee verwendet die URL, um eingehende Anfragen zuzuordnen und an den richtigen API-Proxy weiterzuleiten.
(Optional) Beschreibung: Geben Sie eine Beschreibung für den neuen API-Proxy ein, z. B. "Apigee Hybrid mit einem einfachen Proxy testen".
Ziel (vorhandene API): Geben Sie "https://mocktarget.apigee.net" ein. Dies definiert die Ziel-URL, die Apigee für eine Anfrage an den API-Proxy aufruft. Der simulierte Zieldienst wird bei Apigee gehostet und gibt einfache Daten zurück. Ein API-Schlüssel oder ein Zugriffstoken sind nicht erforderlich.
Die Details Ihres API-Proxys sollten so aussehen:
Klicken Sie auf Weiter.
Wählen Sie auf dem Bildschirm Allgemeine Richtlinien die Sicherheitsoption Passthrough (keine Autorisierung) aus.
Klicken Sie auf Weiter.
Wählen Sie auf dem Bildschirm Zusammenfassung eine Umgebung aus, in der Sie den Proxy bereitstellen möchten, und klicken Sie auf Erstellen und bereitstellen.
Hybrid generiert den Proxy (manchmal auch als Proxy-Bundle bezeichnet) und stellt ihn in der ausgewählten Umgebung bereit.
Klicken Sie auf Zur Proxyliste.
Apigee zeigt die Ansicht Proxys an, in der eine Liste der API-Proxys angezeigt wird. Ihr neuer Proxy sollte mit einer grünen Statusanzeige angezeigt werden, was bedeutet, dass er bereitgestellt wurde.
2. Den API-Proxy aufrufen
Wenn die Benutzeroberfläche angibt, dass Ihr Proxy bereitgestellt ist, können Sie versuchen, diesen mit cURL oder dem REST-Client Ihrer Wahl aufzurufen:
Beispiel:
Suchen Sie mit dem folgenden Befehl die externe IP-Adresse und den Port des Apigee Ingress-Gateways:
kubectl get svc -n APIGEE_NAMESPACE -l app=apigee-ingressgateway
Die Ausgabe sollte in etwa so aussehen:
NAME TYPE CLUSTER-IP EXTERNAL-IP PORT(S) AGE
apigee-ingressgateway-prod-hybrid-37a39bd LoadBalancer 192.0.2.123 233.252.0.123 15021:32049/TCP,80:31624/TCP,443:30723/TCP 16h
Exportieren Sie Ihre externe IP-Adresse und Ihren Port in Variablen:
[[["Leicht verständlich","easyToUnderstand","thumb-up"],["Mein Problem wurde gelöst","solvedMyProblem","thumb-up"],["Sonstiges","otherUp","thumb-up"]],[["Schwer verständlich","hardToUnderstand","thumb-down"],["Informationen oder Beispielcode falsch","incorrectInformationOrSampleCode","thumb-down"],["Benötigte Informationen/Beispiele nicht gefunden","missingTheInformationSamplesINeed","thumb-down"],["Problem mit der Übersetzung","translationIssue","thumb-down"],["Sonstiges","otherDown","thumb-down"]],["Zuletzt aktualisiert: 2025-08-21 (UTC)."],[[["\u003cp\u003eThis content guides you through creating a new API proxy in Apigee using either the Apigee in Cloud console or the classic Apigee UI, with both methods using a step by step approach.\u003c/p\u003e\n"],["\u003cp\u003eWhen setting up the API proxy, you will need to choose a reverse proxy setup, assign a proxy name (like 'myproxy'), a base path, and a target API, such as "https://mocktarget.apigee.net".\u003c/p\u003e\n"],["\u003cp\u003eAfter creating the proxy, you can optionally deploy it to one or more environments and will then see the deployment status and revision number in the UI.\u003c/p\u003e\n"],["\u003cp\u003eOnce the proxy is deployed, you can call it using cURL or a REST client by setting environment variables for the domain, external IP address, and port, followed by executing a cURL command.\u003c/p\u003e\n"],["\u003cp\u003eA successful call to the created API proxy will result in an HTTP 200 response and outputting "Hello, Guest!".\u003c/p\u003e\n"]]],[],null,["# Step 2: Deploy an API proxy\n\n| You are currently viewing version 1.14 of the Apigee hybrid documentation. For more information, see [Supported versions](/apigee/docs/hybrid/supported-platforms#supported-versions).\n\nNow that you've configured and the Apigee UI, and installed and configured the\nruntime, you're ready to see how it all works together.\n\n1. Create a new API proxy using the Apigee UI\n---------------------------------------------\n\nThis section describes how to create a new API proxy in the UI using the API Proxy Wizard.\n**Note:** There is a new version of the Apigee UI, which is integrated with the Google Cloud console. The new UI is called *Apigee in Cloud console*. The instructions in the first two tabs below explain how to use either Apigee in Cloud console or classic Apigee UI. \n\n### Apigee in Cloud console\n\nTo create a new API proxy using Apigee in Cloud console:\n\n1. Open [Apigee UI in Cloud console](https://console.cloud.google.com/apigee) in a browser.\n2. Select your organization from the dropdown menu in the upper left corner.\n3. Select **Proxy development \\\u003e API proxies** in the main view.\n4. Click **Create**.The API Proxy Wizard starts.\n5. Select **Reverse proxy** (most common).\n\n The **Proxy details** view is displayed.\n6. Configure your proxy with the following settings:\n - **Proxy name:** Enter **myproxy**. The remaining steps in this section assume that this is your proxy's ID.\n - **Base path:** Automatically set to **/** followed by the proxy name, which in this example is **/myproxy** . The **Base\n path** is part of the URL used to make requests to your API. Apigee uses the URL to match and route incoming requests to the proper API proxy.\n - (Optional)**Description:** Enter a description for your new API proxy, such as \"Testing Apigee hybrid with a simple proxy\".\n - **Target (Existing API):** Enter \"https://mocktarget.apigee.net\". This defines the target URL that Apigee invokes on a request to the API proxy. The mocktarget service is hosted at Apigee and returns simple data. It requires no API key or access token.\n\n Your API proxy's details should look like the following:\n\n7. Click **Next**.\n8. Under **Deploy (optional)** , you have the option to select one or more environments in which to deploy your proxy, in the **Deployment environments** field. If you prefer not to deploy the proxy at this point, leave the **Deployment environments** field empty. You can always deploy the proxy later.\n9. Click **Create** . Apigee generates the proxy (sometimes referred to as *the proxy bundle* ).\n\n \u003cbr /\u003e\n\nApigee displays the **Proxy summary** view.\nIf you chose to deploy the proxy, the **Deployments** section displays the **Revision**\nnumber, which is 1 when you first deploy. The **Status** column displays the\nenvironments in which the proxy is deployed with a green status indicator.\n\nBelow that, the **Revisions** section shows all revisions made to this proxy. By\nclicking on one of the **VIEW** items in the **Endpoint summary** column, the\n**Endpoint** section displays:\n\n- **Proxy endpoints** : The basepath you set for the proxy, which is this example is `/myproxy`.\n- **Target endpoints** : The basepath you set for the target, which in this example is `https://mocktarget.apigee.net`.\n\n### Classic Apigee\n\nTo create a new API proxy using Classic Apigee:\n\n1. Open [Apigee UI](https://apigee.google.com) in a browser.\n2. Select your organization from the dropdown menu in the upper left corner.\n3. Select **Develop \\\u003e API Proxies** in the main view.\n4. Click **Create New**.The API Proxy Wizard starts.\n5. Select **Reverse proxy** (most common).\n\n The **Proxy details** view is displayed.\n6. Configure your proxy with the following settings:\n - **Proxy Name:** Enter \"myproxy\". The remaining steps in this section assume that this is your proxy's ID.\n - **Proxy Base Path:** Automatically set to \"/myproxy\". The **Proxy Base\n Path** is part of the URL used to make requests to your API. Apigee uses the URL to match and route incoming requests to the proper API proxy.\n - (Optional)**Description:** Enter a description for your new API proxy, such as \"Testing Apigee hybrid with a simple proxy\".\n - **Target (Existing API):** Enter \"https://mocktarget.apigee.net\". This defines the target URL that Apigee invokes on a request to the API proxy. The mocktarget service is hosted at Apigee and returns simple data. It requires no API key or access token.\n\n Your API proxy's details should look like the following:\n\n7. Click **Next**.\n8. On the **Common policies** screen, select **Pass through (no authorization)** as the security option.\n9. Click **Next**.\n10. On the **Summary** screen, select an environment to deploy your proxy to and click **Create and Deploy** .\n\n Hybrid generates the proxy (sometimes referred to as *the proxy bundle*) and deploys it to the environment you selected.\n11. Click **Go to proxy list** .\n\n Apigee displays the **Proxies** view, which displays a list of API proxies. Your\n new proxy should display with a green status indicator, meaning that it has been deployed.\n\n2. Call the API proxy\n---------------------\n\nWhen the UI indicates your proxy is deployed, you can try calling it using cURL or the REST\nclient of your choice.\nFor example:\n\n1. Make sure your `DOMAIN` environment variable is set to the domain name you used for the hostname for your environment group in [Project and org\n setup - Step 3: Create an environment group](/apigee/docs/hybrid/v1.14/precog-add-environment). \n\n ```\n echo $DOMAIN\n ```\n2. Find the external IP address and port of the Apigee ingress gateway with the following command:\n\n ```\n kubectl get svc -n APIGEE_NAMESPACE -l app=apigee-ingressgateway\n ```\n\n\n Your output should look something like: \n\n ```\n NAME TYPE CLUSTER-IP EXTERNAL-IP PORT(S) AGE\n apigee-ingressgateway-prod-hybrid-37a39bd LoadBalancer 192.0.2.123 233.252.0.123 15021:32049/TCP,80:31624/TCP,443:30723/TCP 16h\n ```\n3. Export your external IP and port to variables: \n\n export INGRESS_IP_ADDRESS=EXTERNAL_IP_ADDRESS\n export INGRESS_PORT=\u003cvar translate=\"no\"\u003ePORT_NUMBER\u003c/var\u003e\n\n4. Call the API proxy: \n\n ```\n curl -H Host:$DOMAIN --resolve \\\n $DOMAIN:$INGRESS_PORT:$INGRESS_IP_ADDRESS \\\n https://$DOMAIN:$INGRESS_PORT/myproxy -k -v\n ```\n\n\n For example: \n\n ```\n curl -v -H Host:example.com --resolve example.com:443:233.252.0.123 https://example.com:443/myproxy -k -v\n ```\n5. A successful call to the proxy returns an HTTP 200 response code and the following output.\u003cbr /\u003e\n\n ```\n Hello, Guest!\n ```\n\n\nTo learn more about building and deploying API proxies, see [Build your first proxy overview](/apigee/docs/api-platform/get-started/get-started).\n| **Congratulations!**\n|\n| You've successfully installed Apigee hybrid. To learn more about building and deploying\n| API proxies, see [Introduction to API proxy building](/apigee/docs/api-platform/fundamentals/build-simple-api-proxy).\n\n*[Google Cloud]: Google Cloud"]]