Need development and API help? Ask your questions here!
Recently active
How can I change the Created by field code to tag the user when I have applied it to an Automation? Without the Automation the Created by field correctly shows the user's name, although when I apply an automation it says Created by Automation. Is there any alternative to this feature or is this inherent to the current application of the Created by field in Airtable?
Hi guys,I'm relatively new to scripting, so I've mostly used scripts I find in this amazing community and adapted them to my tables. Once such script I've tweaked to create junction tables. It automatically creates entries in a junction table when a linked record field is updated. It has been working pretty well for a 5-6 months now, then all of a sudden earlier today, it started giving the error:ERRORTypeError: Cannot read properties of null (reading '0')at main on line 38"Usually I can figure out what is going on and fix it, but this really has me stumped. I didn't touch the script today (I'm the only one who manages them). I took a snapshot of the base from this morning and the script works in that, so I tried to copy/paste the code from that to the live version, but it still didn't work. Which lead me to believe that has something to do with a change in the base, like a changed field or table name. So I thought, okay maybe someone accidentally changed a field name. Double chec
I want to get the available views/segment from Air table through Apiso please suggest me which plan will have this featureat this point i don't want to choose the enterprise plan
I want to help make my company better with scripts and extensions. However, I am not fluent with Github or Javascript.I am a quick learner. I think that there are some ideas that I have that could be accomplished through extensions and scripts. I am just wondering if anyone has some advice on how to get started? Maybe a beginning script or extensions I can build for AirTable that would be a proper introduction to it. I would love to create some functional buttons for my interface that link to scripts. Drew
Hi everyone! I’m happy to announce that we’ve released a new scripting API capability today, and this is available in both the Scripting App and the ‘Run a script’ Automation action. You can now select records by recordId, either by setting a new recordIds option when calling selectRecordsAsync or by using the new convenience method selectRecordAsync when you only need one record. This will be especially useful in Automations, where you can now easily select a Record based on a trigger or Find Records output. Examples: const recordIds = input.config().recordIds; const table = base.getTable('Team'); const recordsResult = await table.selectRecordsAsync({fields: table.fields, recordIds}); const records = recordsResult.records; for (const record of records) { console.log(`Record name: ${record.name}`); } and const recordId = input.config().recordId; const table = base.getTable('Team'); const record = await table.selectRecordAsync(recordId); if (record) { console.log(`Record name:
In the API definition for RecordQueryResult it says A RecordQueryResult represents a set of records. It’s a little bit like a one-off Airtable view: it contains a bunch of records, filtered to a useful subset of the records in the table. but in the API for Table there’s no way I see to filter when calling selectRecordsAsync(). Is there no way to query only a subset of rows in the table, i.e. the equivalent of a SQL WHERE clause? If so, what is the RecordQueryResult documentation referring to regarding ‘filtered to a useful subset’?
When sending an automation mail (using gmail or Airtable mail) how can I know if the mai was opened, resended, date opened etc Like in other email platforms like Mailchimp.
I have a multiple select field I am attempting to update within an automation, but I can’t seem to add an option to it without overwriting. Pared down, this is essentially what my code looks like right now: Val = record.getCellValue("The Cell") if(conditions met) { await table.updateRecordAsync(record.id, {"The Cell": [Val, {name: "NewVal"}]}); } And this isn’t working, as it says it can’t recognize this input type. I’ve also tried using getCellValueAsString and then passing that as another option, but that didn’t work either. Right now the code is working but is overwriting the cell value when it does, so I want to add this functionality where it doesn’t overwrite. Any help appreciated!
Hi!I'm trying to adjust the example todo-app by adding an input field when creating a new task.For example if I want to add a comment to a new task that should be created simultaneously. In my code below I get a form field to add the comment and the new task is added, but it loses the comment part somewhere on the way.Can someone help me and see where I've gone wrong?Thanks! function AddTaskForm({ table }) {const [taskName, setTaskName] = useState('');const [commentValue, setComment] = useState('');const commentField = table.getFieldByName('Comment');function onInputChange(event) {setTaskName(event.currentTarget.value);}function onCommentChange(event) {setComment(event.currentTarget.commentValue);}function onSubmit(event) {event.preventDefault();table.createRecordAsync({'Task': taskName },{'Comment': commentValue },);setTaskName('');}// check whether or not the user is allowed to create records with values in the primary field.// if not, disable the form.const isFormEna
Hi everyone, I used a very painfull and well known here workaround until now to update the listing of a (target) linked field depending on the selection of another linked field. But, I have a premium account and access to scripting. I wonder if it’s possible to alter a view of the target linked field with a filter based on a common field value (existing in both tables) (and maybe other things but for instance just this). I was thinking of it because we can restrict a linked field by a view. In summary, it needs: know what is the value in the first linked field get the value of the common field alter the view of the target field by filtering with the previous common field value So, is it doable with scripting ? Thanks a lot for your thoughts.
Anyone knows why this is happening in Chrome and if there is a fix? Currently using Safari for developing.
When I run block init I get the following error: Downloading template... done Extracting template... done Installing dependencies... Error › Warning: ❌ Something failed! Cleaning up... Error: Process exit with error 1 I’m using npm 8.3.1 and node v14.17.6 on Mac OS Monterey (12.5). The error doesn’t really say anything, so I’m unsure about how to continue from here. Has anyone encountered this?
Please is it possible to create a fresh base that will serve as our main client database that can sync with the marketing CRM the marketing team (GHL) uses. A very important component will be creating an internal facing and client facing dashboard for each client. There will be several components to this dashboard but among the most important is a calendar with milestones that when/if moved or changed the contingent dates change as well and the stakeholders are alerted. for example feb 1-4 is in the calendar as time allotted for "design sessions with a client" after those dates automatically there are other important milestones such as "construction document creation" which would be for example feb 6-8 and so on. if the user moves the date(s) then the subsequent dates move as well and the client and any other people (such as the designers) are notified. Please is this possible and who has an idea to go about it
When the data from the table is retrieved through the API, the field order (columns) don’t always come in in the same order that is in the view. For instance, if I have Column1, Column2, Coulmn3 in that order in the Airtable, it might come in with Column3 first, then Column1 second, and Column 2 last. I am using the standard code from the API page and this to display the results: const allRecords = records.map((record) => record.fields); console.log({ allRecords }); It appears that if I make a new table and make the fields it will work. But when the fields (columns) are modified, like change the order or delete columns or add some in, the order gets messed up.Specifying what fields to get doesn’t seem to help. I made a new table with three columns, put data in, it read it correctly. I added a 4th column, then moved it over between the 2nd and 4th columns and it still shows the original order I created the table in with the newly created column that I moved last. Can’t say I can
Can you help.I need to replace a linked field with a string - both in the same table. Here's my code: The problem is on line 23. If I run it as the following it works fine. However "YSW CC2" is a text field.23 await mainTable.updateRecordAsync(record, {"YSW CC2": returnValue If I run it as the following it comes up with the error below. "Contact Name " is a linked field.23 await mainTable.updateRecordAsync(record, {"Contact Name": returnValue If I try the format as suggested by @Karlstens "Updating record Linked Field with a string array" I still get the error.23 await mainTable.updateRecordAsync(record, {"Contact Name": [{id:'${returnvalue}'}] Can anyone help. I can't work out what I'm doing wrong. Much appreciated 🙂
Hello, anyone availeble to help with basic authentication for vidaxl api. I am trying to get products data but really struggling with the authentication // define the request urllet base_url = "https://b2b.vidaxl.com/someendpoint";let authUser = "some_email";let authPass = "some_pass";let authKey = authUser + authPasslet options = {"method": "GET","headers": {"Content-Type" : "application/json","Authorization" : "Basic " + authKey}}let items = await remoteFetchAsync(base_url, options)// let { data } = await items.json()console.log(items)
Hi,I have an Integromat scenario in which I am pulling three of the latest airtable records (sorted by created time, limited to 3), and I get the following output (success):Three bundles as expected, yet when I go to reference the data from these three bundles in a later module, I can only see the first. See here:How can I access the data from Bundles 2 & 3, if only data from Bundle 1 is shown?Thanks!
Hello, I’m looking to remove double line breaks in a rich text field (empty lines in the text). The substitute formula will make me lose the formatting. I tried the find and replace script to no avail. Could someone please help me ? Thanks a lot
Hello everybody,I have a table that's thousands of lines long, with a column called "Formula" which contains small string expressions like:amount = salary * 0.11;What I'm trying to do is run this string in my code, so that it updates the `amount` variable based on which line I select. However, I am running into an error when I try to run the string as code.This is my code, which is able to compile with the correct answer in other online compilers. However, when I run this in my automation script (specifically the line where I call `func()`) I receive TypeError: func is not a function.let code = "amount = salary * 0.11;";// Define the function with the desired argumentslet func = new Function('salary', code);// Call the function with the desired argument valuesfunc(50000);console.log(amount);I've tried using `eval()` to run this (I know it is not best practice) but similarly received the error ReferenceError: eval is not defined. There has to be some way to get this code
Hello,I have 4 columns setup. Date Opened - is a created time field, logs when an entry is createdTime Opened - is a formula field with the following: TONOW({Date Opened}) - Simply logs in minutes (will likely change to hours) how long an entry has been opened for.Done - Simple checkmark boxDate Closed - Is a formula Field with the following: IF(Done = 1, LAST_MODIFIED_TIME(Done)) - simply logs the time an entry is marked as Done with a checkmark.My current issue is, I'd like Time Opened to stop counting as soon as Done is checked and I cant quite figure out how to do this. Does anyone have any pointers?Thanks!
Hi,I'm working with the API, and when trying to create or update a SingleSelect field with a new select option, which was not exist, I get the following error:{"error":{"type":"INVALID_MULTIPLE_CHOICE_OPTIONS","message":"Insufficient permissions to create new select option \\"\\"v0.65.1\\"\\""}}%I set my personal API key with all of the available permission, i tried editing the field's permissions and set it with:* Allow this field to be set in records created through forms* Allow this field to be modified by automationsbut it didn't work.I didn't find anything useful in the API docs. Can anyone help?
Hello, I´m new using airtable.I´m developing a Labview-based software for reading information from airtable and writing information to airtable. I have no problem with reading from airtable. I´m using the functions in labview for inserting the headers with Authorization, then I encode the URL for retrieving the information I want, and use the Get function. This point has no problem.The problem is that I´m not being able to create a new record in the table. Basically, I´m following the same flow as before. I´m inserting the header with the Authorization, then I´m generating the URL with the Base ID and the Table name, then I´m using the function POST which has as inputs the URL and the data to send to the airtable.The data I´m sending is this one:{"fields":{"Test Number":67,"CH - Pass / Fail":"Pass"}} As answer I receive the following header:HTTP/1.1 422 Unprocessable EntityDate: Sat, 24 Dec 2022 10:32:17 GMTContent-Type: application/json; charset=utf-8Content-Length: 12
I'm working on an extension that will use iframes to load parts of the app. While iframes aren't forbidden by the extension guidelines, I'd like to get confirmation from a senior Airtable engineer before starting to work on this architecture -- it's going to be a considerable time and effort to build! I have a design doc I can share to give a full sense of how it will work. Does anyone know how I can reach someone at Airtable to review my design? Thanks.
I have no experience creating scripts and am looking for some assistance to create one for my base. I thought that I could just utilize automations to update records but I have had no luck getting those to work properly and after searching through this forum I believe a script is necessary to do what I need. I have a Daily Fieldwork form that our employees fill out each time they go to install, remove, or service some equipment. If they are installing something new they fill out the form for an "install" and it triggers an automation that successfully creates a new record in another table called "Seismographs/Instrumentation".If they fill out the Daily Fieldwork form for anything other than a new install, they select the equipment number or "JID" that is associated with the equipment that has already been entered into the "Seismographs/Instrumentation" table and they update the information associated with that JID. I cannot figure out how to have multiple fields updated from the D
Hello I am looking to create a custom Airtable Block that can track a list of tracking numbers in a column and return all of the shipments status in other mapped columns (Location, Destination, Last event, arrival date etc) I think the best way would be to create a custom block connected to the Shippo API, but I am open to suggestions. I am OK to host if needed. Please let me know how you would do this, your best price, and when can this be completed by. About Me: Hello! I am Sal, a big Airtable x Zoho fan. I am looking to develop a relationship with a developer to help me with automation set up in Airtable and Zoho — I often come up with ideas, and looking for someone to execute.
Already have an account? Login
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.