Need development and API help? Ask your questions here!
Recently active
I can call my endpoint (with hardcode variable) it's successful in requesting ( got a response ), but when I try to use a variable, params from the record. It's stuck on the CORS problem, but I am not sure why,(both variables are the same, the difference is the one from the variable does not worked,and one from hardcode is worked)//if I used hardcode in data, it work fine.const requestApi = async (params) => { const myHeaders = new Headers(); myHeaders.append("api-key", "xxxxxxxxx"); myHeaders.append("Content-Type", "application/json"); try { const requestOptions = { method: "POST", headers: myHeaders, body: params, // JSON.stringify({ // "pid": "xxxxxx", // "firstName": "xxxxxx", // "lastName": "xxxxxxx", // "birthDay": "xxxxxx", // "laser": "xxxxxx" // }), }; const response = await remoteFetchAsync("https://xxxxxxxx", requestOptions); const result = await response.text(); console.log("Record updated successfully."); } catch (error) { conso
Hi,I am trying to run the following script based on my screenshots and I am getting an error “Your script exceeded the 512MB memory limit.”.What am I doing wrong and how can I fix this? Thanks!
Dead link!
I have a base that has a number of junction tables. For example a product links to a product assembly item that links to a product assembly with multible product assembly items which links to an estimate.Its very cumbersom to have to go through each of these tables and use the forms to add data to each indivdual table. I wanted to create a single form that lets a user select products and then creates all the related junction tables.I was wondering if anyone had any work arounds for being able to add data to multible tables from a form. Right now forms do not allow for record creation or buttons with scripts, making it hard to create a new junction table entry that relates to the record being created.The only work around I can see is to create a seperate dummy " input table" that has a number of records related to each ipnut action I would like. Instead of creating a record users would just be editing the record through an interface. There would then be a script button that
Here's a weird one. So I had am automation set up using the airtable "Slack: Send a message" action and it always worked great. I add the slack workspace account, authorize, then it shows a chanel list of all chans, I pick my chan in the workspace. Good. We created a completely new slack workspace since our product got split to another business and now I need to make this message get sent to the NEW Slack workspace. Simple. Go into the automation, remove the old Slack workspace integration, add the new one with the NEW slack URL and new user/pass, and then... wait... It is showing the OLD slack channel list from the old workspace. The channels are totally different so I must have made a mistake. I remove the "Slack: Send a message" action completely, then to Account -> Integrations section to remove the integration from my entire airtable profile. I notice that this integration DOES show the name of the NEW company, which isn't looking promising (since that means I did log into
Hi! very new to using Airtable. I am trying to find out if it’s possible to use Airtable to populate users profiles for a small 30 members community. I am trying to display name, title, image, etc.. or would I be better using something I am more familiar with like Supabase. any thoughts or advice would be appreciated. Steve
If you’re using a rollup field to summarize linked records with ARRAYJOIN(), the array’s order is determined by the order of the linked records. I created this script to automatically sort linked records in a cell. My use-case is to summarize interactions with companies. I sort by descending order to show the latest summary on top. Enjoy! // Set a trigger: when a record is updated -> watch the linked records field // Set an action: run a script // You should set the record ID of the triggering record as an input variable // Grab the triggering record's ID let inputConfig = input.config(); let recordID = inputConfig.recordID; let table = base.getTable("tableName"); // Load table let queryResult = await table.selectRecordsAsync(); // Get all records in the table let record = queryResult.getRecord(`${inputConfig.recordID}`) // Find the one with the ID from the input // Get the linked records array let linkedRecordsArray = record.getCellValue("linkedRecordsField"); // Sort the link
I'm creating a script between 2 tables: 'Engagements' and 'People'.Engagements is a list of event attendancePeople is a master list of peopleI have a script that, using the attendance sign up info (name, email), tries to find a matching person from the master list. (This step is part of a loop to go through each Engagement record.) let peopleTable = base.getTable('People'); // find a matching Person record let personQuery = await peopleTable.selectRecordsAsync({ fields: ['Person IDENTIFIER'] }); let foundNames = personQuery.records.filter((record) => { let name = record.getCellValue('Person IDENTIFIER'); return name == engagement.getCellValue('Person IDENTIFIER'); }); This works fine. Now I need to link all the 'foundNames' to that 'engagement' record. The linked field is called 'Person' in 'Engagements' table: let numPeople = foundNames.length; if (numPeople > 0) { await engageTable.updateRecordAsync(engagement, { 'Person': [{ id:
Hi Folks,I have come up with a workaround for not being able to filter on query within scripting automations. Since you can query on a view but views can't be adjusted via the API either we use a view that has a checkbox and then check the box through update records and uncheck when done. This is useful when you have a list of records from a linked field more than a dyanamic filter. It is also still best to filter the records that are returned to ensure they do meet your criteria but greatly reduces the number of records returned. First we use this async function to make the object for updates: async function setAutomationFlags(table, recordIds, flagValue) { const automationFlags = recordIds.map(recordId => ({ id: recordId.id, fields: { "Automations": flagValue } })); await updateRecordsInChunks(table, automationFlags); } updateRecordsInChunks is another function that takes an array and slices it: &
I'd like to build a field that returns the days until due if >0, or "Assign Due Date" if Nan, or "Passed Due" if <0.I am struggling to combine the IF statement with the following formula:DATETIME_DIFF({Deadline},TODAY(),'days')Any tips on how to accomplish this?
I'm developing a Block Extension. When I type block release I get"Error: Your Airtable API key is invalid. Please use block set-api-key to update it. Code: airtableApiWithInvalidApiKey"Since api keys are deprecated (I have deleted my key and can't create a new one) I have created a personal access token. But I can't get it to work with block release; running block set-api-key <my-personal-access-token> returns"Error: Invalid Airtable API key specified. Make sure you copied it correctly from airtable.com/account. Code: airtableApiKeyMalformed"How do I use my PAT with Blocks?
I am trying to updated a linked record via Siri Shortcuts. I keep on getting error “value is not an array of record ids” The update is done vie Get content of URL. Request Boyd JSON. I figured out the id of the record that I am trying to link to. I tried setting the fields text to the record ID but I still get an error.
I saw what looks like support for type script in airtables online IDE but I couldn't find any documentation on it. I'd like to get rid of some of these type errors that are populating my code.
Is there a way to get the list-of-values that are available for a single- or multi-select column?
When I change a status in my record I want to check my data entry. If this check fail I want to stamp a warning in a popup message or similar because I want that the user knows this. Somebody can help me? It was more simple in vb but I didnt find nothing about. Thanks
There's an Airtable that's been shared with my account (A) from account (B). I have a personal access token from account A.- The Airtable's restricted to account A's domain- The Airtable is password protectedIs it possible to use the API to fetch the records of the Airtable?I've tried this approach:const Airtable = require("airtable");const PERSONAL_ACCESS_TOKEN = "...";const baseId = "...";const tableName = "...";const base = new Airtable({ apiKey: PERSONAL_ACCESS_TOKEN }).base(baseId);base(tableName).select({}).eachPage(function page(records, fetchNextPage) {records.forEach(function (record) {console.log("Retrieved", record);});fetchNextPage();},function done(err) {if (err) {console.error(err);return;}console.log("Finished fetching records");});```and this approach:```const fetchAirtableData = async (baseId, tableName, personalAccessToken) => {const url = `https://api.airtable.com/v0/${baseId}/${tableName}`;try {const response = await fetch(url, {headers: {Authorization: `Bearer $
Hello, I was wondering how I update my fetch code in observable to use the personal access tokens? Here is the notebook: https://observablehq.com/@datagrazing/fermentation-jar and the code in question: Airtable = (await import("https://cdn.skypack.dev/airtable@0.11.1?min")).defaultfull_data = { data = { const base = new Airtable({ apiKey: API_KEY }).base(BASE); const records = await base("ratios").select({ view: "Grid view" }).all(); return records.map((d) => d.fields); }
Hello I am developing a browser extension. It does Airtable OAuth and then lets the user fetch tables and quickly add records directly from the browser.Yesterday it all worked well for me and today the Airtable API does not send the appropriate CORS headers."Access to fetch at 'https://airtable.com/oauth2/v1/token' from origin 'chrome-extension://bnpbihfpfplcakeplbgbmopmppdkgcdn' has been blocked by CORS policy: Response to preflight request doesn't pass access control check: No 'Access-Control-Allow-Origin' header is present on the requested resource. If an opaque response serves your needs, set the request's mode to 'no-cors' to fetch the resource with CORS disabled."It is indeed true that the preflight request does not have these Access Control headers.I tried the same request from cURL and it passes there and I get back the tokens just fine so it's clear this is an issue with CORS.Since CORS worked for me yesterday and does not work today I wonder if Airtable API blocked me? But it
I’ve been working on a custom Extension (App) using the “Getting started” guide. The Extension has been working fine, running on my localhost at https://localhost:9000. Today, the Extension in the Airtable UI started showing the following message: { "error": "FORBIDDEN", "message": "blockId mismatch. Make sure you are entering development for the correct block." } The error message is very clear, but I haven’t changed the blockId in the remote.json file. I’ve also tried restarting my local and reloading the UI, but this error persists. Somehow it seems like the blockId must have changed, but I’m not clear on how/why or where I would get the new blockId from. Any thoughts on how to fix? I’m assuming I could just create a new Extension, but I’d rather get to the root of the problem. Thanks in advance!
Hi, I've been testing Airtable to create a visual database system for skilled professionals in Nepal. While fetching data from Airtable API to my APP, I hardly get all data. Few of my data are missing. I have tested it using postman.
I have developed an extension with specific business logic that I would like to release to multiple bases at once. I do not want to publish this extension to the marketplace as it would not be relevant to those not working at my company. Has anyone found a good way to release an extension to multiple bases at once? Or to release an extension to all bases owned by an organization? Ideally anyone at my company could release the latest version of the extension to a base without much hassle.My current process is to follow https://airtable.com/developers/extensions/guides/run-in-multiple-bases to create the remote configuration files. Then I have a script that iterates through all of those and releases the current extension to that base. I could further automate the process if I was able to get the blockId without having to go to navigate to the base and retrieve that ID (reference post: https://community.airtable.com/t5/development-apis/how-to-get-the-block-id-fro
I am trying to connect with other application that asks me for my client_id, client_secret, api_token, and refresh_token.So far I have set my api_token, client_id and client_secret, but still struggling with creating the refresh_token. Where should I find it?
Hi, I'm working with the Airtable API, and am noticing that the "list records" API endpoint is returning linked records in "cell format V1", while the Webhooks API returns values in "cell format V2". Cell format V1 is an array of strings representing record ID of the linked record(s).["recXXX", "recXXY"]Cell format V2 is an array of objects representing the record ID and 'name' of the linked record(s).[ { "id": "recXXX", "name": "Linked Record A" }, { "id": "recXXY", "name": "Linked Record B" } ] In my case, I really want to see the "v2" format in a 'list records' API call. Is there an API endpoint that will return this, or is there one planned for the future?
I need to search records in multiple databases and if the search result is not empty then set a variable for that particular organization. I will then compose an email using non empty variables. Scan Airtable A base, if the output is not empty, set the variable Clinic A to results. Scan Airtable B base, if the output is not empty, set the variable Clinic B to results. Compose email that includes non empty variables: Hi John Smith, Please submit the following items: Clinic A variable (has value - not empty) [Clinic B variable is not included as the variable in the previous scenario was empty due to no search results) Can’t figure this one out as Integromat requires everything to go in a flow as I am using filters to filter in or out empty search results. But if search results for variable A are not passed then the rest of the flow does not happen.
Hi There, It seems that there is no way to call directly an external API to a record on Airtable. My goal is to be able to shorten URLs (using Bit.ly API) in my database. I was wondering if there is a way that scripts might be able to help? Here is Bit.ly API reference : https://dev.bitly.com/api-reference I appreciate any help on this subject. Thanks
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.