Skip to content

获取库的名称。

node base-name.mjs
// base-name.mjs

const TOKEN = 'teable_123456';
const BASE_ID = 'bse123456';

const url = 'https://app.teable.cn/api/base/' + BASE_ID;
const options = {method: 'GET', headers: {Authorization: 'Bearer ' + TOKEN}};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data.name);
} catch (error) {
  console.error(error);
}

联系 math@baima.site