---
title: "How to send ConnectiveOne data with send_request"
description: "Send scenario data to an external API, use saved credentials, and handle successful and failed Send Request responses."
---

# How to Send Data from ConnectiveOne via send_request

The `send_request` action allows sending any arbitrary HTTP requests from ConnectiveOne to external services. This is useful for integrating with CRM, ERP, marketing platforms, and other systems.

> **Scenario secrets:** if enabled by your instance administrator, insert authentication into Send Request request fields. See [manage scenario secrets](/en/settings/how-to/manage-action-credentials.md).

---

## Differences from send_me

**`send_me`:**
- Automatically adds `chat_id` and `channel` to request data
- Ideal for webhook integrations where chat context is needed

**`send_request`:**
- Does not automatically add `chat_id` and `channel`
- More flexible for arbitrary API requests
- Supports Basic and Bearer authorization

---

## Configuration

In this action configuration, specify:

- `url` — address to send the request to, you can use `{{placeholders}}`
- `method` — request method (GET, POST, PUT, PATCH, DELETE)
- `data` — additional parameters to send, can contain placeholders
- `headers` — request headers
- `basic_auth` — data for Basic authorization (optional)
- `bearer_auth` — token for Bearer authorization (optional)

---

## Possible Branching by Events

- `"ok"` — request successfully executed
- `"not_ok"` — error during request execution

---

## Configuration Examples

### Example 1: Simple POST Request

```json
{
  "url": "https://your-service.com/api/webhook",
  "method": "POST",
  "data": {
    "data_source": "ConnectiveOne",
    "client_id": "{{messenger_input_param}}"
  },
  "headers": {
    "Content-Type": "application/json",
    "X-Custom-Header": "MyValue"
  }
}
```

### Example 2: GET Request with Parameters

```json
{
  "url": "https://api.example.com/users?name={{user_name}}&email={{user_email}}",
  "method": "GET",
  "headers": {
    "Content-Type": "application/json"
  }
}
```

### Example 3: POST Request with Basic Authorization

```json
{
  "url": "https://api.example.com/secure",
  "method": "POST",
  "data": {
    "message": "{{user_message}}"
  },
  "basic_auth": {
    "login": "username",
    "pass": "password"
  }
}
```

### Example 4: POST Request with Bearer Token

```json
{
  "url": "https://api.example.com/data",
  "method": "POST",
  "data": {
    "action": "update",
    "value": "{{some_value}}"
  },
  "bearer_auth": {
    "token": "{{api_token}}"
  },
  "headers": {
    "Content-Type": "application/json"
  }
}
```

---

## Error Handling

If the request ended with an error, the action returns `"not_ok"`. In the scenario, you can handle this event for:

- Retry
- Sending a message to the user
- Logging the error
- Transferring to operator

---

## Limitations

- URL must be accessible from the ConnectiveOne server
- Only HTTP and HTTPS protocols are supported
- Request timeout depends on system settings
- Maximum data size is limited by system settings

---

## Related Articles

- [Get data via send_request](/en/integrations/how-to/data-transfer/get-data-via-send-request.md)
- [Subscribe user to notifications](/en/integrations/how-to/data-transfer/subscribe-user-to-notifications.md)
- [What are integrations](/en/integrations/explanation/what-are-integrations.md)
