10 releases
0.1.9 | Mar 3, 2023 |
---|---|
0.1.8 | Feb 25, 2023 |
0.1.5 | Jan 30, 2023 |
#18 in #flows
41 downloads per month
9KB
115 lines
This is a library for integrating Airtable in your flow function for flows.network.
Usage example
use airtable_flows::create_record;
use slack_flows::{listen_to_channel};
#[no_mangle]
pub fn run() {
listen_to_channel("myworkspace", "mychannel", |sm| {
let record = serde_json::json!({
"Name": sm.text,
});
create_record("accountName", "mybaseId", "mytable", record);
});
}
When a new message is received from mychannel
, we will create a new record in the table mytable
of base mybaseId
using create_record
.
The whole document is here.
lib.rs
:
Airtable integration for Flows.network
Quick Start
To get started, let's write a very tiny flow function.
use airtable_flows::create_record;
use slack_flows::{listen_to_channel};
#[no_mangle]
pub fn run() {
listen_to_channel("myworkspace", "mychannel", |sm| {
let record = serde_json::json!({
"Name": sm.text,
});
create_record("accountName", "mybaseId", "mytable", record);
});
}
When the Slack message is received, create a new record in Airtable using [create_record].
Dependencies
~1–2MB
~42K SLoC