Armox
    Armox Academy 📚
    API-ReferenzEinführung in die API-ReferenzApps-Endpunkt

    Apps-Endpunkt

    Die Apps-API ermöglicht Ihnen, wiederverwendbare Workflow-Apps auszuführen, die in Armox Canvas erstellt wurden.

    Basispfade:

    • GET https://armox.ai/api/v1/apps
    • POST https://armox.ai/api/v1/apps/run

    GET /api/v1/apps

    Listet aktive Vorlagen-Apps und private Apps auf, auf die Ihr Benutzer Zugriff hat.

    Anfrage

    curl -X GET "https://armox.ai/api/v1/apps" \
      -H "Authorization: Bearer sk_live_your_key_here"
    

    Antwort

    Prompt Template
    {
      "object": "list",
      "data": [
        {
          "id": "app_123",
          "name": "Product Hero Creator",
          "description": "Generate hero product images from a short brief",
          "icon": "sparkles",
          "thumbnail_url": "https://...",
          "is_template": true,
          "brain_id": "brain_abc",
          "tags": ["marketing", "image"],
          "inputs": [
            {
              "id": "input_prompt",
              "label": "Prompt",
              "required": true
            }
          ]
        }
      ]
    }

    POST /api/v1/apps/run

    Führt einen App-Workflow aus und gibt einen asynchronen Job zurück.

    Request Body

    {
      "app_id": "app_123",
      "inputs": {
        "input_prompt": "Luxury perfume bottle, dramatic studio lighting, black background"
      },
      "webhook_url": "https://your-app.com/webhooks/armox"
    }
    

    Felder:

    • app_id (erforderlich): App-Bezeichner aus GET /api/v1/apps
    • inputs (optionales Objekt): Schlüssel-Wert-Eingabezuordnung nach Eingabe-ID
    • webhook_url (optional): Callback-URL

    Validierungsregeln

    • Die App muss existieren und aktiv sein
    • Der Benutzer muss Zugriff auf Nicht-Vorlagen-App-Ressourcen haben
    • Alle erforderlichen App-Eingaben müssen bereitgestellt werden

    Wenn erforderliche Eingaben fehlen, lautet die Antwort 400 mit:

    { "error": "Missing required inputs: Prompt" }
    

    Antwort (202)

    POST /api/v1/apps/run ist asynchron.

    {
      "id": "job_456",
      "object": "job",
      "status": "processing",
      "run_type": "app",
      "app_id": "app_123",
      "app_name": "Product Hero Creator",
      "credits_charged": 340,
      "created_at": "2026-03-26T12:20:00.000Z"
    }
    

    End-to-End-Beispiel

    1. Apps auflisten mit GET /api/v1/apps
    2. Eine App auswählen und ihre inputs prüfen
    3. Ausführen mit POST /api/v1/apps/run
    4. GET /api/v1/jobs/:id pollen bis zur Fertigstellung
    5. Ausgaben aus output_data.node_outputs lesen

    cURL

    curl -X POST "https://armox.ai/api/v1/apps/run" \
      -H "Authorization: Bearer sk_live_your_key_here" \
      -H "Content-Type: application/json" \
      -d '{
        "app_id": "app_123",
        "inputs": {
          "input_prompt": "Luxury perfume bottle, dramatic studio lighting, black background"
        }
      }'
    

    JavaScript

    const runResponse = await fetch("https://armox.ai/api/v1/apps/run", {
      method: "POST",
      headers: {
        Authorization: "Bearer sk_live_your_key_here",
        "Content-Type": "application/json",
      },
      body: JSON.stringify({
        app_id: "app_123",
        inputs: { input_prompt: "Luxury perfume bottle, dramatic studio lighting, black background" },
      }),
    });
    
    const job = await runResponse.json();
    console.log(job);
    

    Kosten und Credits

    Apps können intern mehrere Nodes ausführen. Credits werden abgezogen, sobald die App-Ausführung angenommen wird.

    Wenn der endgültige Job fehlschlägt, werden Credits gemäß der Job-Verarbeitungslogik erstattet.

    Verwandte Seiten

    Bereit, deinen kreativen Workflow zu transformieren?

    Keine Kreditkarte erforderlich2000 kostenlose Credits