easy-airtable-api 0.0.10 → 0.0.11

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -60,6 +60,11 @@ const records = await getRecords<Fields>({
60
60
 
61
61
  ## Changelog
62
62
 
63
+ ### 0.0.11
64
+
65
+ - Make apiKey, baseId, tableId default to undefined #12
66
+ - Missing .js in utils import #13
67
+
63
68
  ### 0.0.10
64
69
 
65
70
  - Fixed deleteRecords implementation errors.
package/lib/requests.d.ts CHANGED
@@ -1,20 +1,20 @@
1
1
  import { AirtableRecord, DeleteRecordsResponse, GetRecordsQueryParameters } from './types/records';
2
2
  export declare function getRecord<Fields>({ apiKey, baseId, tableId, recordId, }: {
3
- apiKey: string;
4
- baseId: string;
5
- tableId: string;
3
+ apiKey?: string;
4
+ baseId?: string;
5
+ tableId?: string;
6
6
  recordId: string;
7
7
  }): Promise<AirtableRecord<Fields>>;
8
8
  export declare function getRecords<Fields>({ apiKey, baseId, tableId, options, }: {
9
- apiKey: string;
10
- baseId: string;
11
- tableId: string;
9
+ apiKey?: string;
10
+ baseId?: string;
11
+ tableId?: string;
12
12
  options?: GetRecordsQueryParameters;
13
13
  }): Promise<AirtableRecord<Fields>[]>;
14
14
  export declare function updateRecord<Fields>({ apiKey, baseId, tableId, recordId, fields, options, }: {
15
- apiKey: string;
16
- baseId: string;
17
- tableId: string;
15
+ apiKey?: string;
16
+ baseId?: string;
17
+ tableId?: string;
18
18
  recordId: string;
19
19
  fields: Fields;
20
20
  options?: {
@@ -24,9 +24,9 @@ export declare function updateRecord<Fields>({ apiKey, baseId, tableId, recordId
24
24
  };
25
25
  }): Promise<AirtableRecord<Fields>>;
26
26
  export declare function updateRecords<Fields>({ apiKey, baseId, tableId, records, options, }: {
27
- apiKey: string;
28
- baseId: string;
29
- tableId: string;
27
+ apiKey?: string;
28
+ baseId?: string;
29
+ tableId?: string;
30
30
  records: {
31
31
  id: string;
32
32
  fields: Fields;
@@ -40,9 +40,9 @@ export declare function updateRecords<Fields>({ apiKey, baseId, tableId, records
40
40
  records: AirtableRecord<Fields>[];
41
41
  }>;
42
42
  export declare function updateRecordsUpsert<Fields>({ apiKey, baseId, tableId, records, options, }: {
43
- apiKey: string;
44
- baseId: string;
45
- tableId: string;
43
+ apiKey?: string;
44
+ baseId?: string;
45
+ tableId?: string;
46
46
  records: {
47
47
  id?: string;
48
48
  fields: Fields;
@@ -59,8 +59,8 @@ export declare function updateRecordsUpsert<Fields>({ apiKey, baseId, tableId, r
59
59
  records: AirtableRecord<Fields>[];
60
60
  }>;
61
61
  export declare function deleteRecords({ apiKey, baseId, tableId, recordIds, }: {
62
- apiKey: string;
63
- baseId: string;
64
- tableId: string;
62
+ apiKey?: string;
63
+ baseId?: string;
64
+ tableId?: string;
65
65
  recordIds: string[];
66
66
  }): Promise<DeleteRecordsResponse>;
package/lib/requests.js CHANGED
@@ -1,6 +1,6 @@
1
1
  import { request } from 'https';
2
2
  import { URL } from 'url';
3
- import { delay } from './utils';
3
+ import { delay } from './utils.js';
4
4
  export async function getRecord({ apiKey, baseId, tableId, recordId, }) {
5
5
  return await airtableRequest({
6
6
  apiKey,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "easy-airtable-api",
3
- "version": "0.0.10",
3
+ "version": "0.0.11",
4
4
  "type": "module",
5
5
  "description": "An easy way to connect to Airtable via their API.",
6
6
  "main": "lib/index.js",