HTTP Integration
Overview
The HTTP integration package provides a flexible HTTP client for making REST API calls to external services. It supports all standard HTTP methods (GET, POST, PUT, PATCH) for both pulling data from (origin) and sending data to (destination) external APIs.
This integration is perfect for connecting to any REST API that doesn't have a dedicated Retrieve integration package, allowing you to build custom integrations with third-party services quickly and efficiently.
Key Features
🌐 Universal HTTP Client
Connect to any REST API with support for GET, POST, PUT, and PATCH methods
🔄 Bidirectional Operations
Both origin actions (pull data) and destination actions (send data) available
🔐 Flexible Authentication
Support for various auth methods via custom headers (Bearer tokens, API keys, OAuth)
⚙️ Configurable Requests
Full control over headers, query parameters, request body, and timeout settings
🛡️ Error Handling
Built-in error handling and retry logic for reliable API communication
📊 Response Processing
Automatic JSON parsing and response data transformation
When to Use This Integration
- Connect to custom APIs that don't have dedicated integrations
- Pull data from external services using REST APIs
- Send data to external systems via HTTP POST/PUT/PATCH
- Build webhooks to receive or send data in real-time
- Integrate with internal APIs within your infrastructure
- Test API endpoints during development and debugging
Configuration
Basic Configuration Fields
The HTTP integration requires minimal base configuration. Most settings are action-specific:
{
"url": "https://api.example.com",
"headers": {
"Authorization": "Bearer YOUR_TOKEN",
"Content-Type": "application/json"
},
"params": {
"limit": 100
},
"timeout": 30000
}url
Type: String (required per action)
Description: The base URL or full endpoint URL for API requests
Example: https://api.example.com
headers
Type: Object (optional)
Description: HTTP headers to include in requests (authentication, content-type, etc.)
Example: {"Authorization": "Bearer token", "Content-Type": "application/json"}
params
Type: Object (optional)
Description: Query parameters to append to the URL
Example: {"limit": 100, "offset": 0}
timeout
Type: Integer (optional)
Description: Request timeout in milliseconds
Default: 30000 (30 seconds)
Origin vs Destination Actions
🔵 Origin Actions (Pull Data)
Origin actions make HTTP requests to external APIs and pass the response data to the next action in your workflow.
- http_origin_get - Retrieve data using GET requests
- http_origin_post - Send POST request and receive response
- http_origin_put - Send PUT request and receive response
- http_origin_patch - Send PATCH request and receive response
Use Case: Pull data from external APIs to process or sync to other systems.
🟢 Destination Actions (Send Data)
Destination actions receive data from previous workflow actions and send it to external APIs.
- http_destination_get - Make GET request (less common for destinations)
- http_destination_post - Create resources using POST
- http_destination_put - Update resources using PUT
- http_destination_patch - Partially update resources using PATCH
Use Case: Send processed data to external APIs or webhook endpoints.
Authentication Methods
Bearer Token
{
"headers": {
"Authorization": "Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9..."
}
}API Key
{
"headers": {
"X-API-Key": "your-api-key-here"
}
}Basic Auth
{
"headers": {
"Authorization": "Basic dXNlcm5hbWU6cGFzc3dvcmQ="
}
}Custom Headers
{
"headers": {
"X-Custom-Auth": "custom-value",
"X-Client-ID": "client-123"
}
}Use Cases
🔗 Third-Party API Integration
Connect to any third-party REST API that doesn't have a dedicated integration package.
🪝 Webhook Endpoints
Send data to webhook URLs for real-time notifications and integrations.
🔄 Data Synchronization
Pull data from external APIs and push to other systems in automated workflows.
🏢 Internal APIs
Integrate with your own internal APIs and microservices.
🧪 API Testing
Test and debug API endpoints during development and integration setup.
📡 IoT & Device APIs
Communicate with IoT devices and hardware APIs using HTTP protocols.
Best Practices
Secure Authentication Credentials
Store API keys and tokens securely in Retrieve's configuration, never hardcode them in workflows.
Set Appropriate Timeouts
Configure timeout values based on expected API response times to prevent workflow hangs.
Handle Rate Limits
Respect API rate limits by adding appropriate delays between requests when processing large datasets.
Validate Response Data
Always validate API responses before passing data to subsequent actions in your workflow.
Use Appropriate HTTP Methods
Follow REST conventions: GET for reading, POST for creating, PUT for replacing, PATCH for updating.
Error Handling
The HTTP integration includes built-in error handling for common scenarios:
- Network Errors: Connection timeouts, DNS failures, network unavailability
- HTTP Errors: 4xx client errors, 5xx server errors with detailed messages
- Parse Errors: Invalid JSON responses or unexpected data formats
- Authentication Errors: 401 Unauthorized, 403 Forbidden responses
Configure retry logic and error notifications in your workflow to handle transient failures gracefully.
Support & Resources
For help with HTTP integration:
- Review the individual action documentation pages for specific HTTP methods
- Consult the target API's documentation for endpoint details and authentication
- Contact Retrieve support for integration-specific questions