Esta página ainda não está disponível no idioma selecionado. Estamos trabalhando para adicionar mais opções de idiomas. Agradecemos sua compreensão.

Compute
Elastic Cloud Server
Huawei Cloud Flexus
Bare Metal Server
Auto Scaling
Image Management Service
Dedicated Host
FunctionGraph
Cloud Phone Host
Huawei Cloud EulerOS
Networking
Virtual Private Cloud
Elastic IP
Elastic Load Balance
NAT Gateway
Direct Connect
Virtual Private Network
VPC Endpoint
Cloud Connect
Enterprise Router
Enterprise Switch
Global Accelerator
Management & Governance
Cloud Eye
Identity and Access Management
Cloud Trace Service
Resource Formation Service
Tag Management Service
Log Tank Service
Config
OneAccess
Resource Access Manager
Simple Message Notification
Application Performance Management
Application Operations Management
Organizations
Optimization Advisor
IAM Identity Center
Cloud Operations Center
Resource Governance Center
Migration
Server Migration Service
Object Storage Migration Service
Cloud Data Migration
Migration Center
Cloud Ecosystem
KooGallery
Partner Center
User Support
My Account
Billing Center
Cost Center
Resource Center
Enterprise Management
Service Tickets
HUAWEI CLOUD (International) FAQs
ICP Filing
Support Plans
My Credentials
Customer Operation Capabilities
Partner Support Plans
Professional Services
Analytics
MapReduce Service
Data Lake Insight
CloudTable Service
Cloud Search Service
Data Lake Visualization
Data Ingestion Service
GaussDB(DWS)
DataArts Studio
Data Lake Factory
DataArts Lake Formation
IoT
IoT Device Access
Others
Product Pricing Details
System Permissions
Console Quick Start
Common FAQs
Instructions for Associating with a HUAWEI CLOUD Partner
Message Center
Security & Compliance
Security Technologies and Applications
Web Application Firewall
Host Security Service
Cloud Firewall
SecMaster
Anti-DDoS Service
Data Encryption Workshop
Database Security Service
Cloud Bastion Host
Data Security Center
Cloud Certificate Manager
Edge Security
Blockchain
Blockchain Service
Web3 Node Engine Service
Media Services
Media Processing Center
Video On Demand
Live
SparkRTC
MetaStudio
Storage
Object Storage Service
Elastic Volume Service
Cloud Backup and Recovery
Storage Disaster Recovery Service
Scalable File Service Turbo
Scalable File Service
Volume Backup Service
Cloud Server Backup Service
Data Express Service
Dedicated Distributed Storage Service
Containers
Cloud Container Engine
SoftWare Repository for Container
Application Service Mesh
Ubiquitous Cloud Native Service
Cloud Container Instance
Databases
Relational Database Service
Document Database Service
Data Admin Service
Data Replication Service
GeminiDB
GaussDB
Distributed Database Middleware
Database and Application Migration UGO
TaurusDB
Middleware
Distributed Cache Service
API Gateway
Distributed Message Service for Kafka
Distributed Message Service for RabbitMQ
Distributed Message Service for RocketMQ
Cloud Service Engine
Multi-Site High Availability Service
EventGrid
Dedicated Cloud
Dedicated Computing Cluster
Business Applications
Workspace
ROMA Connect
Message & SMS
Domain Name Service
Edge Data Center Management
Meeting
AI
Face Recognition Service
Graph Engine Service
Content Moderation
Image Recognition
Optical Character Recognition
ModelArts
ImageSearch
Conversational Bot Service
Speech Interaction Service
Huawei HiLens
Video Intelligent Analysis Service
Developer Tools
SDK Developer Guide
API Request Signing Guide
Terraform
Koo Command Line Interface
Content Delivery & Edge Computing
Content Delivery Network
Intelligent EdgeFabric
CloudPond
Intelligent EdgeCloud
Solutions
SAP Cloud
High Performance Computing
Developer Services
ServiceStage
CodeArts
CodeArts PerfTest
CodeArts Req
CodeArts Pipeline
CodeArts Build
CodeArts Deploy
CodeArts Artifact
CodeArts TestPlan
CodeArts Check
CodeArts Repo
Cloud Application Engine
MacroVerse aPaaS
KooMessage
KooPhone
KooDrive
Help Center/ ROMA Connect/ Getting Started/ Using ROMA Connect for Service Integration

Using ROMA Connect for Service Integration

Updated on 2024-01-05 GMT+08:00

Overview

ROMA Connect encapsulates APIs, data sources, and custom functions into RESTful APIs and opens them to external systems, manages the whole API lifecycle, and protects APIs in multiple layers.

This chapter provides a configuration example to help you get familiar with the service integration process.

The steps for integrating services with ROMA Connect are as follows:

Prerequisites

Before performing this operation, complete the following preparations:

  • An EIP has been bound to the ROMA Connect instance, and the network where the local PC is located can communicate with the EIP network.
  • The Postman tool has been downloaded and installed on your local PC.

Step 1: Create an API Group

Each open API belongs to an API group. Before creating an API, create an API group.

  1. Log in to the ROMA Connect console. On the Instances page, click View Console of an instance.
  2. Create an integration application.
    1. In the navigation pane on the left, choose Integration Applications. In the upper right corner of the page, click Create Integration Application.
    2. In the dialog box displayed, set Name and Description, and click OK.
  3. In the navigation pane on the left, choose API Connect > API Groups. In the upper right corner of the page, click Create API Group and select Create Directly.
  4. In the Create API Group dialog box, enter the group-related parameters and click OK.
    Figure 1 API group configuration
    Table 1 Parameters for creating an API group

    Parameter

    Description

    Name

    Enter an API group name. Using naming rules facilitates future search.

    Scope

    Specify whether the API group is available on the current application or on all applications. Select Current application.

    Integration Application

    Select the integration application created in 2. If none is available, click Create Integration Application on the right to create one.

    Description

    Enter a brief description of the API group.

Step 2: Create an API

Create an API on ROMA Connect and associate it with the backend service.

  1. In the left navigation pane on the instance console, choose API Connect > APIs. In the upper right corner, click Create API.
  2. On the page displayed, configure the frontend definition of the API.
    Figure 2 Frontend configuration
    Table 2 Parameters for defining an API frontend

    Parameter

    Description

    API Name

    Enter an API name. Using naming rules facilitates future search.

    Integration Application

    Select the integration application created in Step 1: Create an API Group. If none is available, click Create Integration Application on the right to create one.

    Group

    Select the API group created in Step 1: Create an API Group.

    URL

    Configure the API access address.

    • Method: request method of the API. Set this parameter to GET here.
    • Protocol: request protocol of the API. Set this parameter to HTTPS here.
    • Path: request path of the API, in /getUserInfo/{userId} format. Set this parameter to /test here.

    Matching

    Matching mode of the API request path. Set this parameter to Exact match here.

    Tags

    Skip this parameter.

    Description

    Skip this parameter.

  3. Configure API security information.
    Figure 3 Security configuration
    Table 3 Security parameters

    Parameter

    Description

    Visibility

    Specifies whether the API can be released to the marketplace. Retain the default value Public, which indicates that the API can be released to the marketplace.

    Authentication Mode

    Security authentication mode used by the API. In this example, select None.

    CORS

    Specifies whether CORS is supported. You do not need to enable this option.

  4. Configure the request parameters of the API. You can skip this step and click Next.
  5. Set the backend type. In this example, select Mock to return specified response.
  6. Configure API backend information.
    Figure 4 Backend configuration
    Table 4 Parameters for defining an API backend

    Parameter

    Description

    Status Code

    Select the HTTP status code returned by the API. Use 200 here.

    Response

    Enter the response result of the API. In this example, set this parameter to ROMA TEST!. Once you call the API, ROMA TEST! is returned.

    Backend Authentication

    Specify whether to use a custom authorizer for authentication. Skip this parameter.

    Add Header

    Customize the header parameters of the API response. Skip this parameter.

  7. Configure response examples to help API callers understand the responses to an API request.
    Figure 5 Response configuration
    Table 5 Response parameters

    Parameter

    Description

    Example Success Response

    Example of a system response when an API is called successfully. In this example, set this parameter to ROMA TEST!.

    Example Failure Response

    Example of a system response when an API cannot be called. Skip this parameter.

  8. Click Finish. After the API is created, the API details page is displayed.

Step 3: Debug the API

After you create an API, debug it to ensure that the API functions properly.

  1. On the details page of the API created in Step 2: Create an API, click Debug in the upper right corner.
  2. Click Debug next to the API's access address. Request parameters are not required in this example because none has been set in previous steps.
  3. View the request and response for API calling.
    If the call is successful, a success response body is returned. In this example, ROMA TEST! is returned.
    Figure 6 API debugging
  4. Click on the right of Debug to return to the APIs details page after debugging.

Step 4: Publish the API

Once the API is tested normal, publish it to an environment so that it can be called by other users.

  1. On the API details page, click Publish in the upper right corner.
  2. On the page displayed, set Environment to RELEASE and click Publish.
    Figure 7 Publishing the API

Step 5: Call the API

In this example, Postman is used to call the API.

  1. Obtain request information of the API.
    On the API details page, view the API calling information, including the request method and access address.
    Figure 8 API request information
  2. Call the API.

    Use Postman to call the API obtained in 1.

    After the API is successfully called, check whether the response is the same as the test result in Step 3: Debug the API.

    Figure 9 API calling response

Usamos cookies para aprimorar nosso site e sua experiência. Ao continuar a navegar em nosso site, você aceita nossa política de cookies. Saiba mais

Feedback

Feedback

Feedback

0/500

Selected Content

Submit selected content with the feedback