diff --git a/README.md b/README.md index c58db6cb..8382a1be 100644 --- a/README.md +++ b/README.md @@ -45,7 +45,7 @@ See the [technical requirements](https://support.airtable.com/hc/en-us/articles/ There are three configurable options available: -* `apiKey` - set the token to your secret API token. Visit [your account page](https://airtable.com/account) to create an API token. (`AIRTABLE_API_KEY`) +* `apiKey` - your secret API token. Visit [/create/tokens](https://airtable.com/create/tokens) to create a personal access token. [OAuth access tokens](https://airtable.com/developers/web/guides/oauth-integrations) can also be used. * `endpointUrl` - the API endpoint to hit. You might want to override it if you are using an API proxy (e.g. runscope.net) to debug your API calls. (`AIRTABLE_ENDPOINT_URL`) * `requestTimeout` - the timeout in milliseconds for requests. The default is 5 minutes (`300000`) @@ -53,13 +53,13 @@ There are three configurable options available: You can set the options globally via `Airtable.configure`: ```js -Airtable.configure({ apiKey: 'YOUR_SECRET_API_KEY' }) +Airtable.configure({ apiKey: 'YOUR_SECRET_API_TOKEN' }) ``` Globally via process env (e.g. in 12factor setup). ```sh -export AIRTABLE_API_KEY=YOUR_SECRET_API_KEY +export AIRTABLE_API_KEY=YOUR_SECRET_API_TOKEN ``` You can also override the settings per connection: @@ -72,6 +72,8 @@ const airtable = new Airtable({endpointUrl: 'https://api-airtable-com-8hw7i1oz63 Go to https://airtable.com/api to see the interactive API documentation for your Airtable bases. Once you select a base, click the "JavaScript" tab to see code snippets using Airtable.js. It'll have examples for all operations you can perform against your base using this library. +You can also view non-interactive API documentation at https://airtable.com/developers/web/api + # Promises As of [v0.5.0](https://github.com/Airtable/airtable.js/releases/tag/v0.5.0) all of the methods that take a `done` callback will return a Promise if you don't pass in a `done` callback.