List messages
Finds sent and received messages by sender, recipient, status or period.
Settings
| Setting | What it is |
|---|---|
| ConnectionRequired | The MessageBird connection the step signs in with. |
| Sender | Only messages sent from this sender id or number. |
| Phone number | Only messages to or from this number, in international format. |
| Direction | "any" or "mt" or "mo" |
| Type | "any" or "sms" or "binary" or "flash" |
| Status | "any" or "scheduled" or "sent" or "buffered" or "delivered" or "expired" or "delivery_failed" |
| Contact id | Only messages to or from this contact. The List contacts node gives the ids. |
| Text contains | Only messages whose text contains this. |
| From | The start of the period, in RFC 3339. |
| Until | The end of the period, in RFC 3339. |
| Messages per call | 1 to 100. MessageBird answers 20 by default. |
| Skip | How many messages to skip. Ignored when Fetch every page is on. |
| Fetch every page | Walks the offset from the start, and refuses past 5,000 messages rather than answering a short list. |
| Cursor | Paste a previous run's Next cursor to read the page after it. |
Technical details
| Key | Value |
|---|---|
connection | texta connection id from `requires.connections` (provider `messagebird`) |
originator | textits `{{ }}` must give a string |
recipient | textits `{{ }}` must give a string |
direction | "any" or "mt" or "mo", by default "any" |
type | "any" or "sms" or "binary" or "flash", by default "any" |
status | "any" or "scheduled" or "sent" or "buffered" or "delivered" or "expired" or "delivery_failed", by default "any" |
contactId | textits `{{ }}` must give a string |
searchterm | textits `{{ }}` must give a string |
from | textits `{{ }}` must give a string |
until | textits `{{ }}` must give a string |
limit | number, by default 20 |
offset | number, by default 0 |
returnAll | true/false, by default false |
cursor | text |
Output
| Field | Type |
|---|---|
messages | array |
messageCountMessages in this answer | number |
hasMoreMore messages are waiting behind this page | boolean |
totalCountMessages MessageBird has in total | number |
nextCursorCursor for the next page | string |
Sample output, and the expression for each field
- hasMorefalse
- messageCount0
- messages[]
- totalCount0
Errors
When a step of this node stops a run, the run page shows a code. Look it up:
Example step
The step as a flow file holds it. Replace each value in <…>.
{
"config": {
"connection": "<connection id>",
"contactId": "",
"cursor": "",
"direction": "any",
"from": "",
"limit": 20,
"offset": 0,
"originator": "",
"recipient": "",
"returnAll": false,
"searchterm": "",
"status": "any",
"type": "any",
"until": ""
},
"label": "List messages",
"type": "messagebird.listMessages",
"version": 2
}Older versions
A flow that already has this version keeps running it. A new step always gets the newest.
Version 1
| Setting | What it is |
|---|---|
| ConnectionRequired | The MessageBird connection the step signs in with. |
| Sender | Only messages sent from this sender id or number. |
| Phone number | Only messages to or from this number, in international format. |
| Direction | "any" or "mt" or "mo" |
| Type | "any" or "sms" or "binary" or "flash" |
| Status | "any" or "scheduled" or "sent" or "buffered" or "delivered" or "expired" or "delivery_failed" |
| Contact id | Only messages to or from this contact. The List contacts node gives the ids. |
| Text contains | Only messages whose text contains this. |
| From | The start of the period, in RFC 3339. |
| Until | The end of the period, in RFC 3339. |
| Messages per call | 1 to 100. MessageBird answers 20 by default. |
| Skip | How many messages to skip. Ignored when Fetch every page is on. |
| Fetch every page | Walks the offset from the start, and refuses past 5,000 messages rather than answering a short list. |
Technical details
| Key | Value |
|---|---|
connection | texta connection id from `requires.connections` (provider `messagebird`) |
originator | textits `{{ }}` must give a string |
recipient | textits `{{ }}` must give a string |
direction | "any" or "mt" or "mo", by default "any" |
type | "any" or "sms" or "binary" or "flash", by default "any" |
status | "any" or "scheduled" or "sent" or "buffered" or "delivered" or "expired" or "delivery_failed", by default "any" |
contactId | textits `{{ }}` must give a string |
searchterm | textits `{{ }}` must give a string |
from | textits `{{ }}` must give a string |
until | textits `{{ }}` must give a string |
limit | number, by default 20 |
offset | number, by default 0 |
returnAll | true/false, by default false |