{"id":2384,"date":"2024-02-09T14:46:50","date_gmt":"2024-02-09T06:46:50","guid":{"rendered":"https:\/\/five.co\/?p=2384"},"modified":"2024-02-23T08:48:45","modified_gmt":"2024-02-23T00:48:45","slug":"connecting-to-the-filemaker-data-api-common-questions","status":"publish","type":"post","link":"https:\/\/preview-php85.dzine.org\/five\/blog\/connecting-to-the-filemaker-data-api-common-questions\/","title":{"rendered":"Connecting to the FileMaker Data API: How-To and Common Questions"},"content":{"rendered":"\n<p class=\"wp-block-paragraph\">In today&#8217;s article, we explain how to connect Five to the FileMaker Data API and address common questions about integrating FileMaker with Five. More specifically, we show how to use the FileMaker Data API as a data source in Five to build a web interface on top of it. <\/p>\n\n\n\n<p class=\"wp-block-paragraph\">This blog post focuses on a key feature of Five: the <strong>Connection Wizard<\/strong>. <\/p>\n\n\n\n<p class=\"wp-block-paragraph\">It functions similarly to the well-known Postman API management tool. By using the Connection Wizard, developers can connect Five to any RESTful API endpoint, seamlessly integrating an API as a data source into the Five development environment. <\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Once an API has been set up in Five as a data source, Five can be used to develop custom applications, including forms, charts, or reports on top of it. <\/p>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<div class=\"wp-block-rank-math-toc-block\" id=\"rank-math-toc\"><h2>Table of Contents<\/h2><nav><ul><li><a href=\"#1-how-do-i-connect-five-to-the-file-maker-data-api\">1. How Do I Connect Five to the FileMaker Data API? <\/a><ul><li><a href=\"#step-1-open-up-the-connection-wizard\">Step 1: Open Up the Connection Wizard<\/a><\/li><li><a href=\"#step-2-authorization-generating-a-bearer-token\">Step 2: Authorization: Generating a Bearer Token<\/a><\/li><li><a href=\"#step-3-read-list-mapping-setting-up-your-get-request\">Step 3: Read List Mapping: Setting Up Your GET Request<\/a><\/li><li><a href=\"#step-4-get-a-single-record-read-single-mapping\">Step 4: Get a Single Record: Read Single Mapping<\/a><\/li><li><a href=\"#step-5-create-single-setting-up-the-post-request\">Step 5: Create Single: Setting Up the POST Request<\/a><\/li><li><a href=\"#step-6-update-single-setting-up-the-put-request\">Step 6: Update Single: Setting Up the PUT Request<\/a><\/li><li><a href=\"#step-7-delete-single-setting-up-the-delete-request\">Step 7: Delete Single: Setting Up the DELETE Request<\/a><\/li><li><a href=\"#step-8-adding-your-api-as-a-data-source\">Step 8: Adding Your API as a Data Source<\/a><\/li><\/ul><\/li><li><a href=\"#expansion-how-to-build-an-app-on-the-file-maker-data-api\">Expansion: How to Build an App on the FileMaker Data API<\/a><\/li><li><a href=\"#common-questions-about-the-file-maker-data-api\">Common Questions About the FileMaker Data API<\/a><ul><li><a href=\"#1-my-bearer-token-expires-every-15-minutes-how-can-five-handle-this\">1. My Bearer Token Expires Every 15 Minutes. How Can Five Handle This?<\/a><\/li><li><a href=\"#2-how-can-i-use-my-api-in-my-applications\">2. How Can I Use My API In My Applications?<\/a><\/li><li><a href=\"#3-what-is-a-data-source-in-five\">3. What Is A Data Source in Five?<\/a><\/li><li><a href=\"#4-does-every-user-have-permission-to-write-back-to-my-api\">4. Does Every User Have Permission to Write Back to My API?<\/a><\/li><li><a href=\"#5-is-my-api-connection-a-live-connection-will-my-data-be-up-to-date-when-i-run-my-apps\">5. Is My API Connection a Live Connection? Will My Data Be Up to Date When I Run My Apps?<\/a><\/li><li><a href=\"#6-can-i-store-my-api-data-in-the-fives-my-sql-database\">6. Can I Store My API Data in the Five&#8217;s MySQL Database?<\/a><\/li><li><a href=\"#7-how-do-i-continue-from-here\">7. How Do I Continue From Here?<\/a><\/li><\/ul><\/li><li><a href=\"#get-your-app-online-for-us-29-99-per-month\">Get Your App Online For US$29.99 Per Month<\/a><\/li><\/ul><\/nav><\/div>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"1-how-do-i-connect-five-to-the-file-maker-data-api\">1. How Do I Connect Five to the FileMaker Data API? <\/h2>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"step-1-open-up-the-connection-wizard\">Step 1: Open Up the Connection Wizard<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">Inside Five, you can use your Filemaker Data API through the <strong>Connection Wizard<\/strong>.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">1.1. Open up Five, and create a new application.<br>1.2. Click on the blue <strong>Manage <\/strong>button<br>1.3. Now, click on <strong>Data <\/strong>and then <strong>Connection Wizard.<\/strong><\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img width=\"1024\" height=\"190\" src=\"https:\/\/preview-php85.dzine.org\/five\/wp-content\/uploads\/2024\/02\/image-57-1024x190.png\" alt=\"\" class=\"wp-image-2459\" srcset=\"https:\/\/preview-php85.dzine.org\/five\/wp-content\/uploads\/2024\/02\/image-57-1024x190.png 1024w, https:\/\/preview-php85.dzine.org\/five\/wp-content\/uploads\/2024\/02\/image-57-300x56.png 300w, https:\/\/preview-php85.dzine.org\/five\/wp-content\/uploads\/2024\/02\/image-57-768x143.png 768w, https:\/\/preview-php85.dzine.org\/five\/wp-content\/uploads\/2024\/02\/image-57-1536x285.png 1536w, https:\/\/preview-php85.dzine.org\/five\/wp-content\/uploads\/2024\/02\/image-57.png 1600w\" sizes=\"(max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<p class=\"wp-block-paragraph\">Here&#8217;s what the Connection Wizards looks like: <\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img width=\"1024\" height=\"530\" src=\"https:\/\/preview-php85.dzine.org\/five\/wp-content\/uploads\/2024\/02\/image-19-1024x530.png\" alt=\"\" class=\"wp-image-2393\" srcset=\"https:\/\/preview-php85.dzine.org\/five\/wp-content\/uploads\/2024\/02\/image-19-1024x530.png 1024w, https:\/\/preview-php85.dzine.org\/five\/wp-content\/uploads\/2024\/02\/image-19-300x155.png 300w, https:\/\/preview-php85.dzine.org\/five\/wp-content\/uploads\/2024\/02\/image-19-768x397.png 768w, https:\/\/preview-php85.dzine.org\/five\/wp-content\/uploads\/2024\/02\/image-19-1536x794.png 1536w, https:\/\/preview-php85.dzine.org\/five\/wp-content\/uploads\/2024\/02\/image-19.png 1914w\" sizes=\"(max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<p class=\"wp-block-paragraph\">The <strong>Connection Wizard<\/strong> works similarly to Postman. It requires your endpoints for the FileMaker Data API. <\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Once you have the <strong>Connection Wizard<\/strong> open, you\u2019ll notice several tabs at the top:<\/p>\n\n\n\n<ol class=\"wp-block-list\">\n<li><strong>General<\/strong>: This is where you give your API connection a name, for example.<\/li>\n\n\n\n<li><strong>Read List Mapping:<\/strong> This requires an endpoint that returns <em>all <\/em>records from the API using a GET method.<\/li>\n\n\n\n<li><strong>Read Single Mapping:<\/strong> This requires an endpoint that provides a <em>single <\/em>record.<\/li>\n\n\n\n<li><strong>Create Single:<\/strong> This requires an endpoint that can be used to add a new record using a POST request. <\/li>\n\n\n\n<li><strong>Update Single:<\/strong> This is for an endpoint where you can use a PUT or PATCH method to update an existing record.<\/li>\n\n\n\n<li><strong>Delete Single:<\/strong> This tab expects an endpoint that, through a DELETE request, allows you to remove a record from the API.<\/li>\n<\/ol>\n\n\n\n<p class=\"wp-block-paragraph\">For each of these endpoints, you will need to set their authentication separately. <\/p>\n\n\n\n<p class=\"wp-block-paragraph\">In the next steps, we will walk you through the process of setting up your FileMaker Data API for use in Five.<\/p>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"step-2-authorization-generating-a-bearer-token\">Step 2: Authorization: Generating a Bearer Token<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">We first need to authorize our access to the FileMaker Data API. To do so, have your Basic Auth username and password ready. This can be configured inside of FileMaker. With your username and password ready, follow these steps inside Five to set up your API:<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">2.1. Inside the <strong>Connection Wizard,<\/strong> click on <strong>Read List Mapping.<\/strong> We skip the <strong>General<\/strong> section for now and come back to it later.<br>2.2. Change the dropdown box that says <strong>GET<\/strong> to <strong>POST.<\/strong><br>2.3. Paste the URL to create a token for your layout in the empty text field. Usually, in FileMaker, the URL looks similar to this:<\/p>\n\n\n\n<p class=\"has-text-align-center wp-block-paragraph\"><code>https:\/\/MyFileMakerServer\/fmi\/data\/vLatest\/databases\/[FileName].fmp12\/sessions<\/code><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">2.4. Next, click on <strong>Authorization <\/strong>and select <strong>Basic Auth. <\/strong>Fill in your username and password which you have created in FileMaker. <br>2.5. Now, click on send to generate a bearer token. <\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Check out the image below to better understand what your screen should look like before clicking <strong>Send.<\/strong><\/p>\n\n\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter size-large\"><img width=\"1024\" height=\"650\" src=\"https:\/\/preview-php85.dzine.org\/five\/wp-content\/uploads\/2024\/02\/Five.Co-FileMaker-Data-API-Generate-a-Token-1024x650.png\" alt=\"\" class=\"wp-image-2458\" srcset=\"https:\/\/preview-php85.dzine.org\/five\/wp-content\/uploads\/2024\/02\/Five.Co-FileMaker-Data-API-Generate-a-Token-1024x650.png 1024w, https:\/\/preview-php85.dzine.org\/five\/wp-content\/uploads\/2024\/02\/Five.Co-FileMaker-Data-API-Generate-a-Token-300x190.png 300w, https:\/\/preview-php85.dzine.org\/five\/wp-content\/uploads\/2024\/02\/Five.Co-FileMaker-Data-API-Generate-a-Token-768x487.png 768w, https:\/\/preview-php85.dzine.org\/five\/wp-content\/uploads\/2024\/02\/Five.Co-FileMaker-Data-API-Generate-a-Token-1536x974.png 1536w, https:\/\/preview-php85.dzine.org\/five\/wp-content\/uploads\/2024\/02\/Five.Co-FileMaker-Data-API-Generate-a-Token-2048x1299.png 2048w\" sizes=\"(max-width: 1024px) 100vw, 1024px\" \/><figcaption class=\"wp-element-caption\"><em>Image 2.1: How to generate a token in Five<\/em><\/figcaption><\/figure>\n<\/div>\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<p class=\"wp-block-paragraph\">Once you click on <strong>Send<\/strong>, here is what the expected response should look like. This response will be shown right inside of Five. <\/p>\n\n\n\n<div class=\"wp-block-kevinbatdorf-code-block-pro\" data-code-block-pro-font-family=\"Code-Pro-JetBrains-Mono\" style=\"font-size:.875rem;font-family:Code-Pro-JetBrains-Mono,ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;line-height:1.25rem;--cbp-tab-width:2;tab-size:var(--cbp-tab-width, 2)\"><span style=\"display:block;padding:16px 0 0 16px;margin-bottom:-1px;width:100%;text-align:left;background-color:#282c34\"><svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"54\" height=\"14\" viewBox=\"0 0 54 14\"><g fill=\"none\" fill-rule=\"evenodd\" transform=\"translate(1 1)\"><circle cx=\"6\" cy=\"6\" r=\"6\" fill=\"#FF5F56\" stroke=\"#E0443E\" stroke-width=\".5\"><\/circle><circle cx=\"26\" cy=\"6\" r=\"6\" fill=\"#FFBD2E\" stroke=\"#DEA123\" stroke-width=\".5\"><\/circle><circle cx=\"46\" cy=\"6\" r=\"6\" fill=\"#27C93F\" stroke=\"#1AAB29\" stroke-width=\".5\"><\/circle><\/g><\/svg><\/span><span role=\"button\" tabindex=\"0\" data-code=\"&quot;response&quot;:{1 item\n&quot;token&quot;:&quot;e96077f0f5f56a8a55f28a3788858cfcd7ad1298af137a3a80b5&quot;\n}\n&quot;messages&quot;:[1 item\n0:{2 items\n&quot;code&quot;:&quot;0&quot;\n&quot;message&quot;:&quot;OK&quot;\n}\n]\n}\" style=\"color:#abb2bf;display:none\" aria-label=\"Copy\" class=\"code-block-pro-copy-button\"><svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" style=\"width:24px;height:24px\" fill=\"none\" viewBox=\"0 0 24 24\" stroke=\"currentColor\" stroke-width=\"2\"><path class=\"with-check\" stroke-linecap=\"round\" stroke-linejoin=\"round\" d=\"M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4\"><\/path><path class=\"without-check\" stroke-linecap=\"round\" stroke-linejoin=\"round\" d=\"M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2\"><\/path><\/svg><\/span><pre class=\"shiki one-dark-pro\" style=\"background-color: #282c34\" tabindex=\"0\"><code><span class=\"line\"><span style=\"color: #98C379\">&quot;response&quot;<\/span><span style=\"color: #ABB2BF\">:{<\/span><span style=\"color: #FFFFFF\">1<\/span><span style=\"color: #ABB2BF\"> <\/span><span style=\"color: #FFFFFF\">item<\/span><\/span>\n<span class=\"line\"><span style=\"color: #E06C75\">&quot;token&quot;<\/span><span style=\"color: #ABB2BF\">:<\/span><span style=\"color: #98C379\">&quot;e96077f0f5f56a8a55f28a3788858cfcd7ad1298af137a3a80b5&quot;<\/span><\/span>\n<span class=\"line\"><span style=\"color: #ABB2BF\">}<\/span><\/span>\n<span class=\"line\"><span style=\"color: #98C379\">&quot;messages&quot;<\/span><span style=\"color: #ABB2BF\">:[<\/span><span style=\"color: #D19A66\">1<\/span><span style=\"color: #ABB2BF\"> <\/span><span style=\"color: #FFFFFF\">item<\/span><\/span>\n<span class=\"line\"><span style=\"color: #D19A66\">0<\/span><span style=\"color: #FFFFFF\">:<\/span><span style=\"color: #ABB2BF\">{<\/span><span style=\"color: #FFFFFF\">2<\/span><span style=\"color: #ABB2BF\"> <\/span><span style=\"color: #FFFFFF\">items<\/span><\/span>\n<span class=\"line\"><span style=\"color: #E06C75\">&quot;code&quot;<\/span><span style=\"color: #ABB2BF\">:<\/span><span style=\"color: #98C379\">&quot;0&quot;<\/span><\/span>\n<span class=\"line\"><span style=\"color: #98C379\">&quot;message&quot;<\/span><span style=\"color: #FFFFFF\">:<\/span><span style=\"color: #98C379\">&quot;OK&quot;<\/span><\/span>\n<span class=\"line\"><span style=\"color: #ABB2BF\">}<\/span><\/span>\n<span class=\"line\"><span style=\"color: #ABB2BF\">]<\/span><\/span>\n<span class=\"line\"><span style=\"color: #ABB2BF\">}<\/span><\/span><\/code><\/pre><\/div>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<p class=\"wp-block-paragraph\">If you receive an error, ensure that your <strong>request type (POST)<\/strong>, <strong>URL, <\/strong>and <strong>basic authentication<\/strong> (username and password) are correct. <\/p>\n\n\n\n<p class=\"wp-block-paragraph\">2.6. Copy the token.<br>2.7. Now, click on <strong>Bearer Token<\/strong>, which is right next to <strong>Basic Auth.<\/strong><br>2.8. Paste the token into the <strong>Token<\/strong> box.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Here is what your screen should look like:<\/p>\n\n\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter size-large\"><img width=\"1024\" height=\"544\" src=\"https:\/\/preview-php85.dzine.org\/five\/wp-content\/uploads\/2024\/02\/image-58-1024x544.png\" alt=\"\" class=\"wp-image-2460\" srcset=\"https:\/\/preview-php85.dzine.org\/five\/wp-content\/uploads\/2024\/02\/image-58-1024x544.png 1024w, https:\/\/preview-php85.dzine.org\/five\/wp-content\/uploads\/2024\/02\/image-58-300x159.png 300w, https:\/\/preview-php85.dzine.org\/five\/wp-content\/uploads\/2024\/02\/image-58-768x408.png 768w, https:\/\/preview-php85.dzine.org\/five\/wp-content\/uploads\/2024\/02\/image-58-1536x816.png 1536w, https:\/\/preview-php85.dzine.org\/five\/wp-content\/uploads\/2024\/02\/image-58.png 2000w\" sizes=\"(max-width: 1024px) 100vw, 1024px\" \/><figcaption class=\"wp-element-caption\"><em>Image 2.2: After generating a bearer token, paste it into the <strong>Token <\/strong>field.<\/em><\/figcaption><\/figure>\n<\/div>\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"step-3-read-list-mapping-setting-up-your-get-request\">Step 3: Read List Mapping: Setting Up Your GET Request<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">We will keep working on the same screen we were just on, i.e. we are continuing in <strong>Read List Mapping with the bearer token filled into the token field.<\/strong><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">3.1. Start by changing the dropdown box that says <strong>POST <\/strong>to <strong>GET.<\/strong><br>3.2. Replace the token-generating URL with your GET endpoint. Usually, in FileMaker, the GET URL looks similar to this:<\/p>\n\n\n\n<p class=\"has-text-align-center wp-block-paragraph\"><code>https:\/\/MyFileMakerServer\/fmi\/data\/vLatest\/databases\/[FileName].fmp12\/layouts\/[LayoutName]\/records<\/code><\/p>\n\n\n\n<p class=\"has-black-color has-text-color has-link-color wp-elements-c707d84ae73dc5e5e57f0954f70b529e wp-block-paragraph\">3.3. Click on <strong>Send<\/strong>. The response now contains a list of all records from your layout in JSON format.<br>3.4. Next, click on <strong>Field Mapping. <\/strong>Field Mapping shows you how Five understands the data it receives: it maps the fields from your API to field IDs. Make sure you are happy with each field&#8217;s data type and display type. <br>3.5. Inside <strong>Field Mapping<\/strong>, tick the <strong>Primary Key <\/strong>box for the field that contains your primary key. In FileMaker, this field is usually called recordId.  Note: You need to set the Primary Key for any tab that handles a GET request. <\/p>\n\n\n\n<p class=\"has-black-color has-text-color has-link-color wp-elements-29eb4afd92300b230628ac1519868ee6 wp-block-paragraph\">We have now successfully set up our first endpoint, the GET endpoint and we have checked our field mapping. Onto the next endpoint! <\/p>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"step-4-get-a-single-record-read-single-mapping\">Step 4: Get a Single Record: Read Single Mapping<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">We now continue by setting up the next endpoint: Read Single Mapping. <\/p>\n\n\n\n<p class=\"wp-block-paragraph\">4.1. Click on <strong>Read Single Mapping.<\/strong><br>4.2. Paste the URL of your read-single endpoint into the empty field next to <strong>GET.<\/strong> Usually, in FileMaker, the URL looks similar to this:<\/p>\n\n\n\n<p class=\"has-text-align-center wp-block-paragraph\"><code>https:\/\/MyFileMakerServer\/fmi\/data\/vLatest\/databases\/[FileName].fmp12\/layouts\/[LayoutName]\/records\/:recordId<\/code><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Now, test whether the endpoint works as expected. It supposed to return a single record from your API.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">4.3. Inside <strong>Read Single Mapping, <\/strong>click on <strong>Authorization <\/strong>and then on <strong>Bearer Token. <\/strong>Paste the token you have generated in step 1.5. above.<br>4.4. Now click on <strong>Params<\/strong>.<br>4.5. Inside the <strong>Value <\/strong>field, fill in any integer, such as <strong>1<\/strong>. This will return the first record.<br>4.6. Click on <strong>Send<\/strong>. <\/p>\n\n\n\n<p class=\"wp-block-paragraph\">You should now be able to see your first record (recordId = 1) of your API.<\/p>\n\n\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter size-large is-resized\"><img width=\"1024\" height=\"649\" src=\"https:\/\/preview-php85.dzine.org\/five\/wp-content\/uploads\/2024\/02\/Five.Co-FileMaker-Data-API-Read-Single-Mapping-1024x649.png\" alt=\"\" class=\"wp-image-2463\" style=\"width:840px;height:auto\" srcset=\"https:\/\/preview-php85.dzine.org\/five\/wp-content\/uploads\/2024\/02\/Five.Co-FileMaker-Data-API-Read-Single-Mapping-1024x649.png 1024w, https:\/\/preview-php85.dzine.org\/five\/wp-content\/uploads\/2024\/02\/Five.Co-FileMaker-Data-API-Read-Single-Mapping-300x190.png 300w, https:\/\/preview-php85.dzine.org\/five\/wp-content\/uploads\/2024\/02\/Five.Co-FileMaker-Data-API-Read-Single-Mapping-768x487.png 768w, https:\/\/preview-php85.dzine.org\/five\/wp-content\/uploads\/2024\/02\/Five.Co-FileMaker-Data-API-Read-Single-Mapping-1536x973.png 1536w, https:\/\/preview-php85.dzine.org\/five\/wp-content\/uploads\/2024\/02\/Five.Co-FileMaker-Data-API-Read-Single-Mapping-2048x1298.png 2048w\" sizes=\"(max-width: 1024px) 100vw, 1024px\" \/><figcaption class=\"wp-element-caption\"><em>Image 4.1.: Setting up and testing the <strong>Read Single Mapping<\/strong> connection<\/em><\/figcaption><\/figure>\n<\/div>\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"step-5-create-single-setting-up-the-post-request\">Step 5: Create Single: Setting Up the POST Request<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">We now continue by setting up the next endpoint: Create Single. <\/p>\n\n\n\n<p class=\"wp-block-paragraph\">5.1. Click on <strong>Create Single.<\/strong><br>5.2. Paste the URL of your POST endpoint into the empty field next to <strong>POST.<\/strong> Usually, in FileMaker, the URL looks similar to this:<\/p>\n\n\n\n<p class=\"has-text-align-center wp-block-paragraph\"><code>https:\/\/MyFileMakerServer\/fmi\/data\/vLatest\/databases\/[FileName].fmp12\/layouts\/[LayoutName]\/<\/code><\/p>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"step-6-update-single-setting-up-the-put-request\">Step 6: Update Single: Setting Up the PUT Request<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">We now continue by setting up the next endpoint: Create Single. <\/p>\n\n\n\n<p class=\"wp-block-paragraph\">6.1. Click on <strong>Update Single.<\/strong><br>6.2. Paste the URL of your PUT endpoint into the empty field next to <strong>PUT.<\/strong> Usually, in FileMaker, the URL looks similar to this:<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><code>https:\/\/MyFileMakerServer\/fmi\/data\/vLatest\/databases\/[FileName].fmp12\/layouts\/[LayoutName]\/<span style=\"background-color: initial; font-family: inherit; font-size: inherit; color: initial;\">records\/:record<\/span>Id<\/code><\/p>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"step-7-delete-single-setting-up-the-delete-request\">Step 7: Delete Single: Setting Up the DELETE Request<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">We now continue by setting up the next endpoint: Delete Single. <\/p>\n\n\n\n<p class=\"wp-block-paragraph\">7.1. Click on <strong>Delete Single.<\/strong><br>7.2. Paste the URL of your PUT endpoint into the empty field next to <strong>DELETE endpoint.<\/strong> Usually, in FileMaker, the URL looks similar to this:<\/p>\n\n\n\n<p class=\"has-text-align-center wp-block-paragraph\"><code>https:\/\/MyFileMakerServer\/fmi\/data\/vLatest\/databases\/[FileName].fmp12\/layouts\/[LayoutName]\/records\/:recordId<\/code><\/p>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"step-8-adding-your-api-as-a-data-source\">Step 8: Adding Your API as a Data Source<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">8.1. Now, click on <strong>General.<\/strong><br>8.2. Select <strong>New <\/strong>from the <strong>WebService <\/strong>dropdown.<br>8.3. Give your WebService a <strong>WebService ID<\/strong> and <strong>Name<\/strong>.<br>8.4. Select <strong>Basic<\/strong> from<strong> Authentication Type.<\/strong><br>8.5. Fill in your <strong>username <\/strong>and <strong>password<\/strong>, which you have defined for your FileMaker Data API.<br>8.6. Fill in the <strong>Token Endpoint <\/strong>from Step 1.3. above.<br>8.7. For <strong>Token Path, <\/strong>fill in &#8220;response&#8221;.&#8221;token&#8221;.<br>8.8. Last, click on the <strong>Tick \u2714\ufe0f<\/strong> icon to save. <\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Here is what your <strong>General <\/strong>tab should look like:<\/p>\n\n\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter size-large\"><img width=\"1024\" height=\"648\" src=\"https:\/\/preview-php85.dzine.org\/five\/wp-content\/uploads\/2024\/02\/Five.Co-FileMaker-Data-API-General-Settings-1024x648.png\" alt=\"\" class=\"wp-image-2461\" srcset=\"https:\/\/preview-php85.dzine.org\/five\/wp-content\/uploads\/2024\/02\/Five.Co-FileMaker-Data-API-General-Settings-1024x648.png 1024w, https:\/\/preview-php85.dzine.org\/five\/wp-content\/uploads\/2024\/02\/Five.Co-FileMaker-Data-API-General-Settings-300x190.png 300w, https:\/\/preview-php85.dzine.org\/five\/wp-content\/uploads\/2024\/02\/Five.Co-FileMaker-Data-API-General-Settings-768x486.png 768w, https:\/\/preview-php85.dzine.org\/five\/wp-content\/uploads\/2024\/02\/Five.Co-FileMaker-Data-API-General-Settings-1536x972.png 1536w, https:\/\/preview-php85.dzine.org\/five\/wp-content\/uploads\/2024\/02\/Five.Co-FileMaker-Data-API-General-Settings-2048x1296.png 2048w\" sizes=\"(max-width: 1024px) 100vw, 1024px\" \/><figcaption class=\"wp-element-caption\"><em>Image 7.1: Filling in the General settings for the FileMaker Data API<\/em><\/figcaption><\/figure>\n<\/div>\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<p class=\"wp-block-paragraph\">Done &#8211; we have now successfully added a FileMaker Data API as a data source in Five!<\/p>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"expansion-how-to-build-an-app-on-the-file-maker-data-api\">Expansion: How to Build an App on the FileMaker Data API<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\"> Once you have successfully added the FileMaker Data API as a data source to Five, the API can be used to:<\/p>\n\n\n\n<ol class=\"wp-block-list\">\n<li>Build a responsive web application, such as API dashboards, API admin panels, or API CRUD apps.<\/li>\n\n\n\n<li>Create forms, charts, dashboards, or PDF reports on top of it. Five&#8217;s <strong>Form <\/strong>and <strong>Chart Wizards<\/strong> make it extremely quick to build front-end elements for a responsive web application.<\/li>\n\n\n\n<li>Give a wider audience access to part or all of the data stored in your FileMaker database. Five&#8217;s fixed monthly pricing per application &#8211; <strong>without user limits<\/strong> &#8211; makes this viable.<\/li>\n\n\n\n<li>Push some of this data into Five&#8217;s MySQL database. Once the data from the API is stored inside Five&#8217;s database, it can be queried in standard SQL.<\/li>\n\n\n\n<li>Assign CRUD permissions to different user roles to the API.<\/li>\n<\/ol>\n\n\n\n<p class=\"wp-block-paragraph\">Once the connection to your API is set up, the possibilities are almost limitless in Five. To get started developing your app, watch this video and learn how to create a form that connects to your API in Five (fast forward to 5 min 25 sec to see how to create a form on an API):<\/p>\n\n\n\n<figure class=\"wp-block-embed is-type-video is-provider-youtube wp-block-embed-youtube wp-embed-aspect-16-9 wp-has-aspect-ratio\"><div class=\"wp-block-embed__wrapper\">\n<iframe title=\"Connect to REST APIs Using Web Services | Five.Co\" width=\"500\" height=\"281\" src=\"https:\/\/www.youtube.com\/embed\/wybhalZpla4?start=60&#038;feature=oembed\" frameborder=\"0\" allow=\"accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share\" referrerpolicy=\"strict-origin-when-cross-origin\" allowfullscreen><\/iframe>\n<\/div><\/figure>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"common-questions-about-the-file-maker-data-api\">Common Questions About the FileMaker Data API<\/h2>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"1-my-bearer-token-expires-every-15-minutes-how-can-five-handle-this\">1. My Bearer Token Expires Every 15 Minutes. How Can Five Handle This?<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">Five can automatically renew the bearer token. Setting this up is simple inside Five and was already part of Step 8 above. Click on the <strong>General <\/strong>tab in the Connection Wizard:<\/p>\n\n\n\n<ol class=\"wp-block-list\">\n<li>Select <strong>New <\/strong>from the <strong>WebService<\/strong> drop-down.<\/li>\n\n\n\n<li>Give your API an appropriate <strong>WebService ID<\/strong> and <strong>Name<\/strong>.<\/li>\n\n\n\n<li>Select <strong>Basic <\/strong>for the <strong>Authentication Type<\/strong>.<\/li>\n\n\n\n<li>Add the credentials for your Basic Auth in the <strong>Username<\/strong> and <strong>Password<\/strong> field.<\/li>\n\n\n\n<li>Add the URL that generates a bearer token for your layout in the <strong>Token Endpoint<\/strong> field. This is the same endpoint discussed in the previous question.<\/li>\n\n\n\n<li>In the <strong>Token Path<\/strong>, add: <code><strong>\"response\".\"token\"<\/strong><\/code>. This indicates where FileMaker stores your token in the JSON response after calling the API. <\/li>\n<\/ol>\n\n\n\n<p class=\"wp-block-paragraph\">Here is what your screen should look like:<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img width=\"1024\" height=\"531\" src=\"https:\/\/preview-php85.dzine.org\/five\/wp-content\/uploads\/2024\/02\/image-35-1024x531.png\" alt=\"\" class=\"wp-image-2409\" srcset=\"https:\/\/preview-php85.dzine.org\/five\/wp-content\/uploads\/2024\/02\/image-35-1024x531.png 1024w, https:\/\/preview-php85.dzine.org\/five\/wp-content\/uploads\/2024\/02\/image-35-300x155.png 300w, https:\/\/preview-php85.dzine.org\/five\/wp-content\/uploads\/2024\/02\/image-35-768x398.png 768w, https:\/\/preview-php85.dzine.org\/five\/wp-content\/uploads\/2024\/02\/image-35.png 1339w\" sizes=\"(max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"2-how-can-i-use-my-api-in-my-applications\">2. How Can I Use My API In My Applications?<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">When you set up an API through the Connection Wizard, Five tries to understand the response and maps the data it receives into fields. This enables Five to immediately use your API as a data source for your applications. <\/p>\n\n\n\n<p class=\"wp-block-paragraph\">To better understand how this works, click on <strong>Read List Mapping<\/strong>, paste your API URL, and click on <strong>Send. <\/strong>Now, click on <strong>Field Mapping<\/strong>, which is right below where you pasted your URL.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Here you will see how Five is mapping all your fields. The field mapping translates the JSON response into fields and assigns each field a <strong>Field ID<\/strong>. It also gives each mapped field a Data Type and Display Type. <\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Last, the field mapping tries to automatically understand what your <strong>Primary Key<\/strong> is. You can confirm or change the primary key through the checkbox in the <strong>Primary Key<\/strong> column. <\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img width=\"1024\" height=\"366\" src=\"https:\/\/preview-php85.dzine.org\/five\/wp-content\/uploads\/2024\/02\/Slide-16_9-6-1024x366.png\" alt=\"\" class=\"wp-image-2410\" srcset=\"https:\/\/preview-php85.dzine.org\/five\/wp-content\/uploads\/2024\/02\/Slide-16_9-6-1024x366.png 1024w, https:\/\/preview-php85.dzine.org\/five\/wp-content\/uploads\/2024\/02\/Slide-16_9-6-300x107.png 300w, https:\/\/preview-php85.dzine.org\/five\/wp-content\/uploads\/2024\/02\/Slide-16_9-6-768x274.png 768w, https:\/\/preview-php85.dzine.org\/five\/wp-content\/uploads\/2024\/02\/Slide-16_9-6-1536x549.png 1536w, https:\/\/preview-php85.dzine.org\/five\/wp-content\/uploads\/2024\/02\/Slide-16_9-6-2048x732.png 2048w\" sizes=\"(max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<p class=\"has-text-align-center wp-block-paragraph\"><\/p>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<p class=\"wp-block-paragraph\">After you are done, click on <strong>Save<\/strong>, and you should be able to use this API directly as a data source in forms, charts, or PDF reports.<\/p>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"3-what-is-a-data-source-in-five\">3. What Is A Data Source in Five?<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">A data source is required when creating forms, reports, charts, or any other component dealing with data in Five. A data source can be:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>A database table from Five&#8217;s integrated MySQL database,<\/li>\n\n\n\n<li>A database table from an external database, connected to Five via a connection string,<\/li>\n\n\n\n<li>An SQL query, or <\/li>\n\n\n\n<li>An API connection<\/li>\n<\/ul>\n\n\n\n<p class=\"wp-block-paragraph\">The Connection Wizard saves your API as a data source, enabling its direct use in your applications.<\/p>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"4-does-every-user-have-permission-to-write-back-to-my-api\">4. Does Every User Have Permission to Write Back to My API?<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">User permissions can be set by accessing the &#8220;<strong>Roles<\/strong>&#8221; menu under &#8220;<strong>Setup<\/strong>.&#8221; In this menu, you can define default and individual-level permissions for each data source in your application.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Of course, you can also govern access to the data stored in your FileMaker database through FileMaker. Follow the <a href=\"https:\/\/help.claris.com\/en\/data-api-guide\/content\/index.html\" rel=\"nofollow noopener\" target=\"_blank\">FileMaker Data API Guide<\/a> to learn more.<\/p>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"5-is-my-api-connection-a-live-connection-will-my-data-be-up-to-date-when-i-run-my-apps\">5. Is My API Connection a Live Connection? Will My Data Be Up to Date When I Run My Apps?<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">Yes, since your API acts directly as a data source, it is a live connection to the Data API. If you prefer not to have a live connection, you can use custom JavaScript functions to manage your data.<\/p>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"6-can-i-store-my-api-data-in-the-fives-my-sql-database\">6. Can I Store My API Data in the Five&#8217;s MySQL Database?<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">You can create custom JavaScript functions in Five to handle your data. When using code, you have complete control over your data. For example, in just a few lines of code, you can extract and store the data from your API in Five&#8217;s integrated MySQL database. This then enables you to query your data. Alternatively, you can just use Five to create a CRUD front-end directly on your API, for example.<\/p>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h3 class=\"wp-block-heading\" id=\"7-how-do-i-continue-from-here\">7. How Do I Continue From Here?<\/h3>\n\n\n\n<p class=\"wp-block-paragraph\">Five treats your API as a data source. To better understand what you can do with a data source in Five, <a href=\"https:\/\/help.five.org\" rel=\"nofollow noopener\" target=\"_blank\">visit our documentation<\/a> or <a href=\"https:\/\/five.org\" rel=\"nofollow noopener\" target=\"_blank\">post your questions on our community<\/a>.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">Last, to push your application to the web, so that your end-users can access it, subscribe to one of our plans.<\/p>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"get-your-app-online-for-us-29-99-per-month\">Get Your App Online For US$29.99 Per Month<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Five lets you develop your application locally free of charge. Simply use our free download and build your application until it\u2019s ready for your end-users.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">To deploy your application, sign up for one of our paid plans, starting from US$29.99 per month and application. Your plan includes unlimited end-users and provides you with a custom URL to access the application online.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\"><a href=\"https:\/\/preview-php85.dzine.org\/five\/order-payment\/\">To sign up, click here!<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>In today&#8217;s article, we explain how to connect Five to the FileMaker Data API and address common questions about integrating FileMaker with Five. More specifically, we show how to use the FileMaker Data API as a data source in Five to build a web interface on top of it. This blog post focuses on a [&hellip;]<\/p>\n","protected":false},"author":10,"featured_media":2441,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"_eb_attr":"","_uag_custom_page_level_css":"","footnotes":""},"categories":[21],"tags":[],"class_list":["post-2384","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-blog"],"acf":[],"uagb_featured_image_src":{"full":["https:\/\/preview-php85.dzine.org\/five\/wp-content\/uploads\/2024\/02\/Five.Co-Connecting-to-the-FileMaker-Data-API-Common-Questions.png",960,540,false],"thumbnail":["https:\/\/preview-php85.dzine.org\/five\/wp-content\/uploads\/2024\/02\/Five.Co-Connecting-to-the-FileMaker-Data-API-Common-Questions-150x150.png",150,150,true],"medium":["https:\/\/preview-php85.dzine.org\/five\/wp-content\/uploads\/2024\/02\/Five.Co-Connecting-to-the-FileMaker-Data-API-Common-Questions-300x169.png",300,169,true],"medium_large":["https:\/\/preview-php85.dzine.org\/five\/wp-content\/uploads\/2024\/02\/Five.Co-Connecting-to-the-FileMaker-Data-API-Common-Questions-768x432.png",768,432,true],"large":["https:\/\/preview-php85.dzine.org\/five\/wp-content\/uploads\/2024\/02\/Five.Co-Connecting-to-the-FileMaker-Data-API-Common-Questions.png",960,540,false],"1536x1536":["https:\/\/preview-php85.dzine.org\/five\/wp-content\/uploads\/2024\/02\/Five.Co-Connecting-to-the-FileMaker-Data-API-Common-Questions.png",960,540,false],"2048x2048":["https:\/\/preview-php85.dzine.org\/five\/wp-content\/uploads\/2024\/02\/Five.Co-Connecting-to-the-FileMaker-Data-API-Common-Questions.png",960,540,false]},"uagb_author_info":{"display_name":"Pranoy Sarkar","author_link":"https:\/\/preview-php85.dzine.org\/five\/author\/f1v5_ed8_au\/"},"uagb_comment_info":0,"uagb_excerpt":"In today&#8217;s article, we explain how to connect Five to the FileMaker Data API and address common questions about integrating FileMaker with Five. More specifically, we show how to use the FileMaker Data API as a data source in Five to build a web interface on top of it. This blog post focuses on a&hellip;","_links":{"self":[{"href":"https:\/\/preview-php85.dzine.org\/five\/wp-json\/wp\/v2\/posts\/2384","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/preview-php85.dzine.org\/five\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/preview-php85.dzine.org\/five\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/preview-php85.dzine.org\/five\/wp-json\/wp\/v2\/users\/10"}],"replies":[{"embeddable":true,"href":"https:\/\/preview-php85.dzine.org\/five\/wp-json\/wp\/v2\/comments?post=2384"}],"version-history":[{"count":0,"href":"https:\/\/preview-php85.dzine.org\/five\/wp-json\/wp\/v2\/posts\/2384\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/preview-php85.dzine.org\/five\/wp-json\/wp\/v2\/media\/2441"}],"wp:attachment":[{"href":"https:\/\/preview-php85.dzine.org\/five\/wp-json\/wp\/v2\/media?parent=2384"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/preview-php85.dzine.org\/five\/wp-json\/wp\/v2\/categories?post=2384"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/preview-php85.dzine.org\/five\/wp-json\/wp\/v2\/tags?post=2384"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}