diff --git a/docs/API/fliplet-datasources.md b/docs/API/fliplet-datasources.md index 5ef2bff1..fcd0695e 100644 --- a/docs/API/fliplet-datasources.md +++ b/docs/API/fliplet-datasources.md @@ -5,36 +5,40 @@ The Data Source JS APIs allows you to interact and make any sort of change to yo The `fliplet-datasources` package contains the following namespaces: -- [Data Sources](#data-sources) - - [Get the list of data sources for the current organization](#get-the-list-of-data-sources-for-the-current-organization) - - [Get the list of data sources in use by the current app](#get-the-list-of-data-sources-in-use-by-the-current-app) - - [Get a data source by ID](#get-a-data-source-by-id) - - [Create a new data source](#create-a-new-data-source) - - [Connect to a data source by ID](#connect-to-a-data-source-by-id) - - [Connect to a data source by Name](#connect-to-a-data-source-by-name) -- [Connection instance methods](#connection-instance-methods) - - [Fetch records from a data source](#fetch-records-from-a-data-source) - - [Fetch all records](#fetch-all-records) - - [Fetch records with a query](#fetch-records-with-a-query) - - [Filter the columns returned when finding records](#filter-the-columns-returned-when-finding-records) - - [Fetch records with pagination](#fetch-records-with-pagination) - - [Join data from other dataSources](#join-data-from-other-datasources) - - [Run aggregation queries](#run-aggregation-queries) - - [Find a specific record](#find-a-specific-record) - - [Find a record by its ID](#find-a-record-by-its-id) - - [Replace the contents of the data source with new records](#replace-the-contents-of-the-data-source-with-new-records) - - [Insert an array of new records into a data source](#insert-an-array-of-new-records-into-a-data-source) - - [Commit changes at once to a data source](#commit-changes-at-once-to-a-data-source) - - [Insert a single record into the data source](#insert-a-single-record-into-the-data-source) - - [Update a record (entry)](#update-a-record-entry) - - [Import a file into the data sources](#import-a-file-into-the-data-sources) - - [Remove a record by its ID](#remove-a-record-by-its-id) - - [Remove entries matching a query](#remove-entries-matching-a-query) - - [Get unique values for a column](#get-unique-values-for-a-column) - - [Get unique values for multiple columns at once](#get-unique-values-for-multiple-columns-at-once) -- [Define views to filter a data source](#define-views-to-filter-a-data-source) -- [Configurable operations](#configurable-operations) - - [Automatically generate a unique ID for your entries](#automatically-generate-a-unique-id-for-your-entries) +- [Data Sources JS APIs](#data-sources-js-apis) + - [Data Sources](#data-sources) + - [Get the list of data sources for the current organization](#get-the-list-of-data-sources-for-the-current-organization) + - [Get the list of data sources in use by the current app](#get-the-list-of-data-sources-in-use-by-the-current-app) + - [Get a data source by ID](#get-a-data-source-by-id) + - [Create a new data source](#create-a-new-data-source) + - [Connect to a data source by ID](#connect-to-a-data-source-by-id) + - [Connect to a data source by Name](#connect-to-a-data-source-by-name) + - [Connection instance methods](#connection-instance-methods) + - [Fetch records from a data source](#fetch-records-from-a-data-source) + - [Fetch all records](#fetch-all-records) + - [Fetch records with a query](#fetch-records-with-a-query) + - [Filter the columns returned when finding records](#filter-the-columns-returned-when-finding-records) + - [Fetch records with pagination](#fetch-records-with-pagination) + - [Join data from other dataSources](#join-data-from-other-datasources) + - [Run aggregation queries](#run-aggregation-queries) + - [Sort / order the results](#sort--order-the-results) + - [Find a specific record](#find-a-specific-record) + - [Find a record by its ID](#find-a-record-by-its-id) + - [Replace the contents of the data source with new records](#replace-the-contents-of-the-data-source-with-new-records) + - [Insert an array of new records into a data source](#insert-an-array-of-new-records-into-a-data-source) + - [Commit changes at once to a data source](#commit-changes-at-once-to-a-data-source) + - [Insert a single record into the data source](#insert-a-single-record-into-the-data-source) + - [**Options: folderId**](#options-folderid) + - [**Options: ack**](#options-ack) + - [Update a record (entry)](#update-a-record-entry) + - [Import a file into the data sources](#import-a-file-into-the-data-sources) + - [Remove a record by its ID](#remove-a-record-by-its-id) + - [Remove entries matching a query](#remove-entries-matching-a-query) + - [Get unique values for a column](#get-unique-values-for-a-column) + - [Get unique values for multiple columns at once](#get-unique-values-for-multiple-columns-at-once) + - [Define views to filter a data source](#define-views-to-filter-a-data-source) + - [Configurable operations](#configurable-operations) + - [Automatically generate a unique ID for your entries](#automatically-generate-a-unique-id-for-your-entries) --- @@ -113,6 +117,11 @@ Fliplet.DataSources.create({ Name: 'Jane Doe', Email: 'janedoe@example.com' } + ], + + // Optionally define access rules + accessRules: [ + { type: ['select', 'insert', 'update', 'delete'], allow: 'all' } ] }).then(function (dataSource) { // The data source has been created