See the KeyQL Github repo for the spec and more examples: functions/contains.js These endpoints use the KeyQL query language to make queries. You can make calls to them via the lib-js frontend package, directly to the URL using fetch, or using whatever HTTP client you prefer. Like all Autocode sources, the endpoints and queries in this project are completely customizable –– everything is code that you can edit and test using the Autocode editor. Then, link your copy of the base to your project in Autocode and press Deploy! Next, create a copy of the sample base on your own Airtable account by clicking this link. To get started, click the Open in Autocode button above to fork this source and create your own project in Autocode. You can deploy your own working version of this project in just a few clicks! It uses the API from Autocode's Standard Library. This source contains example endpoints that query data from an Airtable base. We'll cover the general steps for this below.Published from airtable/airtable-query-examples A second way to filter records in a List records request is to use the sort parameter.The link above contains more details about how to pass the view parameter in a request. One way to sort records is to pass a view parameter in an API request containing the list records scope, yielding the records in the API response in the order that they appear in a specific table view.There are two different ways to sort records in API requests: If the filterByFormula parameter is combined with the view parameter, only records in that view that satisfy the formula will be returned.Any records that appear as 0, false, NaN,, or #Error! in the formula, then the output will not be included in the response.If the response does not filter for the expected records, we recommend double-checking the formula in the Airtable base first to ensure it is returning the expected values in the formula field of the records you were expecting would be filtered.In the test shown below, you can see that only ‘Cookies & Cream’ and ‘Cookie Dough’ were returned: You can now test the request in a tool like Postman. Now, let’s say we only want to return flavors with 5-star ratings using the filterByFormula parameter: Including a list records scope in an API request to this table without any parameters will return all the flavors. To help demonstrate this, let’s say you have a table of ice cream flavors: This formula will need to be included in the table of the base where the API call is being requested. When filtering an API response using the filterByFormula parameter, a valid formula must be used which will evaluate each record. An alternative way to filter records in a call containing a list records scope is to use the filterByFormula parameter which we will outline in more detail below. ![]() One way to filter records is to pass a view parameter in an API request containing the list records scope, yielding only the records as they appear in a specific table view. ![]() There are two different ways to filter records in API requests: Token-based access - In order to make API requests, you'll need to authenticate using one of the methods outlined here. ![]() Learn how to filter or sort the results of an API response.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |