Skip to main content

Metadata API for schema and mutating tables


Is there any plan for an API to pull metadata? It’s currently very difficult to infer the schema, you have to resort to hacks like reading all records and then trying to infer types and column names from that. It’d be great if you could pull the schema information for a table more easily!

It’d also be awesome if you’d be able to add and change tables from the API, but that’s less pressing to me :slightly_smiling_face:

40 replies

Forum|alt.badge.img+18
  • Inspiring
  • 366 replies
  • October 9, 2016

+1. Apparently they’re working on it… :slightly_smiling_face:

Note that the Standard API does not provide the ability to create or modify base schemas. For this type of behavior, you will need to use the Airtable Metadata API, which has not yet been released.


  • New Participant
  • 2 replies
  • March 30, 2017

Anyone have any idea whether the Metadata API is getting close… ?


Forum|alt.badge.img+18
  • Inspiring
  • 366 replies
  • March 30, 2017
mattlibera wrote:

Anyone have any idea whether the Metadata API is getting close… ?


As of last week: months…


  • New Participant
  • 2 replies
  • March 30, 2017

:disappointed:

Oh well. Guess I’ll stick with hard-coding for now… thx.


Forum|alt.badge.img+18
mattlibera wrote:

:disappointed:

Oh well. Guess I’ll stick with hard-coding for now… thx.


I found a half-way solution that will help in some use-cases while waiting for the metadata API.

Visit https://airtable.com/api and select a base. Then open your browsers console (Developer Tools) and run the following (I tried simply running JSON.stringify(window.application), however there are circular references so I had to manually reconstruct the properties I wanted).

var myapp = {
	id:window.application.id,
	name:window.application.name,
	tables:[]
};

for (let table of window.application.tables){

	var mytable = {
			id:table.id,
			isEmpty:table.isEmpty,
			name:table.name,
			nameForUrl:table.nameForUrl,
			primaryColumnName:table.primaryColumnName,
			columns:[]
	};

	for (let column of table.columns){
		var mycolumn = {
			id:column.id,
			name:column.name,
			type:column.type,
			typeOptions:column.typeOptions
		};

		mytable.columns.push(mycolumn);

	}

	myapp.tables.push(mytable);

}

jQuery('link[rel=stylesheet]').remove();
jQuery("body").html(JSON.stringify(myapp));
console.log(myapp);

  • New Participant
  • 3 replies
  • May 10, 2017

+1, getting the schema would be really great! Modifying the schema is far less important for our use-cases.


Forum|alt.badge.img+18
  • Inspiring
  • 366 replies
  • March 8, 2018
Tuur wrote:

+1. Apparently they’re working on it… :slightly_smiling_face:

Note that the Standard API does not provide the ability to create or modify base schemas. For this type of behavior, you will need to use the Airtable Metadata API, which has not yet been released.


Any news on this guys? Or are you keeping it exclusive to Zapier et al?


  • Participating Frequently
  • 5 replies
  • March 13, 2018

Similar to the @Chester_McLaughlin solution above I created a node script that launches a browser environment and downloads the schema to a json file. https://github.com/cape-io/airtable-schema


Forum|alt.badge.img+18
  • Inspiring
  • 366 replies
  • March 16, 2018
Kai_Curry wrote:

Similar to the @Chester_McLaughlin solution above I created a node script that launches a browser environment and downloads the schema to a json file. https://github.com/cape-io/airtable-schema


Unfortunately that’s not good enough for me.


I feel your hurt Tuur - between

  • the lack of a metadata API
  • the inability to list all bases accessible with a given API key (hmm Zapier can do it, why can’t we? What endpoint have they been granted access to that we haven’t?)
  • the inconsistent way that fields are returned (empty values are sometimes just missing, other times empty arrays)

developers will struggle to write useful, reusable tools. The silence on this front is frustrating. If a small % of the effort going into front end tools like Blocks was put into these small enhancements, the sky is the limit.


Forum|alt.badge.img+18
  • Inspiring
  • 366 replies
  • March 26, 2018
Hugh_Campbell wrote:

I feel your hurt Tuur - between

  • the lack of a metadata API
  • the inability to list all bases accessible with a given API key (hmm Zapier can do it, why can’t we? What endpoint have they been granted access to that we haven’t?)
  • the inconsistent way that fields are returned (empty values are sometimes just missing, other times empty arrays)

developers will struggle to write useful, reusable tools. The silence on this front is frustrating. If a small % of the effort going into front end tools like Blocks was put into these small enhancements, the sky is the limit.


I’m afraid the silence (and removing of old references) is telling…

They probably have other priorities.


  • New Participant
  • 1 reply
  • May 4, 2018

I’d love to see a Metadata API as well…


Why would it take so long? They use something automated to generate the table’s API documentation (I doubt there’s a poor intern building each table model for each table’s API docs…).

I’m sure all they’d have to do is expose it as an API endpoint that we can read.


  • New Participant
  • 2 replies
  • November 3, 2018

@Simon_Horup_Eskildse any chance we can do a similar schema hack for “view” meta data besides columns?


Forum|alt.badge.img+3
  • Participating Frequently
  • 7 replies
  • July 10, 2019

This is a blocker for me. Oh well, back to Google Sheets.


Hello, is there any official update on this? The blocks seems to be using a private API endpoint to fetch the data I want.

It would be cool if we could get access to the same API even if it’s released in Beta. At least we can build some proof-of-concept’s until a mature API is ready


  • New Participant
  • 3 replies
  • August 8, 2019

+1 for making metadata a first class citizen


Forum|alt.badge.img+19
  • Inspiring
  • 3264 replies
  • August 12, 2019

+1 and then some…

Schema…

If Airtable wants to see intelligent, non-brittle integrations emerge around their product, they will expand API access as soon as is practical. Forcing the developer community to script hard-coded solutions doesn’t allow us to create sustainable outcomes. This is bad for business.

Blocks…

It’s also not wise (in my opinion) for Airtable to create classes of API access that are denied to the general user community. It tends to stifle innovation. Ideally, we should all be able to define and register custom blocks using open web standards.


Forum|alt.badge.img+3
  • New Participant
  • 2 replies
  • October 15, 2019

+1 for this feature, the ability to create tables and modify table schemas would be enormously helpful in our use case. I’d be happy to pay extra for this too.


+1 Readable metadata as a minimum!


  • New Participant
  • 2 replies
  • January 9, 2020

This is a real bummer and would be very useful. Its 2020 now and still no response… frustrating


Forum|alt.badge.img+19
  • Inspiring
  • 3264 replies
  • January 9, 2020
Sean_Thompson wrote:

This is a real bummer and would be very useful. Its 2020 now and still no response… frustrating


Yep. A half-decade waiting. This is the equivalent of 35 Internet years; roughly half the lifetime of the product.

The request for a simple Split() function is also in the 5yr range. Unbelievable.


  • New Participant
  • 2 replies
  • January 9, 2020
Bill_French wrote:

+1 and then some…

Schema…

If Airtable wants to see intelligent, non-brittle integrations emerge around their product, they will expand API access as soon as is practical. Forcing the developer community to script hard-coded solutions doesn’t allow us to create sustainable outcomes. This is bad for business.

Blocks…

It’s also not wise (in my opinion) for Airtable to create classes of API access that are denied to the general user community. It tends to stifle innovation. Ideally, we should all be able to define and register custom blocks using open web standards.


100% this… I’m wanting to work on a big integration with Airtable into my existing application, but it’s way too hard without having Schema definitions… its like you said… brittle and unpredictable - if I don’t know what type of field I’m working with, I can’t make a good experience for our users.


  • New Participant
  • 1 reply
  • February 20, 2020

This is critical functionality and would make Airtable a much more powerful tool.


I was seeing? the codepen Airtable API Encoder, and I be reading the comments of this post, and i thinking that if is possible add more complex options to the codepen code for econde our Api to get more and best request? is for this that zapier can do other functions that we dont can?


Reply