Apidog Docs
πŸ‡ΊπŸ‡Έ English
  • πŸ‡ΊπŸ‡Έ English
  • πŸ‡―πŸ‡΅ ζ—₯本θͺž
HomeLearning CenterSupport CenterAPI References
HomeLearning CenterSupport CenterAPI References
Discord Community
Slack Community
X / Twitter
πŸ‡ΊπŸ‡Έ English
  • πŸ‡ΊπŸ‡Έ English
  • πŸ‡―πŸ‡΅ ζ—₯本θͺž
  1. Send requests
  • Apidog Learning Center
  • Get started
    • Introduce Apidog
    • Basic concepts in Apidog
    • Navigating Apidog
    • Quick Start
      • Overview
      • Specify a new endpoint
      • Make a request to the endpoint
      • Add an assertion
      • Create a test scenario
      • Share your API documentation
      • Explore more
      • Send a request and save as an endpoint
    • Migration
      • Overview
      • Manual import
      • Scheduled import
      • Import options
      • Export data
      • Import from...
        • Import from Postman
        • Import OpenAPI (Swagger) spec
        • Import cURL
        • Import Markdowns
        • Import from Insomnia
        • Import from apiDoc
        • Import .har file
        • Import WSDL
  • Design APIs
    • Overview
    • Create a new API project
    • Endpoint basics
    • Components
    • Common fields
    • Global parameters
    • Endpoint change history
    • Batch endpoint management
    • Configure multiple request body examples
    • Schemas
      • Generate Schemas from JSON etc.
      • Build a schema
      • Overview
      • Create a new schema
    • Security schemes
      • Overview
      • Create a security scheme
      • Use the security scheme
      • Security scheme in online documentation
    • Advanced features
      • Custom endpoint fields
      • Import endpoints as test steps
      • Endpoint status
      • Appearance of parameter lists
      • Endpoint unique idenfication
  • Develop and Debug APIs
    • Overview
    • Generate requests
    • Send requests
    • Endpoint cases
    • Dynamic values
    • Validate responses
    • Design-first Mode & Request-first Mode
    • Generate code
    • Environments & variables
      • Overview
      • Using variables
      • Environments & services
    • Vault secrets
      • Overview
      • HashiCorp Vault
      • Azure Key Vault
      • AWS Secrets Manager
    • Pre/Post processors
      • Overview
      • Assertion
      • Extract variable
      • Wait
      • Database operations
        • Overview
        • MongoDB
        • Redis
        • Oracle Client
      • Using scripts
        • Overview
        • Postman scripts reference
        • Pre processor scripts
        • Post processor scripts
        • Public scripts
        • Calling other programming languages
        • Using JS libraries
        • Visualizing responses
        • Script examples
          • Assertion scripts
          • Using variables in scripts
          • Using scripts to modify request messages
          • Other examples
    • Dynamic values Modules
  • Mock API data
    • Overview
    • Smart mock
    • Custom mock
    • Mock priority sequence
    • Mock scripts
    • Cloud mock
    • Self-hosted runner mock
    • Mock language (Locales)
  • Automated tests
    • Overview
    • Test reports
    • Test scenarios
      • Create a test scenario
      • Pass data between requests
      • Flow control conditions
      • Import endpoints/endpoint cases from other projects
      • Sync data from endpoints/endpoint cases
      • Export test scenarios
    • Run test scenarios
      • Run a test scenario
      • Data-driven testing
      • Run test scenarios in batch
      • Scheduled tasks
      • Manage the runtime environment of APIs from other projects
    • Test APIs
      • Integration testing
      • Performance testing
      • End-to-end testing
      • Regression testing
    • Apidog CLI
      • Overview
      • Installing and running Apidog CLI
      • Apidog CLI Options
    • CI/CD
      • Overview
      • Integrate with Jenkins
      • Integration with Gitlab
  • Publish API Docs
    • Overview
    • API Technologies Supported
    • Quick share
    • View the API documentation
    • Publish docs sites
    • Folder tree settings
    • Custom layouts
    • Visibility settings
    • Endpoint SEO settings
    • Custom domain
    • Embedding values in document URLs
    • Documentation Search
    • Integrating Google Analytics with Doc Sites
    • CORS Proxy
    • API Versions
      • Overview
      • Create API versions
      • Publish API versions
      • Share endpoints with API versions
  • Send requests
    • Overview
    • gRPC
    • Use request proxy agents for debugging
    • SOAP/WebService
    • GraphQL
    • WebSocket
    • Socket.IO
    • SSE debugging
    • Create requests
      • Request History
      • Request basics
      • Parameters and body
      • Request headers
      • Request settings
      • HTTP/2
    • Authentication and authorization
      • Overview
      • CA and client certificates
      • Authorization types supported by Apidog
      • Digest Auth
      • OAuth 1.0
      • OAuth 2.0
      • Hawk Authentication
      • Kerberos
      • NTLM
      • Akamai EdgeGrid
    • Response and cookies
      • Overview
      • API response in Apidog
      • Create and send cookies
      • Debug requests
      • Save the request as an endpoint
  • Branches
    • Overview
    • Create a new sprint branch
    • Test APIs in a branch
    • Design API in a branch
    • Merge sprint branches
    • Manage sprint branches
  • Apidog MCP Server
    • Overview
    • Conntect API Specification within Apidog Project to AI via Apidog MCP Server
    • Conntect Online API Documentation Published by Apidog to AI via Apidog MCP Server
    • Conntect OpenAPI Files to AI via Apidog MCP Server
  • Best practices
    • How to handle API signatures
    • How to access OAuth 2.0 protected APIs
    • Apidog collaboration workflow
    • Managing authentication state in Apidog
  • Administration
    • Onboarding Checklist
      • Basic Concepts
      • Onboarding Guide
    • Managing Teams
      • Managing Teams
      • Managing Team Members
      • Member Roles & Permission Settings
      • Team Activities
      • Team Resources
        • General Runner
        • Team Variables
        • Request Proxy Agent
      • Real-time Collaborations
        • Team Collaboration
    • Managing Projects
      • Managing Projects
      • Managing Project Members
      • Notification Settings
      • Project Resources
        • Database Connection
    • Managing Organizations
      • Single Sign-On (SSO)
        • SSO Overview
        • Configure Microsoft Entra ID
        • Configure Okta
        • Configure SSO for an Organization
        • Managing user accounts
        • Mapping Groups to Teams
      • SCIM Provisioning
        • Intro to SCIM Provisioning
        • Microsoft Entra ID
        • Okta
      • Organization Resources
        • Self-hosted Runner
  • Billing
    • Overview
    • Credits
    • Unable to use credit cards?
    • Managing subscriptions
    • Upgrade plan
  • Add-ons
    • API Hub
    • Apidog Intellij IDEA plugin
    • Browser Extension
      • Chrome
      • Microsoft Edge
    • Request Proxy
      • Request proxy in Apidog web
      • Request proxy in shared docs
      • Request proxy in Apidog client
  • Account & preferences
    • Language settings
    • Data backup
    • Network proxy configuration
    • Hot keys
    • Updating Apidog
    • Generate OpenAPI access token
    • Deleting account
    • Account settings
  • References
    • API-Design First Approach
    • Apidog OpenAPI Specificaiton Extensions
    • JSONPath
    • XPath
    • Regular Expressions
    • JSON Schema
    • CSV File Format
    • Install Java Environment
    • Runner deployment environment
    • Apidog flavored Markdown
  • Apidog Europe
    • Apidog Europe
  • Support Center
  1. Send requests

gRPC

gRPC is an efficient, fast, and reliable Remote Procedure Call (RPC) framework widely used in various scenarios. In microservices architecture, Apidog facilitates efficient communication across services. For scenarios involving substantial data transfer, Apidog utilizes streaming capabilities to reduce network latency and bandwidth consumption.
The gRPC API debugging functionality is currently in the Beta testing phase. Apidog version must be equal to or greater than 2.3.0 to use the gRPC API debugging feature.

Create a New gRPC Project#

Click the "New Project" button on the Apidog homepage and select "gRPC Project (Beta)."

Import Proto#

gRPC follows an API-First approach, meaning that before development, services, methods, and messages must be defined through .proto files. Therefore, before debugging gRPC APIs using Apidog, you need to import the .proto file that serves as the API definition.

Initial Import#

Currently, there are two ways to import .proto files:
Local file
URL hosting the .proto file
The selected .proto file will be imported as one Proto, where the service will be imported as a service, and rpc will be imported as methods.
If the chosen .proto file depends on other .proto files, you need to manually add the dependency directory.
Services from other .proto files that the selected .proto file depends on will also be imported into the same Proto if their package belongs to the same package as the selected .proto file.

Reimport#

If the imported .proto file undergoes changes, it can be reimported in Apidog: right-click on Proto, then click the "Reimport" button.

Invocation Methods#

When defining gRPC methods using .proto files, Apidog supports four types:
Unary: One-way call
Server Streaming: Server-side streaming
Client Streaming: Client-side streaming
Bidirectional Streaming: Bidirectional streaming
Apidog supports all four method types.

Unary Call#

Unary calls are similar to HTTP requests. Enter the URL in the address bar, input the message content in JSON format under the Message tab, click the "Invoke" button, and the unary call will be initiated.
Additionally, you can manually fill in Metadata and Auth information to meet authentication or other complex scenarios.

Streaming Call#

Streaming calls are similar to WebSocket connections. After initiating the call, you can write and send messages under the Message tab. Server streaming, client streaming, and bidirectional streaming fall under the streaming call types.
Apidog provides a timeline view that centrally displays the call status, sent messages, and received messages in chronological order. Clicking on a message allows easy viewing of message details.

Advanced Usage#

Auto-generate Dynamic Values#

Apidog can recognize the content in .proto files, allowing you to click the "Auto-generate" button to generate the message body. For more flexible dynamic data, you can configure and generate expressions using the "Dynamic Values" feature.
Refer to the "Dynamic Values" for more detailed instructions.

Use Variables#

You can use Apidog variables in gRPC messages and Metadata.Refer to the "Environment Variable Types" documentation for detailed instructions.

Enable TLS#

gRPC APIs support establishing secure connections through TLS.
Using Apidog, you can click on the protocol selector in front of the URL to quickly toggle the TLS status.
Additionally, Apidog is compatible with using grpcs:// in the URL to enable TLS for the connection. Conversely, grpc:// indicates TLS is not enabled.

Manage Server Addresses and Environments#

Click the plus icon on the right side of the URL address bar to add the currently used server address to an environment.
Then, select the environment and server address in the upper right corner, and choose "Follow Default" in the URL address bar to use a unified server address for debugging all methods.

View Proto Files and API Parameters#

View Proto File Content#

In Apidog, clicking on the Proto in the left directory tree allows you to view the raw content of the .proto file.

View Request and Response Parameters#

gRPC uses ProtoBuf as the serialization format, meaning that each message is transmitted in ProtoBuf format when sending or receiving messages. Unlike other text-based serialization formats (JSON, XML), ProtoBuf is a binary format not suitable for human writing and reading. Therefore, when calling gRPC APIs In Apidog, all messages are written and displayed in JSON format.
You can view the request and response parameters represented in JSON format on the API information page.
ProtoBuf and JSON have a mapping relationship for data types, as shown in the table below:
ProtoBuf 3JSONJSON Example
messageobject{"fooBar": v, "g": null, …}
enumstring"FOO_BAR"
map<K,V>object{"k": v, …}
repeated Varray[v, …]
boolbooleantrue, false
stringstring"Hello World!"
bytesbase64 string"YWJjMTIzIT8kKiYoKSctPUB+"
int32, fixed32, uint32number1, -10, 0
int64, fixed64, uint64string"1", "-10"
float, doublenumber1.1, -10.0, 0, "NaN", "Infinity"

Save Debugging Information#

After completing debugging, click the "Save" button to save server URL, messages, Metadata, etc., in the current method for other team members to debug.
Modified atΒ 2025-01-27 02:32:30
Previous
Overview
Next
Use request proxy agents for debugging
Built with