Updated on 2025-08-19 GMT+08:00

API Connect (APIC) Trigger

This section describes how to create an APIC trigger on the FunctionGraph console to invoke a function using an API.

For details about the APIC event source, see Supported Event Sources.

Notes and Constraints

APIC triggers are available only in the AP-Singapore region. You can check whether the trigger type is supported on the console.

Prerequisites

Creating an APIC Trigger

  1. Log in to the FunctionGraph console. In the navigation pane, choose Functions > Function List.
  2. Click the function to be configured to go to the function details page.
  3. Choose Configuration > Triggers and click Create Trigger.

    Figure 1 Creating a trigger

  4. Configure the following parameters.

    Table 1 APIC trigger parameters

    Parameter

    Description

    Example Value

    Trigger Type

    Mandatory.

    Select API Connect (APIC).

    API Connect (APIC)

    API Instance

    Mandatory.

    Select an APIC instance. If no instance is available, click Create API Instance.

    APIC_fg

    API Name

    Mandatory.

    APIG trigger name. The name can contain 3 to 64 characters and must start with a letter. Only letters, digits, and underscores (_) are allowed.

    API_apic

    API Group

    Mandatory.

    Select an API group. An API group is a collection of APIs. You can manage APIs by API group.

    If no group is available, click Create API Group.

    APIConnect_test

    Environment

    Mandatory.

    The environment where the API is published. An API can be called in different environments, such as production, test, and development environments only when the parameter is set to RELEASE.

    If no environment is available, click Create Environment.

    RELEASE

    Security Authentication

    Mandatory.

    API authentication modes are as follows:

    • App: AppKey and AppSecret authentication. This mode is of high security and is recommended. For details, see App Authentication.
    • IAM: IAM authentication. This mode grants access permissions to IAM users only and is of medium security. For details, see IAM Authentication
    • None: No authentication. This mode grants access permissions to all users.

    None

    Protocol

    Mandatory.

    There are two types of API request protocols:

    • HTTP: Data is not encrypted during transmission.
    • HTTPS: Data is encrypted during transmission.

    HTTPS

    Timeout (ms)

    Mandatory.

    API backend timeout in milliseconds. Range: 1–60,000.

    5000

  5. Click OK.

    After the trigger is created, an API named API_apic is generated on the APIG console. You can click the API name in the trigger list to go to the APIG console.

Invoking the Function

  1. Log in to ROMA Connect, find the selected instance (for example, Ac6-instance-NoDelete), and view the public IP address.
  2. Enter the public IP address in the address box of the browser.
  3. After the function is executed, a result is returned.

Viewing the Execution Result

  1. Return to the FunctionGraph console. In the navigation pane, choose Functions > Function List.
  2. Click the name of the desired function.
  3. On the displayed function details page, click the Logs tab to query the function running logs. For details, see Configuring and Viewing Function Invocation Logs
  4. Click View Context in the same row as a log to view log details.

Helpful Links

Manage function triggers through APIs. For details, see Function Trigger APIs.