El contenido no se encuentra disponible en el idioma seleccionado. Estamos trabajando continuamente para agregar más idiomas. Gracias por su apoyo.
- What's New
- Function Overview
- Product Bulletin
- Service Overview
- Billing
- Getting Started
-
User Guide
- Process of Using APIG
- Creating a User and Granting APIG Permissions
- Creating a Gateway
- Opening APIs
- (Optional) Configuring Authorization for API Calling
- Calling APIs
-
Managing APIs
- Overview
- Viewing or Modifying API Information
- Configuring Custom API Authentication
- Configuring API Parameter Orchestration Rules
- Customizing Error Response for APIs
- Cloning an API
- Taking an API Offline
- Importing and Exporting APIs
-
API Design File Extension Definitions
- x-apigateway-auth-type
- x-apigateway-request-type
- x-apigateway-match-mode
- x-apigateway-cors
- x-apigateway-is-send-fg-body-base64
- x-apigateway-any-method
- x-apigateway-backend
- x-apigateway-backend.parameters
- x-apigateway-backend.httpEndpoints
- x-apigateway-backend.httpVpcEndpoints
- x-apigateway-backend.functionEndpoints
- x-apigateway-backend.mockEndpoints
- x-apigateway-backend-policies
- x-apigateway-backend-policies.conditions
- x-apigateway-ratelimit
- x-apigateway-ratelimits
- x-apigateway-ratelimits.policy
- x-apigateway-ratelimits.policy.special
- x-apigateway-access-control
- x-apigateway-access-controls
- x-apigateway-access-controls.policy
- x-apigateway-plugins
- x-apigateway-auth-opt
- x-apigateway-result-normal-sample
- x-apigateway-result-failure-sample
- x-apigateway-authorizer
- x-apigateway-response
- x-apigateway-responses
- x-apigateway-pass-through
- x-apigateway-sample
- x-apigateway-content-type
- x-apigateway-orchestrations
- Configuring API Policies
- Configuring a Credential Policy
- Managing APIG Gateways
- Viewing Metrics and Configuring Alarms
- Viewing Audit Logs
- Shared Gateway (for Existing Users)
-
Best Practices
- Overview
-
API Openness
- Selectively Exposing CCE Workloads with a Dedicated Gateway
- Selectively Exposing Service Capabilities of a Data Center Using a Dedicated Gateway
- Exposing Backend Services Across VPCs Using a Dedicated Gateway
- Routing gRPC Service Requests Using a Dedicated Gateway
- Forwarding WebSocket Service Requests Using a Dedicated Gateway
- HTTP-to-HTTPS Auto Redirection with a Dedicated Gateway
- Calling Different Backend Services Using a Dedicated Gateway
- API Authentication
- API Policies
- API Security
- Developer Guide
-
API Reference
- Before You Start
- API Overview
- Calling APIs
-
Dedicated Gateway APIs (V2)
- API Group Management
- Environment Management
- Environment Variable Management
- Request Throttling Policy Management
-
API Management
- Creating an API
- Modifying an API
- Deleting an API
- Publishing an API or Taking an API Offline
- Querying API Details
- Querying APIs
- Verifying the API Definition
- Debugging an API
- Publishing APIs or Taking APIs Offline
- Querying Historical Versions of an API
- Switching the Version of an API
- Querying the Runtime Definition of an API
- Querying API Version Details
- Taking an API Version Offline
- Signature Key Management
- Binding/Unbinding Signature Keys
- Binding/Unbinding Request Throttling Policies
- Excluded Request Throttling Configuration
- App Authorization Management
- Resource Query
- Domain Name Management
- Access Control Policy Management
- Binding/Unbinding Access Control Policies
- Custom Authorizer Management
- API Import and Export
-
VPC Channel Management
- Creating a VPC Channel
- Updating a VPC Channel
- Deleting a VPC Channel
- Querying VPC Channel Details
- Querying VPC Channels
- Adding or Updating Backend Instances
- Querying Backend Servers of a VPC Channel
- Updating Backend Instances
- Removing a Backend Server
- Enabling Backend Servers
- Disabling Backend Servers
- Modifying VPC Channel Health Check
- Adding or Updating a Backend Server Group of a VPC Channel
- Querying Backend Server Groups of a VPC Channel
- Querying a Backend Server Group of a VPC Channel
- Deleting a Backend Server Group of a VPC Channel
- Updating a Backend Server Group of a VPC Channel
- Monitoring Information Query
- Group Response Management
- Tag Management
- Gateway Feature Management
- Configuration Management
-
Gateway Management
- Creating a Dedicated Gateway (Pay-Per-Use)
- Querying Dedicated Gateway Details
- Updating a Dedicated Gateway
- Querying the Creation Progress of a Dedicated Gateway
- Updating or Binding an EIP to a Dedicated Gateway
- Unbinding the EIP of a Dedicated Gateway
- Enabling Public Access for a Dedicated Gateway
- Updating the Outbound Access Bandwidth of a Dedicated Gateway
- Disabling Public Access for a Dedicated Gateway
- Enabling Public Inbound Access
- Updating Public Inbound Access Bandwidth of a Gateway
- Disabling Public Inbound Access for a Gateway
- Querying AZs
- Querying Dedicated Gateways
- Deleting a Dedicated Gateway
- Modifying the Specifications of a Pay-Per-Use Gateway
- Querying Gateway Constraints
- VPC Endpoint Management
- Gateway Tag Management
- Microservice Center Management
-
SSL Certificate Management
- Querying SSL Certificates
- Creating an SSL Certificate
- Binding a Domain Name with SSL Certificates
- Unbinding a Domain Name's SSL Certificates
- Querying Certificate Details
- Deleting an SSL Certificate
- Modifying an SSL Certificate
- Binding an SSL Certificate to a Domain Name
- Unbinding an SSL Certificate from a Domain Name
- Querying Domain Names of an SSL Certificate
-
Plug-in Management
- Creating a Plug-in
- Modifying a Plug-in
- Deleting a Plug-in
- Querying Plug-ins
- Querying Plug-in Details
- Binding a Plug-in to APIs
- Binding an API with Plug-ins
- Unbinding a Plug-in from All APIs
- Unbinding an API's Plug-ins
- Querying APIs Bound with a Plug-in
- Querying Plug-ins Bound to an API
- Querying APIs to Which a Plug-in Can Be Bound
- Querying Plug-ins That Can Be Bound to an API
-
Credential Management
- Creating an App
- Modifying an App
- Deleting an App
- Resetting the AppSecret of an App
- Verifying an App
- Querying App Details
- Querying Apps
- Creating an AppCode
- Generating an AppCode
- Deleting an AppCode
- Querying AppCode Details
- Querying AppCodes of an App
- Querying Quotas Associated with a Credential
- Configuring Access Control Settings for an App
- Querying Access Control Details About an App
- Deleting Access Control Settings of an App
-
Credential Quota Management
- Creating a Credential Quota
- Querying Credential Quota Details
- Querying Credential Quotas
- Modifying a Credential Quota
- Deleting a Credential Quota
- Querying the Credentials Bound to a Specified Quota
- Binding a Credential Quota with Credentials
- Unbinding a Credential Quota from a Credential
- Querying Credentials That Can Be Bound to a Credential Quota
- Asynchronous Task Management
- Orchestration Rule Management
- Gateway Custom Inbound Port Management
-
Shared Gateway APIs (for Existing Users)
- API Group Management
-
API Management
- Object Model
- Creating an API
- Modifying an API
- Deleting an API
- Publishing an API
- Taking an API Offline
- Publishing Multiple APIs or Taking Multiple APIs Offline
- Querying API Details
- Querying an API List
- Querying Historical API Versions
- Taking an Effective Version of an API Offline
- Querying Details of an API Version
- Querying the Runtime Definition of an API
- Debugging an API
- App Management
- App Authorization Management
- Environment Management
- Environment Variable Management
- Request Throttling Policy Management
- Binding Request Throttling Policies
- Excluded Request Throttling Configuration
- Access Control Policy Management
-
Binding Access Control Policies
- Object Model
- Binding an Access Control Policy to an API
- Querying the List of Access Control Policies Bound to an API
- Querying the List of APIs Bound to an Access Control Policy
- Querying the List of APIs Not Bound to an Access Control Policy
- Unbinding an Access Control Policy from an API
- Unbinding Multiple Access Control Policies from APIs
- Querying Subscription Information in KooGallery
- Configuration Management
- Resource Query
- Signature Key Management
- Binding Signature Keys
- Domain Name Management
- VPC Channel Management
- Querying Metrics
- OpenAPI
- Custom Authorizer Management
- Permissions Policies and Supported Actions
- Appendix
- Change History
- SDK Reference
-
FAQs
- Common FAQs
- Product Consulting FAQs
-
Opening APIs
- Why Can't I Create APIs?
- How Do I Define Response Codes for an API?
- Can I Specify a Private Network Load Balancer Address for the Backend Service?
- Can I Specify the Backend Address as a Subnet IP Address?
- Does APIG Support Multiple Backend Endpoints?
- Can I Bind Private Domain Names for API Access?
- Why Do I Fail to Call an API Across Domains?
- How Do I Use APIG to Open Up Services Deployed on Huawei Cloud?
- Publishing an API
-
Calling APIs
- What Are the Possible Causes for an API Calling Failure?
- Why Am I Seeing the Error Message "414 Request URI too large" When I Call an API?
- Why Am I Seeing the Error Message "The API does not exist or has not been published in the environment" When I Call an API?
- Why Am I Seeing the Error Message "No backend available" When I Call an API?
- Why Am I Seeing the Error Message "Backend unavailable" or "Backend timeout" When I Invoke the Backend Service?
- Why Am I Seeing the Error Message "Backend domain name resolution failed" When I Invoke the Backend Service?
- Why Am I Seeing the Error Message "Incorrect IAM authentication information" When I Call an API?
- Why Am I Seeing the Error Message "Incorrect app authentication information" When I Call an API?
- Why Doesn't Modification of the backend_timeout Parameter Take Effect?
- Does APIG Have a Limit on the Size of the API Request Body?
- Is There a Limit on the Size of the Response to an API Request?
- How Do I Call an API Using App Authentication in iOS System?
- Why Can't I Create a Header Parameter Named x-auth-token for an API Called Through IAM Authentication?
- Can Mobile Apps Call APIs?
- Can Applications Deployed in a VPC Call APIs?
- Does APIG Support WebSocket Data Transmission?
- How Will the Requests for an API with Multiple Backend Policies Be Matched and Executed?
- How Can I Access Backend Services over Public Networks Through APIG?
- API Authentication
-
API Policies
- Can I Configure the Maximum Number of Concurrent Requests?
- Is the Restriction of 1,000 Requests Per Day to a Debugging Domain Name Applied to Enterprise Accounts?
- Does APIG Have Bandwidth Limits?
- Why Doesn't a Request Throttling Policy Take Effect?
- How Do I Provide an Open API to Specific Users?
- Are Client IP Addresses Verified for Access Control?
- Importing and Exporting APIs
- Videos
-
More Documents
-
User Guide (Kuala Lumpur Region)
- Service Overview
- Getting Started
- Comparing Versions
- Overview
-
API Management
- Creating an API Group
- Binding a Domain Name
- Creating an Environment Variable
- Creating a Gateway Response
- Creating an API
- Cloning an API
- CORS
- Debugging an API
- Authorizing API Access
- Publishing an API
- Taking an API Offline
-
Importing and Exorting APIs
- Restrictions and Compatibility
- Importing APIs
- Exporting APIs
-
Extended Definition
- x-apigateway-auth-type
- x-apigateway-request-type
- x-apigateway-match-mode
- x-apigateway-cors
- x-apigateway-any-method
- x-apigateway-backend
- x-apigateway-backend.parameters
- x-apigateway-backend.httpEndpoints
- x-apigateway-backend.httpVpcEndpoints
- x-apigateway-backend.functionEndpoints
- x-apigateway-backend.mockEndpoints
- x-apigateway-backend-policies
- x-apigateway-backend-policies.conditions
- x-apigateway-ratelimit
- x-apigateway-ratelimits
- x-apigateway-ratelimits.policy
- x-apigateway-ratelimits.policy.special
- x-apigateway-access-control
- x-apigateway-access-controls
- x-apigateway-access-controls.policy
- x-apigateway-plugins
- Viewing APIs
- HTTP 2.0
- API Policies
- Credentials
- Monitoring & Analysis
- Gateway Management
- SDKs
- Published API Calling
- Permissions Management
- Auditing
-
FAQs
- Common FAQs
-
API Creation
- How Do I Define Response Codes for an API?
- How Do I Specify the Host Port for a VPC Channel (or Load Balance Channel)?
- How Do I Set the Backend Address If I Will Not Use a VPC Channel (or Load Balance Channel)?
- How Can I Configure the Backend Service Address?
- Can I Specify a Private Network Load Balancer Address for the Backend Service?
- Can I Specify the Backend Address as a Subnet IP Address?
- Does APIG Support Multiple Backend Endpoints?
- What Should I Do After Applying for an Independent Domain Name?
- Can I Bind Private Domain Names for API Access?
- Why Does an API Failed to Be Called Across Domains?
-
API Calling
- What Are the Possible Causes for an API Calling Failure?
- What Should I Do If an Error Code Is Returned During API Calling?
- Why Am I Seeing the Error Message "414 Request URI too large" When I Call an API?
- What Should I Do If "The API does not exist or has not been published in the environment." Is Displayed?
- Why Am I Seeing the Message "No backend available"?
- What Are the Possible Causes If the Message "Backend unavailable" or "Backend timeout" Is Displayed?
- Why Am I Seeing the Message "Backend domain name resolution failed" When a Backend Service Is Called?
- Why Doesn't Modification of the backend_timeout Parameter Take Effect?
- How Do I Switch the Environment for API Calling?
- What Is the Maximum Size of an API Request Package?
- How Do I Perform App Authentication in iOS System?
- Why Can't I Create a Header Parameter Named x-auth-token for an API Called Through IAM Authentication?
- App (Credential) FAQs
- Can Mobile Apps Call APIs?
- Can Applications Deployed in a VPC Call APIs?
- Does APIG Support WebSocket Data Transmission?
- Does APIG Support Persistent Connections?
- How Will the Requests for an API with Multiple Backend Policies Be Matched and Executed?
- Is There a Limit on the Size of the Response to an API Request?
- How Can I Access Backend Services over Public Networks Through APIG?
-
API Authentication
- Does APIG Support HTTPS Two-Way Authentication?
- How Do I Call an API That Does Not Require Authentication?
- Which TLS Versions Does APIG Support?
- Does APIG Support Custom Authentication?
- Will the Request Body Be Signed for Security Authentication?
- Common Errors Related to IAM Authentication Information
- What Should I Do If the App Authentication Information Is Incorrect?
- API Control Policies
- API Publishing
- API Import and Export
- API Security
- Other FAQs
- Change History
- Developer Guide (Kuala Lumpur Region)
-
API Reference (Kuala Lumpur Region)
- Before You Start
- Calling APIs
-
Dedicated Gateway APIs (V2)
- API Group Management
- Environment Management
- Environment Variable Management
- Request Throttling Policy Management
-
API Management
- Creating an API
- Modifying an API
- Deleting an API
- Publishing an API or Taking an API Offline
- Querying API Details
- Querying APIs
- Verifying the API Definition
- Debugging an API
- Publishing APIs or Taking APIs Offline
- Querying Historical Versions of an API
- Switching the Version of an API
- Querying the Runtime Definition of an API
- Querying API Version Details
- Taking an API Version Offline
- Signature Key Management
- Binding/Unbinding Signature Keys
- Binding/Unbinding Request Throttling Policies
- Excluded Request Throttling Configuration
- App Authorization Management
- Resource Query
- Domain Name Management
- Access Control Policy Management
- Binding/Unbinding Access Control Policies
- Custom Authorizer Management
- API Import and Export
-
VPC Channel Management
- Creating a VPC Channel
- Updating a VPC Channel
- Deleting a VPC Channel
- Querying VPC Channel Details
- Querying VPC Channels
- Adding or Updating Backend Instances
- Querying Backend Servers of a VPC Channel
- Updating Backend Instances
- Removing a Backend Server
- Enabling Backend Servers
- Disabling Backend Servers
- Modifying VPC Channel Health Check
- Adding or Updating a Backend Server Group of a VPC Channel
- Querying Backend Server Groups of a VPC Channel
- Querying a Backend Server Group of a VPC Channel
- Deleting a Backend Server Group of a VPC Channel
- Updating a Backend Server Group of a VPC Channel
- Monitoring Information Query
- Group Response Management
- Tag Management
- Gateway Feature Management
- Configuration Management
-
Gateway Management
- Creating a Dedicated Gateway (Pay-Per-Use)
- Querying Dedicated Gateway Details
- Updating a Dedicated Gateway
- Querying the Creation Progress of a Dedicated Gateway
- Updating or Binding an EIP to a Dedicated Gateway
- Unbinding the EIP of a Dedicated Gateway
- Enabling Public Access for a Dedicated Gateway
- Updating the Outbound Access Bandwidth of a Dedicated Gateway
- Disabling Public Access for a Dedicated Gateway
- Enabling Public Inbound Access
- Updating Public Inbound Access Bandwidth of a Gateway
- Disabling Public Inbound Access for a Gateway
- Querying AZs
- Querying Dedicated Gateways
- Deleting a Dedicated Gateway
- Modifying the Specifications of a Pay-Per-Use Gateway
- Querying Gateway Constraints
- VPC Endpoint Management
- Gateway Tag Management
-
SSL Certificate Management
- Querying SSL Certificates
- Creating an SSL Certificate
- Binding a Domain Name with SSL Certificates
- Unbinding a Domain Name's SSL Certificates
- Querying Certificate Details
- Deleting an SSL Certificate
- Modifying an SSL Certificate
- Binding an SSL Certificate to a Domain Name
- Unbinding an SSL Certificate from a Domain Name
- Querying Domain Names of an SSL Certificate
-
Plug-in Management
- Creating a Plug-in
- Modifying a Plug-in
- Deleting a Plug-in
- Querying Plug-ins
- Querying Plug-in Details
- Binding a Plug-in to APIs
- Binding an API with Plug-ins
- Unbinding a Plug-in from All APIs
- Unbinding an API's Plug-ins
- Querying APIs Bound with a Plug-in
- Querying Plug-ins Bound to an API
- Querying APIs to Which a Plug-in Can Be Bound
- Querying Plug-ins That Can Be Bound to an API
-
Credential Management
- Creating an App
- Modifying an App
- Deleting an App
- Resetting the AppSecret of an App
- Verifying an App
- Querying App Details
- Querying Apps
- Creating an AppCode
- Generating an AppCode
- Deleting an AppCode
- Querying AppCode Details
- Querying AppCodes of an App
- Querying Quotas Associated with a Credential
- Configuring Access Control Settings for an App
- Querying Access Control Details About an App
- Deleting Access Control Settings of an App
-
Credential Quota Management
- Creating a Credential Quota
- Querying Credential Quota Details
- Querying Credential Quotas
- Modifying a Credential Quota
- Deleting a Credential Quota
- Querying the Credentials Bound to a Specified Quota
- Binding a Credential Quota with Credentials
- Unbinding a Credential Quota from a Credential
- Querying Credentials That Can Be Bound to a Credential Quota
- Asynchronous Task Management
- Permissions Policies and Supported Actions
- Appendix
- Change History
-
User Guide (ME-Abu Dhabi Region)
- Service Overview
- Getting Started
- Comparing Versions
- Overview
-
API Management
- Creating an API Group
- Importing a CCE Workload
- Binding a Domain Name
- Creating an Environment Variable
- Creating a Gateway Response
- Creating an API
- Creating a gRPC API
- Cloning an API
- CORS
- Debugging an API
- Authorizing API Access
- Publishing an API
- Taking an API Offline
-
Importing and Exorting APIs
- Restrictions and Compatibility
- Importing APIs
- Exporting APIs
-
Extended Definition
- x-apigateway-auth-type
- x-apigateway-request-type
- x-apigateway-match-mode
- x-apigateway-cors
- x-apigateway-is-send-fg-body-base64
- x-apigateway-any-method
- x-apigateway-backend
- x-apigateway-backend.parameters
- x-apigateway-backend.httpEndpoints
- x-apigateway-backend.httpVpcEndpoints
- x-apigateway-backend.functionEndpoints
- x-apigateway-backend.mockEndpoints
- x-apigateway-backend-policies
- x-apigateway-backend-policies.conditions
- x-apigateway-ratelimit
- x-apigateway-ratelimits
- x-apigateway-ratelimits.policy
- x-apigateway-ratelimits.policy.special
- x-apigateway-access-control
- x-apigateway-access-controls
- x-apigateway-access-controls.policy
- x-apigateway-plugins
- Viewing APIs
- HTTP 2.0
- API Policies
- Credentials
- Monitoring & Analysis
- Gateway Management
- SDKs
- Published API Calling
- Permissions Management
- Auditing
-
FAQs
- Common FAQs
-
API Creation
- Why Can't I Create APIs?
- How Do I Define Response Codes for an API?
- How Do I Specify the Host Port for a VPC Channel (or Load Balance Channel)?
- How Do I Set the Backend Address If I Will Not Use a VPC Channel (or Load Balance Channel)?
- How Can I Configure the Backend Service Address?
- Can I Specify a Private Network Load Balancer Address for the Backend Service?
- Can I Specify the Backend Address as a Subnet IP Address?
- Does APIG Support Multiple Backend Endpoints?
- What Should I Do After Applying for an Independent Domain Name?
- Can I Bind Private Domain Names for API Access?
- Why Does an API Failed to Be Called Across Domains?
-
API Calling
- What Are the Possible Causes for an API Calling Failure?
- What Should I Do If an Error Code Is Returned During API Calling?
- Why Am I Seeing the Error Message "414 Request URI too large" When I Call an API?
- What Should I Do If "The API does not exist or has not been published in the environment." Is Displayed?
- Why Am I Seeing the Message "No backend available"?
- What Are the Possible Causes If the Message "Backend unavailable" or "Backend timeout" Is Displayed?
- Why Am I Seeing the Message "Backend domain name resolution failed" When a Backend Service Is Called?
- Why Doesn't Modification of the backend_timeout Parameter Take Effect?
- How Do I Switch the Environment for API Calling?
- What Is the Maximum Size of an API Request Package?
- How Do I Perform App Authentication in iOS System?
- Why Can't I Create a Header Parameter Named x-auth-token for an API Called Through IAM Authentication?
- App (Credential) FAQs
- Can Mobile Apps Call APIs?
- Can Applications Deployed in a VPC Call APIs?
- Does APIG Support WebSocket Data Transmission?
- Does APIG Support Persistent Connections?
- How Will the Requests for an API with Multiple Backend Policies Be Matched and Executed?
- Is There a Limit on the Size of the Response to an API Request?
- How Can I Access Backend Services over Public Networks Through APIG?
-
API Authentication
- Does APIG Support HTTPS Two-Way Authentication?
- How Do I Call an API That Does Not Require Authentication?
- Which TLS Versions Does APIG Support?
- Does APIG Support Custom Authentication?
- Will the Request Body Be Signed for Security Authentication?
- Common Errors Related to IAM Authentication Information
- What Should I Do If the App Authentication Information Is Incorrect?
- API Control Policies
- API Publishing
- API Import and Export
- API Security
- Other FAQs
- Change History
- Developer Guide (ME-Abu Dhabi Region)
-
API Reference (ME-Abu Dhabi Region)
- Before You Start
- Calling APIs
-
Dedicated Gateway APIs (V2)
- API Group Management
- Environment Management
- Environment Variable Management
- Request Throttling Policy Management
-
API Management
- Creating an API
- Modifying an API
- Deleting an API
- Publishing an API or Taking an API Offline
- Querying API Details
- Querying APIs
- Verifying the API Definition
- Debugging an API
- Publishing APIs or Taking APIs Offline
- Querying Historical Versions of an API
- Switching the Version of an API
- Querying the Runtime Definition of an API
- Querying API Version Details
- Taking an API Version Offline
- Signature Key Management
- Binding/Unbinding Signature Keys
- Binding/Unbinding Request Throttling Policies
- Excluded Request Throttling Configuration
- App Authorization Management
- Resource Query
- Domain Name Management
- Access Control Policy Management
- Binding/Unbinding Access Control Policies
- Custom Authorizer Management
- API Import and Export
-
VPC Channel Management
- Creating a VPC Channel
- Updating a VPC Channel
- Deleting a VPC Channel
- Querying VPC Channel Details
- Querying VPC Channels
- Adding or Updating Backend Instances
- Querying Backend Servers of a VPC Channel
- Updating Backend Instances
- Removing a Backend Server
- Enabling Backend Servers
- Disabling Backend Servers
- Modifying VPC Channel Health Check
- Adding or Updating a Backend Server Group of a VPC Channel
- Querying Backend Server Groups of a VPC Channel
- Querying a Backend Server Group of a VPC Channel
- Deleting a Backend Server Group of a VPC Channel
- Updating a Backend Server Group of a VPC Channel
- Monitoring Information Query
- Group Response Management
- Tag Management
- Gateway Feature Management
- Configuration Management
-
Gateway Management
- Creating a Dedicated Gateway (Pay-Per-Use)
- Querying Dedicated Gateway Details
- Updating a Dedicated Gateway
- Querying the Creation Progress of a Dedicated Gateway
- Updating or Binding an EIP to a Dedicated Gateway
- Unbinding the EIP of a Dedicated Gateway
- Enabling Public Access for a Dedicated Gateway
- Updating the Outbound Access Bandwidth of a Dedicated Gateway
- Disabling Public Access for a Dedicated Gateway
- Enabling Public Inbound Access
- Updating Public Inbound Access Bandwidth of a Gateway
- Disabling Public Inbound Access for a Gateway
- Querying AZs
- Querying Dedicated Gateways
- Deleting a Dedicated Gateway
- Modifying the Specifications of a Pay-Per-Use Gateway
- Querying Gateway Constraints
- VPC Endpoint Management
- Gateway Tag Management
- Microservice Center Management
-
SSL Certificate Management
- Querying SSL Certificates
- Creating an SSL Certificate
- Binding a Domain Name with SSL Certificates
- Unbinding a Domain Name's SSL Certificates
- Querying Certificate Details
- Deleting an SSL Certificate
- Modifying an SSL Certificate
- Binding an SSL Certificate to a Domain Name
- Unbinding an SSL Certificate from a Domain Name
- Querying Domain Names of an SSL Certificate
-
Plug-in Management
- Creating a Plug-in
- Modifying a Plug-in
- Deleting a Plug-in
- Querying Plug-ins
- Querying Plug-in Details
- Binding a Plug-in to APIs
- Binding an API with Plug-ins
- Unbinding a Plug-in from All APIs
- Unbinding an API's Plug-ins
- Querying APIs Bound with a Plug-in
- Querying Plug-ins Bound to an API
- Querying APIs to Which a Plug-in Can Be Bound
- Querying Plug-ins That Can Be Bound to an API
-
Credential Management
- Creating an App
- Modifying an App
- Deleting an App
- Resetting the AppSecret of an App
- Verifying an App
- Querying App Details
- Querying Apps
- Creating an AppCode
- Generating an AppCode
- Deleting an AppCode
- Querying AppCode Details
- Querying AppCodes of an App
- Querying Quotas Associated with a Credential
- Configuring Access Control Settings for an App
- Querying Access Control Details About an App
- Deleting Access Control Settings of an App
-
Credential Quota Management
- This API is used to creat a credential quota.
- Querying Credential Quota Details
- Querying Credential Quotas
- Modifying a Credential Quota
- Deleting a Credential Quota
- Querying the Credentials Bound to a Specified Quota
- Binding a Credential Quota with Credentials
- Unbinding a Credential Quota from a Credential
- Querying Credentials That Can Be Bound to a Credential Quota
- Asynchronous Task Management
- Permissions Policies and Supported Actions
- Appendix
- Change History
-
Best Practices (ME-Abu Dhabi Region)
- Selectively Exposing CCE Workloads with a Dedicated Gateway
- Selectively Exposing Service Capabilities of a Data Center Using a Dedicated Gateway
- Developing a Custom Authorizer with FunctionGraph
- Exposing Backend Services Across VPCs Using a Dedicated Gateway
- Interconnecting a Dedicated Gateway with WAF
- Request Throttling 2.0 with a Dedicated Gateway
- Two-Factor Authentication with a Dedicated Gateway
- HTTP-to-HTTPS Auto Redirection with a Dedicated Gateway
- Client Authentication with a Dedicated Gateway
- Invoking an API Policy Backend via Frontend Authentication Parameters (System Parameter)
- Forwarding WebSocket Services Using Dedicated Gateway
- Change History
- User Guide (Paris Region)
-
Developer Guide (Paris Region)
- Application Scenarios
- Calling APIs Through App Authentication
- Calling APIs Through IAM Authentication
- Creating Signatures for Backend Requests
-
Importing and Exporting APIs
- Restrictions and Compatibility
- Extended Definition
- API Import Precautions
- Examples of Importing APIs
- API Export Precautions
- Change History
-
API Reference (Paris Region)
- Before You Start
- Calling APIs
- Getting Started
-
Shared Gateway APIs
- API Group Management
-
API Management
- Object Model
- Registering an API
- Modifying an API
- Deleting an API
- Publishing an API
- Taking an API Offline
- Publishing Multiple APIs or Taking Multiple APIs Offline
- Querying API Details
- Querying an API List
- Querying Historical API Versions
- Taking an Effective Version of an API Offline
- Querying Details of an API Version
- Querying the Runtime Definition of an API
- Debugging an API
- App Management
- App Authorization Management
- Environment Management
- Environment Variable Management
- Request Throttling Policy Management
- Binding Request Throttling Policies
- Excluded Request Throttling Configuration
- Access Control Policy Management
-
Binding Access Control Policies
- Object Model
- Binding an Access Control Policy to an API
- Querying the List of Access Control Policies Bound to an API
- Querying the List of APIs Bound to an Access Control Policy
- Querying the List of APIs Not Bound to an Access Control Policy
- Unbinding an Access Control Policy from an API
- Unbinding Multiple Access Control Policies from APIs
- Querying Subscription Information in the Marketplace
- Resource Query
- Signature Key Management
- Binding Signature Keys
- Domain Name Management
- VPC Channel Management
- OpenAPI
- Custom Authorizer Management
- Appendix
- Change History
-
Dedicated API Gateway User Guide (Paris Region)
- Service Overview
- Getting Started
- Comparing Versions
- Overview
-
API Management
- Creating an API Group
- Binding a Domain Name
- Creating an Environment Variable
- Creating a Gateway Response
- Creating an API
- CORS
- Debugging an API
- Authorizing API Access
- Publishing an API
- Taking an API Offline
-
Importing and Exorting APIs
- Restrictions and Compatibility
- Importing APIs
- Exporting APIs
-
Extended Definition
- x-apigateway-auth-type
- x-apigateway-request-type
- x-apigateway-match-mode
- x-apigateway-cors
- x-apigateway-any-method
- x-apigateway-backend
- x-apigateway-backend.parameters
- x-apigateway-backend.httpEndpoints
- x-apigateway-backend.httpVpcEndpoints
- x-apigateway-backend.functionEndpoints
- x-apigateway-backend.mockEndpoints
- x-apigateway-backend-policies
- x-apigateway-backend-policies.conditions
- x-apigateway-ratelimit
- x-apigateway-ratelimits
- x-apigateway-ratelimits.policy
- x-apigateway-ratelimits.policy.special
- x-apigateway-access-control
- x-apigateway-access-controls
- x-apigateway-access-controls.policy
- x-apigateway-plugins
- Viewing APIs
- API Policies
- Credentials
- Monitoring & Analysis
- Gateway Management
- Published API Calling
- Permissions Management
- Auditing
-
FAQs
- Common FAQs
-
API Creation
- How Do I Define Response Codes for an API?
- How Do I Specify the Host Port for a VPC Channel (or Load Balance Channel)?
- How Do I Set the Backend Address If I Will Not Use a VPC Channel (or Load Balance Channel)?
- How Can I Configure the Backend Service Address?
- Can I Specify a Private Network Load Balancer Address for the Backend Service?
- Can I Specify the Backend Address as a Subnet IP Address?
- Does APIG Support Multiple Backend Endpoints?
- What Should I Do After Applying for an Independent Domain Name?
- Can I Bind Private Domain Names for API Access?
- Why Does an API Failed to Be Called Across Domains?
-
API Calling
- What Are the Possible Causes for an API Calling Failure?
- What Should I Do If an Error Code Is Returned During API Calling?
- Why Am I Seeing the Error Message "414 Request URI too large" When I Call an API?
- What Should I Do If "The API does not exist or has not been published in the environment." Is Displayed?
- Why Am I Seeing the Message "No backend available"?
- What Are the Possible Causes If the Message "Backend unavailable" or "Backend timeout" Is Displayed?
- Why Am I Seeing the Message "Backend domain name resolution failed" When a Backend Service Is Called?
- Why Doesn't Modification of the backend_timeout Parameter Take Effect?
- How Do I Switch the Environment for API Calling?
- What Is the Maximum Size of an API Request Package?
- How Do I Perform App Authentication in iOS System?
- Why Can't I Create a Header Parameter Named x-auth-token for an API Called Through IAM Authentication?
- App (Credential) FAQs
- Can Mobile Apps Call APIs?
- Can Applications Deployed in a VPC Call APIs?
- Does APIG Support WebSocket Data Transmission?
- Does APIG Support Persistent Connections?
- How Will the Requests for an API with Multiple Backend Policies Be Matched and Executed?
- Is There a Limit on the Size of the Response to an API Request?
- How Can I Access Backend Services over Public Networks Through APIG?
-
API Authentication
- Does APIG Support HTTPS Two-Way Authentication?
- How Do I Call an API That Does Not Require Authentication?
- Which TLS Versions Does APIG Support?
- Does APIG Support Custom Authentication?
- Will the Request Body Be Signed for Security Authentication?
- Common Errors Related to IAM Authentication Information
- API Control Policies
- API Publishing
- API Import and Export
- API Security
- Other FAQs
- Change History
- Dedicated API Gateway Developer Guide (Paris Region)
-
Dedicated API Gateway API Reference (Paris Region)
- Before You Start
- Calling APIs
-
Dedicated Gateway APIs (V2)
- API Group Management
- Environment Management
- Environment Variable Management
- Request Throttling Policy Management
-
API Management
- Creating an API
- Modifying an API
- Deleting an API
- Publishing an API or Taking an API Offline
- Querying API Details
- Querying APIs
- Debugging an API
- Publishing APIs or Taking APIs Offline
- Querying Historical Versions of an API
- Switching the Version of an API
- Querying the Runtime Definition of an API
- Querying API Version Details
- Taking an API Version Offline
- Signature Key Management
- Binding/Unbinding Signature Keys
- Binding/Unbinding Request Throttling Policies
- Excluded Request Throttling Configuration
- App Authorization Management
- Resource Query
- App Management
- Domain Name Management
- Access Control Policy Management
- Binding/Unbinding Access Control Policies
- Custom Authorizer Management
- API Import and Export
- VPC Channel Management
- Monitoring Information Query
- Group Response Management
- Tag Management
- Gateway Feature Management
- Configuration Management
-
Gateway Management
- Creating a Dedicated Gateway (Pay-Per-Use)
- Querying Dedicated Gateway Details
- Updating a Dedicated Gateway
- Querying the Creation Progress of a Dedicated Gateway
- Updating or Binding an EIP to a Dedicated Gateway
- Unbinding the EIP of a Dedicated Gateway
- Enabling Public Access for a Dedicated Gateway
- Updating the Outbound Access Bandwidth of a Dedicated Gateway
- Disabling Public Access for a Dedicated Gateway
- Querying AZs
- Querying Dedicated Gateways
- Deleting a Dedicated Gateway
- Permissions Policies and Supported Actions
- Appendix
- Change History
-
User Guide (Kuala Lumpur Region)
- General Reference
Copied.
Java
Scenarios
To use Java to call an API through app authentication, obtain the Java SDK, import the sample code, and then call the API by referring to the API calling example.
This section uses Eclipse 4.5.2 as an example.

Prerequisites
- You have obtained API calling information. For details, see Preparation.
- You have installed Eclipse 3.6.0 or a later version. If not, download Eclipse from the official Eclipse website and install it.
- You have installed IntelliJ IDEA 2022.2.1. If not, download the installation package from the official IntelliJ IDEA website and install it.
- You have installed Java Development Kit (JDK) 1.8.111 or a later version. If not, download JDK from the official Oracle website and install it. JDK 17 or later is not supported.
Obtaining the SDK
On the APIG console, choose Help Center > Using SDKs, and download the SDK of the desired language.
Alternatively, download the latest SDK version. Then obtain the ApiGateway-java-sdk.zip package. The following table shows the files decompressed from the package.
Name |
Description |
---|---|
libs\java-sdk-core-x.x.x.jar |
Signing SDK |
pom.xml |
Required for defining dependencies when building Maven projects |
changelog |
Change log |
src |
Demo code of the signature verification SDK
Classes:
|
Configuring IDEA
Use any of the following configuration methods:
- Importing the Sample Project
- Start IDEA and choose File > New > Project from Existing Sources.
Select the decompressed APIGW-java-sdk-x.x.x folder, and click OK to import the sample project.
- On the Import Project page, select Create project from existing sources.
Click Next until Import Project is displayed, select Maven, and click Create.
- You can create a project in the current window or a new window. In this example, click New Window.
- Start IDEA and choose File > New > Project from Existing Sources.
- Creating a Maven Project
- Start IDEA and choose File > New > Project.
- Select New Project, set the following parameters, and click Create.
Name: Enter apig-sdk-maven-demo.
Build System: Select Maven.
JDK: Select the version you use.
- Click New Window. You can also create a project in the current window.
- Copy the src and libs folders in the sample project to the apig-sdk-maven-demo project.
- Configure the pom.xml file of the new Maven project.
Expand the project file on the left, double-click pom.xml, and replace the file content with the following code: Download the dependency to the local repository for packaging.
<?xml version="1.0" encoding="UTF-8"?> <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> <modelVersion>4.0.0</modelVersion> <groupId>com.huawei.apigateway</groupId> <artifactId>java</artifactId> <version>1.0.0</version> <build> <plugins> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-compiler-plugin</artifactId> <version>3.8.0</version> <configuration> <source>1.8</source> <target>1.8</target> <encoding>UTF-8</encoding> </configuration> </plugin> </plugins> </build> <properties> <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding> <maven.compiler.source>1.8</maven.compiler.source> <maven.compiler.target>1.8</maven.compiler.target> </properties> <dependencies> <dependency> <groupId>commons-codec</groupId> <artifactId>commons-codec</artifactId> <version>1.15</version> </dependency> <dependency> <groupId>commons-logging</groupId> <artifactId>commons-logging</artifactId> <version>1.2</version> </dependency> <dependency> <groupId>org.apache.httpcomponents</groupId> <artifactId>httpclient</artifactId> <version>4.5.13</version> </dependency> <dependency> <groupId>com.squareup.okhttp3</groupId> <artifactId>okhttp</artifactId> <version>4.9.1</version> </dependency> <dependency> <groupId>org.apache.httpcomponents</groupId> <artifactId>httpcore</artifactId> <version>4.4.13</version> </dependency> <dependency> <groupId>org.slf4j</groupId> <artifactId>slf4j-api</artifactId> <version>1.7.25</version> <scope>compile</scope> </dependency> <dependency> <groupId>org.slf4j</groupId> <artifactId>slf4j-simple</artifactId> <version>1.7.25</version> </dependency> <dependency> <!--Replace this with the actual path.--> <systemPath>${project.basedir}/libs/java-sdk-core-XXX.jar</systemPath> <groupId>com.huawei.apigateway</groupId> <artifactId>java-sdk-core</artifactId> <version>SDK package version</version> <scope>system</scope> </dependency> <dependency> <groupId>org.openeuler</groupId> <artifactId>bgmprovider</artifactId> <version>1.0.3</version> </dependency> </dependencies> </project>
- Configure the Maven configuration file settings.xml.
- Add the following content to the profiles section:
<profile> <id>MyProfile</id> <repositories> <repository> <id>HuaweiCloudSDK</id> <url>https://mirrors.huaweicloud.com/repository/maven/huaweicloudsdk/</url> <releases> <enabled>true</enabled> </releases> <snapshots> <enabled>false</enabled> </snapshots> </repository> </repositories> <pluginRepositories> <pluginRepository> <id>HuaweiCloudSDK</id> <url>https://mirrors.huaweicloud.com/repository/maven/huaweicloudsdk/</url> <releases> <enabled>true</enabled> </releases> <snapshots> <enabled>false</enabled> </snapshots> </pluginRepository> </pluginRepositories> </profile>
- Add the following content to the mirrors section:
<mirror> <id>huaweicloud</id> <mirrorOf>*,!HuaweiCloudSDK</mirrorOf> <url>https://repo.huaweicloud.com/repository/maven/</url> </mirror>
- Add the activeProfiles tag to activate the configurations.
<activeProfiles> <activeProfile>MyProfile</activeProfile> </activeProfiles>
- Add the following content to the profiles section:
- To download the Maven dependency, right-click pom.xml, and choose Maven > Reload project from the shortcut menu.
- Expand the src file under the project on the left and double-click HttpClientDemo. If a green arrow is displayed, the creation is successful, as shown in the following figure.
API Calling Example
- Replace the API information in the HttpClientDemo.java file.
- In this example, the AK and SK stored in the environment variables are used. Specify the environment variables HUAWEICLOUD_SDK_AK and HUAWEICLOUD_SDK_SK in the local environment first. The following uses Linux as an example to describe how to set the obtained AK/SK as environment variables.
- Open the terminal and run the following command to open the environment variable configuration file:
- Set environment variables, save the file, and exit the editor.
export HUAWEICLOUD_SDK_AK="Obtained AK" export HUAWEICLOUD_SDK_SK="Obtained SK"
- Run the following command to apply the modification:
- Replace the API information and configured environment variables in the HttpClientDemo.java file.
NOTE:
HttpClientDemo references the following classes (view them in the src file mentioned in section "Obtaining the SDK"):
- Constant: constants used in the demo
- SSLCipherSuiteUtil: TLS authentication configuration tool. For example, it can be used to configure skipping certificate verification on clients.
- UnsupportProtocolException: exception handling class
public class HttpClientDemo { private static final Logger LOGGER = LoggerFactory.getLogger(HttpClientDemo.class); public static void main(String[] args) throws Exception { // Create a new request. Request httpClientRequest = new Request(); try { // Set the request parameters. // AppKey, AppSecrect, Method and Url are required parameters. // Directly writing AK/SK in code is risky. For security, encrypt your AK/SK and store them in the configuration file or environment variables. // In this example, the AK/SK are stored in environment variables for identity authentication. // Before running this example, set environment variables HUAWEICLOUD_SDK_AK and HUAWEICLOUD_SDK_SK. httpClientRequest.setKey(System.getenv("HUAWEICLOUD_SDK_AK")); httpClientRequest.setSecret(System.getenv("HUAWEICLOUD_SDK_SK")); httpClientRequest.setMethod("POST"); // Set a request URL in the format of https://{Endpoint}/{URI}. httpClientRequest.setUrl("put your request url here"); httpClientRequest.addHeader("Content-Type", "text/plain"); // Set a body for http request. httpClientRequest.setBody("put your request body here"); } catch (Exception e) { LOGGER.error(e.getMessage()); return; } CloseableHttpClient client = null; try { // Sign the request. HttpRequestBase signedRequest = Client.sign(httpClientRequest, Constant.SIGNATURE_ALGORITHM_SDK_HMAC_SHA256); if (Constant.DO_VERIFY) { // creat httpClient and verify ssl certificate HostName.setUrlHostName(httpClientRequest.getHost()); client = (CloseableHttpClient) SSLCipherSuiteUtil.createHttpClientWithVerify(Constant.INTERNATIONAL_PROTOCOL); } else { // creat httpClient and do not verify ssl certificate client = (CloseableHttpClient) SSLCipherSuiteUtil.createHttpClient(Constant.INTERNATIONAL_PROTOCOL); } HttpResponse response = client.execute(signedRequest); // Print the body of the response. HttpEntity resEntity = response.getEntity(); if (resEntity != null) { LOGGER.info("Processing Body with name: {} and value: {}", System.getProperty("line.separator"), EntityUtils.toString(resEntity, "UTF-8")); } } catch (Exception e) { LOGGER.error(e.getMessage()); } finally { if (client != null) { client.close(); } } } }
- In this example, the AK and SK stored in the environment variables are used. Specify the environment variables HUAWEICLOUD_SDK_AK and HUAWEICLOUD_SDK_SK in the local environment first. The following uses Linux as an example to describe how to set the obtained AK/SK as environment variables.
- Run HttpClientDemo.java to sign the request, access the API, and print the result.
The following is an example output:
[main] INFO com.huawei.apig.sdk.demo.HttpClientDemo - Print the authorization: [Authorization: SDK-HMAC-SHA256 Access=3afe***ba29, SignedHeaders=host;x-sdk-date, Signature=26b2***dbf6] [main] INFO com.huawei.apig.sdk.demo.HttpClientDemo - Print the status line of the response: HTTP/1.1 200 OK [main] INFO com.huawei.apig.sdk.demo.HttpClientDemo - Processing Header with name: Date and value: Fri, 26 Aug 2022 08:58:51 GMT [main] INFO com.huawei.apig.sdk.demo.HttpClientDemo - Processing Header with name: Content-Type and value: application/json [main] INFO com.huawei.apig.sdk.demo.HttpClientDemo - Processing Header with name: Transfer-Encoding and value: chunked [main] INFO com.huawei.apig.sdk.demo.HttpClientDemo - Processing Header with name: Connection and value: keep-alive [main] INFO com.huawei.apig.sdk.demo.HttpClientDemo - Processing Header with name: Server and value: api-gateway [main] INFO com.huawei.apig.sdk.demo.HttpClientDemo - Processing Header with name: X-Request-Id and value: 10955c5346b9512d23f3fd4c1bf2d181 [main] INFO com.huawei.apig.sdk.demo.HttpClientDemo - Processing Body with name: and value: {"200": "sdk success"}
If {"200": "sdk success"} is displayed, the signing is successful and the API request is sent to the backend.
If the AK or SK has changed, APIG returns an error message.
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.See the reply and handling status in My Cloud VOC.
For any further questions, feel free to contact us through the chatbot.
Chatbot