Need development and API help? Ask your questions here!
Recently active
What sort of code will allow me to read a .CSV table, and if LAST NAME, FIRST NAME, and DATE OF BIRTH columns in the .CSV file == the LAST, FIRST and DOB columns in my records, would trigger a check box in the last column? Very new at writing code. Example CSV file attached. Thank you!
I have slowly been developing a custom app that interfaces with several external APIs that supply additional data to airtable entries. I started out with the utility as an automation script - here I was able to use remoteFetchAsync() to avoid any CORS issues with my fetch calls. However, since moving to the custom app and React, I am having to go through the proxy at https://cors-anywhere.herokuapp.com/ to run my API calls (and avoid the CORS preflight errors). The issue is the proxy is only for development - I would like to either duplicate what it does myself or find a similar service that does the same thing. I am relatively new to JS and web development, so I am looking for a well documented solution that would be easy to implement in a few hours. Does anyone have any hints on where to look? Since Airtable has the server fetch functionality built in for scripts, is it also possible to use it in custom apps?
Hi there, I’m a developer who has been building some custom apps for a company over the last 6 months to help keep Airtable at the center of their operations and integrate various services and APIs right into their Airtable workflow. One of the most useful features has been using the Button field with an action of opening a custom app. This has allowed the team to trigger various actions right from a record in a view. Something that would be incredibly useful would be to get the field ID from the record action data that we get from the useRecordActionData hook. This way we could create multiple button fields within one table that perform different actions in one custom app. At the moment we are limited to one action per table because we cannot differentiate action data from two different buttons on the same table.
Hi! I am using a react front end with Airtable as my backend, Everything works fine and I am to create and list records, but when I run a .update, I get an error. In my console I get: Access to fetch at 'https://api.airtable.com/v0/appfGOrSlohKglsao/Users/?' from origin 'http://localhost:3000' has been blocked by CORS policy: Method PATCH is not allowed by Access-Control-Allow-Methods in preflight response. It seems to be that Airtable is not allowing PATCH requests specifically? I don’t think I need a proxy given everything else works just fine. Am I missing some configuration?
We are using airtable rest apis to manage our employee’s data. In the airtable support article, it was written that the airtable API has a rate limit of 5 requests per second per base. Here is the article link: Public REST API – Airtable Support. So if we upgrade to a pro or enterprise plan then can we get a more request limit on API? Or is there any other way to increase airtable API request limit? Thanks.
For the Python Community out there, I wanted to share airbase, an Asynchronous Airtable API Python Client I’ve made for python 3.7+. A lot of credit to gtalarico and the work he’s done with pyAirtable (previously airtable-python-wrapper) which greatly informed this API client. All suggestions and feedback are very welcomed, as well as any contributions. There is still work to be done in documentation, and helper functions. Here is the repo
Hey guys, I have a base with a few thousand customers in it. Each customer has their own record, which includes the time and date that the customer first made a purchase from my store. I’m looking to generate a list of unique (but memorable) referral codes for each customer in my base. To achieve this, I would ideally like to generate unique codes for each customer by conflating: The customers first name. The first letter of their surname. The running total occurrences of any given abbreviated name. (With 1) and 2) put together being the customer’s abbreviated name.) So, if your name was Bob Matthews, and you were the first Bob M that had ever made a purchase from my store, your unique code would be BobM_1. If you were the second Bob M to ever make a purchase, your code would be BobM_2, and so on. Example list of customers (sorted by when the customers first made a purchase.) Tim Smith > TimS_1 Kate Field > KateF_1 Tim Short > TimS_2 Ben Thomas > BenT_1 Richard Burton &g
Hi all, I had a URL field in AT called “Google maps link”. When I tried to set up a zap to create a google doc triggered by a new record in AT, Zapier didn’t find the field. Then I changed the field to single line and still, Zapier couldn’t find it. Finally, I created a formula field to create a direct copy of the field, and still Zapier is not finding it. I even deleted my original zap and started a new one, thinking maybe there was some issue with my original zap, but still, nothing. Any ideas?
I copied @Justin_Barrett’s script from the below post and modified it for my purpose: Automatically link record based on plain text or formula result Scripting app I would like to create a workaround for the issue that Linked Records are not available in Automations. I am collecting lots of URL inputs from colleagues via the web clipper. For a number of reasons I want to link the records to another table automatically, using a script. The idea would be to trigger the script using an Automation. In short: I want the title of the Calculated site to be copied into the linked record field Sites [how to link record] I feel like this should be fairly simpl… I’m inputting productName (formula field, text formatted) and recordID from the trigger. My tables are Departures with a linked field Product towards the table Products, where the primary field Product matches the productName input. let DepartureTable = base.getTable("Departures"); let ProductTable =
Just getting back into programming after a long pause. Is there an example script out there: Simple php loop and echo rows from table? Thank you!
I was wondering if it’s possible to add multiple filters in the Airtable API URL - I have figured out the way for one filter, but I am struggling to apply multiple filters. Here’s the URL I made, which has a single filter applied : api.airtable.com/v0/<BASE_ID>/<TABLE_NAME>?api_key=<API_KEY>&filterByFormula={City}="MUMBAI" The above URL works perfectly, but if I try to add another filter (using &), it shows errors. I am looking for a way to add these 3 filters : {City} = “MUMBAI” (field type = single line text) {Age} > 25 (field type = number) {Calculation} = “Ok” (field type = formula, result would be either “Ok” or “NA”) What is the recommended/correct way to add multiple filters? Your guidance would be very appreciated. Thanks!
Hey there community - I recently joined the Product team to lead Developer Relations! I get to work directly with the engineers building our developer tools, and advocate for things that this lovely community needs to succeed. Specifically, my role is to listen to, learn from, and contribute to this community on behalf of Airtable. I’m dedicated to making announcements about recent changes, popping into hot debates and discussions on this forum, and answering Airtable questions as they come along. From the outside looking in, this community has been thriving. I’m excited to get to know each of you. That being said, it wouldn’t be a valuable post without an announcement! We recently added the ability to write field descriptions and write description data when creating a field or table using the SDK. Field descriptions can now be edited and specified when creating a new field: Added field.updateDescriptionAsync (docs). Added optional description argument to table.createFieldAsync (docs)
$api_key = ‘[KEY GOES HERE]’; $base_id = ‘appPrp2UDQKyeozka’; // Base ID for entire scorecard machine $table_id = ‘tblhkGjHUAMbsLYDF’; // Table ID $view_id = ‘viwnABjCLiL9eAiip’; // View ID $scorecard_id = ‘recNQHVVwauXgaS3q’; $url = ‘https://api.airtable.com/v0/’ . $base_id . ‘/’. $table_id . ‘/?view=’.$view_id; //’&fields%5B%5D=Criteria&fields%5B%5D=Section%20Link’; $headers = array( 'Authorization: Bearer ’ . $api_key ); $ch = curl_init(); curl_setopt($ch, CURLOPT_HTTPGET, 1); curl_setopt($ch, CURLOPT_RETURNTRANSFER, true); curl_setopt($ch, CURLOPT_TIMEOUT, 10); curl_setopt($ch, CURLOPT_HTTPHEADER, $headers); curl_setopt($ch, CURLOPT_URL, $url); $entries = curl_exec($ch); curl_close($ch); $airtable_response = json_decode($entries, TRUE); This gives me a response with the items in this view. But they aren’t ordered by the order in the view? How can i fix this?
Hey folks, Seems when we use images from Airtable to render they bring in 10+ cookies with them see attached. Can someone from Airtable team explain why this is the case as this is breaking EU laws… –Artur
I run a kids club and do my database through airtable and would love to automate some updates after club each week. Want to have the “pts this week” column be multiplied by 10 and added to the existing value in the “total points” column. Want to increment the attendance column value by 1 if the “pts this week” column is not blank. Not sure I can swing this with a formula or an automated script run weekly. Zero scripting experience. I know how to do this through third party apps (Wayscipt, Pabbly, etc) but would like to learn here. Thought I’d ask for help and see where I end up as this probably is a very simple script.
Hi I have a price field that I auto import prices from and it comes out as “7 99” because that’s how this specific website shows the price. I want to use the find and replace script to replace the spaces " " with a period “.” however that doesn’t work. Idk code but should this fix be done in my data scraping or can airtable fix it.
The attachments get into my airtable, but… a) they only show as grey paper clips b) clicking on them gives a black screen with an error e.g. “Previews for this filetype are not available screenshot_20211001-083956_google (3).jpg - 315.2 KB” - so airtable KNOWS this is a jpg c) clicking on the “Download” button from that black page, correctly downloads the file - so airtable HAS the file.
Hey all, I have an Airtable set up former employees returning hardware to the company. It’s based on a form where they select whether they will drop-off their hardware in person or ship it to the building. I set up an automation where if they select drop-off, they select a day and time and an event is created on a shared Google calendar. I am working on another automation that adds a member of the IT team as an attendee on each event when they are assigned in Airtable, and it works perfectly for the drop-off records. However, I assign IT team members to all records, not just drop-offs, and when I assign out a non-drop-off ticket I get a ‘failed automation’ notice. Is there a way to tell Airtable to only update records that have ‘Drop-off’ selected, and not update for records with ‘Ship to HQ’ selected?
Hey! First time here. Guys, I need the Airtable API to return an array on this format: But the only way I could make it return was in 2 separated arrays, like this: Is there anyway to return it like the first image? Thanks in advance!
Hey there, I would love a bit of help with an issue I have been struggling with: I have large data set containing keywords / descriptive tags to describe/classify the designs on our webshop juniqe.com, they are stored on a table called Image Keywords in my base, whereas the designs they are related to are on a table called DESIGNS I wrote the script below to merge the duplicate entries in the keyword table, since these records hold much information other than the linked record to DESIGNS. I’d like to believe that the script does the following cycle through all the records and compare the current records main field to the others, using the field Name (EN) as comparison value (the keywords english translation) If a duplicate has been found, combine the linked records of both the instances the script has found, and write them back to the first instance Clear the linked record field of the second instance (the comparison record) and mark that record with a checkbox field called DUPE to in
Hello, first of all, the Airtable API documentation is great. That said, closely following the example code, i’m trying to understand how I might do something functional with the retrieve method. Here is the example I am given from the API docs for my table ‘Users’ base('Users').select({ // Selecting the first 3 records in Grid view: maxRecords: 3, view: "Grid view" }).eachPage(function page(records, fetchNextPage) { // This function (`page`) will get called for each page of records. records.forEach(function(record) { console.log('Retrieved', record.get('ID')); }); // To fetch the next page of records, call `fetchNextPage`. // If there are more records, `page` will get called again. // If there are no more records, `done` will get called. fetchNextPage(); }, function done(err) { if (err) { console.error(err); return; } }); What i’d like to do is wrap this example up in a function and return an array of all records. But I don’t see
Hi, Is it possible to return the Linked table children of a table from List Rest call? At the moment a list call seems to return an array of Id’s - is it possible to expand that to include the data from the linked table? The only solution I can see is to iterate through the array of ids and make a Retrieve a Record call for each id of the Linked Field… e.g. in Ingredient below it returns the an array with Id:recEehttf17ZzJYwq… Could that expand to include the fields from the linked table Ingredient? { “id”: “recxTeOfNbAhcTPYS”, “fields”: { “Id”: 1, “Ingredient”: [ “recEehttf17ZzJYwq” ], “Price”: 14.5, “Date”: “2017-04-01T11:44:00.000Z” }, “createdTime”: “2017-04-01T10:40:34.932Z” } Thanks, Andrew
I have developed a Custom App locally, which I am able to run in development mode using block run in my base, however, after running block release, the custom app is not available in the Custom Apps modal, and rather than showing the custom apps menu item, the menu items says Build a custom app, indicating that there are no available custom apps for the base. Is there anything obvious that I might be missing? The block release process seems to run successfully: building copying package.json file copying package-lock.json file installing node modules [npm] [npm] > core-js@2.6.12 postinstall /tmp/airtableBlocks/build/1632423151219/transpiled/user/node_modules/babel-runtime/node_modules/core-js [npm] > node -e "try{require('./postinstall')}catch(e){}" [npm] [npm] [npm] > ejs@2.7.4 postinstall /tmp/airtableBlocks/build/1632423151219/transpiled/user/node_modules/ejs [npm] > node ./postinstall.js [npm] [npm] [npm] > fsevents@1.2.13 install /tmp/airtableBlocks/build/163242
Hey there, Apps should be able to offer a similar pricing model to airtable’s, which is a workspace based pricing model that charges per workspace user. To all app developers, if you’d like support for this too, please like this post :pray: . The following apparently simple features are missing from the current apps sdk in order for us app developers to offer that: Add base.workspaceId to the base model. Without that, a lot of code will need to be developed by apps to try and “guess” and/or ask users if another base belongs to the same workspace and should be added to the same subscription. Add CollaboratorData.isWorkspaceCollaborator or base.workspaceCollaborators so we can enable billing features only for workspace collaborators. Since airtable charges only for collaborators with owner, create, edit and comment permissions, add CollaboratorData.permissionLevel to the collaborator model. Without that, apps will be able to charge per user only after first time app use, after
Trying to add indicated number of days to date via scripting. But the system gives an error. Anyone has any clues about what is wrong? Maybe the DATEADD function is available to formulas only and is not available for scripting? ReferenceError: DATEADD is not defined Code: let current_date = new Date(); let date_added = DATEADD(current_date, 7, 'days')
Already have an account? Login
No account yet? Create an account
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.