# sendings (records)

| Required permit | Rate limit tokens cost |
| --- | --- |
| Reporting:Api:Report:Sendings | 2 |

This report allows you to get information about sendings in your loyalty club.


## Fields

### id

| Type | Filterable | Can change? |
| --- | --- | --- |
| Integer | <Icon icon="material-outline-highlight_off"/> | <Icon icon="material-outline-highlight_off"/> |

Internal ID of sending.

### loyalty_club_id

| Type | Filterable | Can change? |
| --- | --- | --- |
| Integer | <Icon icon="material-outline-done"/> (via `X-Customer` header) | <Icon icon="material-outline-highlight_off"/> |

ID of loyalty club.

### language

| Type | Filterable | Can change? |
| --- | --- | --- |
| Enum | <Icon icon="material-outline-highlight_off"/> | <Icon icon="material-outline-highlight_off"/> |

Language of sending.

### channel

| Type | Filterable | Can change? |
| --- | --- | --- |
| String | <Icon icon="material-outline-done"/> | <Icon icon="material-outline-highlight_off"/> |

Sending's channel.

This field is an enum, possible values are:

* sms
* email
* push

### service_type

| Type | Filterable | Can change? |
| --- | --- | --- |
| Enum | <Icon icon="material-outline-done"/> | <Icon icon="material-outline-highlight_off"/> |

Sending's service_type.

### reporting_id

| Type | Filterable | Can change? |
| --- | --- | --- |
| Integer | <Icon icon="material-outline-done"/> | <Icon icon="material-outline-highlight_off"/> |

Sending's reporting_id. This field can be used to attribute reported sending to its source.

### source_app

| Type | Filterable | Can change? |
| --- | --- | --- |
| Enum | <Icon icon="material-outline-highlight_off"/> | <Icon icon="material-outline-highlight_off"/> |

Identifier of application which is the source of given sending.

This field is an enum, possible values are:

* the-big-project
* messages_api

### source_type

| Type | Filterable | Can change? |
| --- | --- | --- |
| Enum | <Icon icon="material-outline-highlight_off"/> | <Icon icon="material-outline-highlight_off"/> |

Type of sending connected with its source.

This field is an enum, possible values are:

* campaigns
* triggers
* other

### source_id

| Type | Filterable | Can change? |
| --- | --- | --- |
| Integer | <Icon icon="material-outline-highlight_off"/> | <Icon icon="material-outline-highlight_off"/> |

ID set by source application.

### audience_id

| Type | Filterable | Can change? |
| --- | --- | --- |
| Integer | <Icon icon="material-outline-highlight_off"/> | <Icon icon="material-outline-highlight_off"/> |

ID of audience to which sending was scheduled.

### campaign_id

| Type | Filterable | Can change? |
| --- | --- | --- |
| Integer | <Icon icon="material-outline-highlight_off"/> | <Icon icon="material-outline-highlight_off"/> |

ID of campaign to which sending was scheduled.

### dispatches_count

| Type | Filterable | Can change? |
| --- | --- | --- |
| Integer | <Icon icon="material-outline-highlight_off"/> | <Icon icon="material-outline-done"/> |

Number of messages scheduled to be sent.

### members_count

| Type | Filterable | Can change? |
| --- | --- | --- |
| Integer | <Icon icon="material-outline-highlight_off"/> | <Icon icon="material-outline-done"/> |

Number of members to which messages were scheduled to be sent.

### new_count

| Type | Filterable | Can change? |
| --- | --- | --- |
| Integer | <Icon icon="material-outline-highlight_off"/> | <Icon icon="material-outline-done"/> |

Number of messages in preprocessing stage during sending.

### transiently_failed_count

| Type | Filterable | Can change? |
| --- | --- | --- |
| Integer | <Icon icon="material-outline-highlight_off"/> | <Icon icon="material-outline-done"/> |

Number of messages which have a delay during the sending phase.

### transmitted_count

| Type | Filterable | Can change? |
| --- | --- | --- |
| Integer| <Icon icon="material-outline-highlight_off"/> | <Icon icon="material-outline-done"/> |

Number of messages which were successfully sent.

### failed_count

| Type | Filterable | Can change? |
| --- | --- | --- |
| Integer | <Icon icon="material-outline-highlight_off"/> | <Icon icon="material-outline-done"/> |

Number of messages which failed to be sent.

### delivered_count

| Type | Filterable | Can change? |
| --- | --- | --- |
| Integer | <Icon icon="material-outline-highlight_off"/> | <Icon icon="material-outline-done"/> |

Number of messages which were successfully delivered to members.

### delivery_errored_count

| Type | Filterable | Can change? |
| --- | --- | --- |
| Integer | <Icon icon="material-outline-highlight_off"/> | <Icon icon="material-outline-done"/> |

Number of messages which encountered errors during delivery.

### clicked_count

| Type | Filterable | Can change? |
| --- | --- | --- |
| Integer | <Icon icon="material-outline-highlight_off"/> | <Icon icon="material-outline-done"/> |

Number of members which clicked on a link within the message.

Clicks made by bots are skipped.

### opened_count

| Type | Filterable | Can change? |
| --- | --- | --- |
| Integer | <Icon icon="material-outline-highlight_off"/> | <Icon icon="material-outline-done"/> |

Number of members which opened the message.

Opens made by bots are skipped.

### opened_events_count

| Type | Filterable | Can change? |
| --- | --- | --- |
| Integer | <Icon icon="material-outline-highlight_off"/> | <Icon icon="material-outline-done"/> |

Number of opening events.

### computed_counts

| Type | Filterable | Can change? |
| --- | --- | --- |
| Object | <Icon icon="material-outline-highlight_off"/> | <Icon icon="material-outline-done"/> |

Counts computed from bare counts for various business cases. It includes following metrics:

* sent - number of messages sent from the system
* failed_to_send - number of messages which failed during sending phase
* en_route - number of messages that are scheduled to be send but not yet reached the delivered or error state
* delivered - number of messages delivered to members
* errored - number of messages which failed during sending phase or failed during delivery
* open_rate - Open Rate percentage

### created_at

| Type | Filterable | Can change? |
| --- | --- | --- |
| String(`ISO 8601` timestamp) | <Icon icon="material-outline-highlight_off"/> | <Icon icon="material-outline-highlight_off"/> |

Time when given sending was created. Note that it’s not the same as time of sending.

### timeseries_time_ranges

| Type | Filterable | Can change? |
| --- | --- | --- |
| Object(dynamic) | <Icon icon="material-outline-highlight_off"/> | <Icon icon="material-outline-highlight_off"/> |

This field represents the time ranges when you can query related timeseries reports for events.

Example:

```json
"1h":{
    "from":"2025-04-11T08:00:00.000000Z",
    "to":null
},
"1d":{
    "from":"2025-04-11T00:00:00.000000Z",
    “to":null
 },
"1w":{
    "from":"2025-04-07T00:00:00.000000Z",
    "to":null
},
"1mo":{
    "from":"2025-04-01T00:00:00.000000Z",
    "to":null
}
```

## Query without aggregations

Query returns list of sendings.

```json
{
    "records": [
        {
           "id":452,
           "loyalty_club_id":275,
           "language":null,
           "channel":"push",
           "service_type":"rewards_notifications",
           "reporting_id":null,
           "source_id":null,
           "source_app":"messages_api",
           "source_type":"other",
           "audience_id":null,
           "campaign_id":null,
           "dispatches_count":67066,
           "members_count":8679,
           "new_count":909,
           "delivered_count":0,
           "delivery_errored_count":0,
           "failed_count":165,
           "opened_count":0,
           "opened_events_count":0,
           "transiently_failed_count":0,
           "transmitted_count":65992,
           "created_at":"2025-04-11T08:29:09.359381",
           "timeseries_time_ranges":{
              "1h":{
                 "from":"2025-04-11T08:00:00.000000Z",
                 "to":null
              },
              "1d":{
                 "from":"2025-04-11T00:00:00.000000Z",
                 "to":null
              },
              "1w":{
                 "from":"2025-04-07T00:00:00.000000Z",
                 "to":null
              },
              "1mo":{
                 "from":"2025-04-01T00:00:00.000000Z",
                 "to":null
              }
           }
        }
    ],
    "pagination": {
        "next_page_info": "CNOW-AE"
    },
    "result_type": "records"
}
```

## Aggregations

### reporting_id

Fetch sendings summary aggregated by reporting_id.

As a single "MPC sending" scheduled on UI can produce many "reporting sending" entities, this is helpful to gather all the "MPC sending" statistics in a single entity.

#### Returned fields

| Key | Type | Description |
| --- | --- | --- |
| reporting_id | Integer | See in `Fields` |
| service_type | String | See in `Fields` |
| ids | Array[Integer] | Internal sending IDs which are aggregated |
| dispatches_count | Integer | See in `Fields` |
| members_count | Integer | See in `Fields` |
| new_count | Integer | See in `Fields` |
| delivered_count | Integer | See in `Fields` |
| delivery_errored_count | Integer | See in `Fields` |
| failed_count | Integer | See in `Fields` |
| opened_count | Integer | See in `Fields` |
| opened_events_count | Integer | See in `Fields` |
| transiently_failed_count | Integer | See in `Fields` |
| transmitted_count | Integer | See in `Fields` |
| first_created_at | String(`ISO 8601` timestamp) | Time of first sending created_at |
| last_created_at | String(`ISO 8601` timestamp) | Time of last sending created_at |


#### Example query response

```json
{
    "records": [
        {
           "reporting_id":7265,
           "service_type":"campaigns",
           "ids":[
              40689
           ],
           "dispatches_count":73,
           "members_count":73,
           "new_count":0,
           "delivered_count":72,
           "delivery_errored_count":1,
           "failed_count":0,
           "opened_count":0,
           "opened_events_count":0,
           "transiently_failed_count":0,
           "transmitted_count":73,
           "first_created_at":"2025-08-06T09:00:31.423979",
           "last_created_at":"2025-08-06T09:00:31.423979",
           "timeseries_time_ranges":{
              "1h":{
                 "from":"2025-08-06T09:00:00.000000Z",
                 "to":"2025-08-08T09:00:31.423979Z"
              },
              "1d":{
                 "from":"2025-08-06T00:00:00.000000Z",
                 "to":"2025-08-08T09:00:31.423979Z"
              },
              "1w":{
                 "from":"2025-08-04T00:00:00.000000Z",
                 "to":"2025-08-08T09:00:31.423979Z"
              },
              "1mo":{
                 "from":"2025-08-01T00:00:00.000000Z",
                 "to":"2025-08-08T09:00:31.423979Z"
              }
           }
        }
    ],
    "pagination": {
        "next_page_info": "CNOW-AE"
    },
    "result_type": "records"
}
```

### campaign_id

Fetch sendings summary aggregated by campaign_id.

#### Returned fields

| Key | Type | Description |
| --- | --- | --- |
| campaign_id | Integer | See in `Fields` |
| service_type | String | See in `Fields` |
| ids | Array[Integer] | Internal sending IDs which are aggregated |
| dispatches_count | Integer | See in `Fields` |
| members_count | Integer | See in `Fields` |
| new_count | Integer | See in `Fields` |
| delivered_count | Integer | See in `Fields` |
| delivery_errored_count | Integer | See in `Fields` |
| failed_count | Integer | See in `Fields` |
| opened_count | Integer | See in `Fields` |
| opened_events_count | Integer | See in `Fields` |
| transiently_failed_count | Integer | See in `Fields` |
| transmitted_count | Integer | See in `Fields` |
| first_created_at | String(`ISO 8601` timestamp) | Time of first sending created_at |
| last_created_at | String(`ISO 8601` timestamp) | Time of last sending created_at |


#### Example query response

```json
{
    "records": [
        {
           "campaign_id":7265,
           "service_type":"campaigns",
           "ids":[
              40689
           ],
           "dispatches_count":73,
           "members_count":73,
           "new_count":0,
           "delivered_count":72,
           "delivery_errored_count":1,
           "failed_count":0,
           "opened_count":0,
           "opened_events_count":0,
           "transiently_failed_count":0,
           "transmitted_count":73,
           "first_created_at":"2025-08-06T09:00:31.423979",
           "last_created_at":"2025-08-06T09:00:31.423979",
           "timeseries_time_ranges":{
              "1h":{
                 "from":"2025-08-06T09:00:00.000000Z",
                 "to":"2025-08-08T09:00:31.423979Z"
              },
              "1d":{
                 "from":"2025-08-06T00:00:00.000000Z",
                 "to":"2025-08-08T09:00:31.423979Z"
              },
              "1w":{
                 "from":"2025-08-04T00:00:00.000000Z",
                 "to":"2025-08-08T09:00:31.423979Z"
              },
              "1mo":{
                 "from":"2025-08-01T00:00:00.000000Z",
                 "to":"2025-08-08T09:00:31.423979Z"
              }
           }
        }
    ],
    "pagination": {
        "next_page_info": "CNOW-AE"
    },
    "result_type": "records"
}
```
