We have reset all users FileMaker related profile fields. Please take the opportunity to update your information,  this will provide background to members whom read your posts. Click here.

Jump to content

Search the Community

Showing results for tags 'curl'.



More search options

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Categories

  • Custom Function Library

Community Forums

  • Community Resources
    • Community Articles, Tips, & Techniques
    • FileMaker Marketplace Discussions
  • FileMaker Security Management
    • Security Concepts
    • Intellectual Property
  • FileMaker Server Administration
    • FileMaker Server 16
    • FileMaker Custom SSL Certificates
    • External Server Authentication
  • FileMaker Go & Mobile Strategies
    • FileMaker Go for iPhone & iPad
    • iBeacon Support
    • FileMaker IOS App SDK
  • FileMaker and the Internet
    • FileMaker REST API
    • FileMaker Cloud
    • FileMaker WebDirect
    • Custom Web Publishing
    • Other Internet Technologies
  • FileMaker Interface Features
    • Cards & Window Management
    • Interface Design Discussions
    • Layouts
    • Themes and Styles
    • Button, Popovers, Button Bars, SVG Icons
    • Tab and Slide Control Panels
    • Portals
    • Web Viewer
    • Conditional Formatting
    • Custom Menus
    • Value Lists
    • Tool Tips
  • FileMaker Schema & Logical Functions
    • Managing Scripts
    • Calculation Engine (Define Fields)
    • Custom Functions Discussions
    • FileMaker Query Language or FQL
    • Relationships
    • Charting
    • Remote Container Fields
    • Finding & Searching
    • Importing & Exporting
    • External Data Sources
    • Advanced & Developer Features
    • Reports, Printing & Publication
  • Brain Food
    • The Left Brain
    • Upgrading & Migration
    • Data Analysis
    • Development Standards
    • The Separation Model
    • Relational Database Theory
    • Damaged / Corrupt File Problems
    • OS Level Database Automation
    • Hardware & Networking
    • Bar Codes (Printer, Scanners, Software)
    • Accounting Solutions
  • FileMaker Discussions
    • FileMaker Pro 16 Discussions
  • Geist Interactive Product Support Forums
    • Visit Geist Interactive
    • Visit Modular FileMaker
    • FMPerception
    • Generator
    • fmQBO
  • 360 Works Official Product Support Forums
    • 360 Works General Support
    • MirrorSync by 360Works
    • SuperContainer by 360 Works
    • ScriptMaster by 360 Works
    • FTPeek by 360 Works
    • 360Works Email Plugin
    • DocuBin by 360 Works
    • Zulu – FileMaker, iCal & Google Calendar.
  • FM Forums Affiliate Sponsors
    • SyncServer Pro by LinearBlue
    • Open Source Frameworks
    • Monkey Bread Software (MBS Plugin)
    • FileMaker Plug-Ins
    • ISO FileMaker Magazine
    • User Group Central - Sponsored by FMPug.com
  • FM Starting Point - By Richard Carlton Consulting
    • Visit FM Starting Point
    • FM Starting Point - General Discussions
  • FileMaker Classifieds
    • FileMaker Product & Service Announcements
    • Professional FileMaker Training
    • Services for Hire
    • Services Wanted
    • Solutions Wanted
    • Tools Of The Trade
  • The Water Cooler
    • Member Lounge
    • Wants & Wishes
  • FM Forums Operations
    • FM Forums Feedback & Site News
    • Site Instructions
  • FileMaker Platform
  • Dungeon

Blogs

  • Captain's Blog
  • FileMaker Weetbicks
  • FileMaker Security Blog
  • The FileMaker Rift
  • HOnza's Bits @ FMForums
  • SeedCode
  • CampSoftware, Hal Gumbert
  • FileMaker Hacks
  • Skeleton Key's Blog
  • Wing Forward Solutions
  • 360Works Articles and Tutorials
  • GoBillit
  • Filemaker - an amateur's view
  • Linear Blue
  • Surya Kanta Mekap's Blog
  • eXcelisys' Blog
  • Manjit Behera
  • Blue Feather's Blog
  • RCC's FileMaker News and Bits
  • Thorsen Consulting
  • DB Services Blog
  • FileMaker Magazine
  • Eye on FileMaker
  • Dev Talk
  • The Philosophy of FileMaker

Categories

  • Samples
  • Solutions
  • White Papers
  • Plug-Ins
  • FMGo

Found 7 results

  1. I'm trying to get a token from an authorization server using cURL in Insert From URL. When I make the following request in Terminal curl -i -X POST -d 'username=myaccountname&password=mypassword' https://authserver.com/login I get the token back in the response header. Since FileMaker doesn't support the --include (-i) option I haven't been able to figure out how to get the response header with the token. Anyone have any ideas on how to accomplish this? Thanks in advance! -Kent UPDATE: Okay, I figured out I can get a response header by using the option --dump-header and setting it to a variable. The only problem now is that the token comes from a redirect location and I'm only getting the response header from the original URL. I'll keep working on it but I'll be happy to get whatever advice anyone can offer in the meantime.
  2. I am trying to do a basic Insert from URL call with some CURL headers added and I keep getting authentication errors. This is the curl command sent by the provider for me to use. curl -X GET --header 'Accept: application/json' --header 'api_key: 1234567890abcdefg' 'https://mydomain.leaddocket.com/api/endpoint' This is the curl I am setting up -X GET \ --header 'Accept: application/json' \ --header 'api_key: 1234567890abcdefg' \ -trace $$curlTraceDump FM barks and says "Authentication Failed" but if I do this with the BaseElements plugin, it works just fine. What I found when looking at the Curl Trace was that FM is dropping some of the headers I send and injecting its own. Here's the snippet I am finding from FM's trace: GET /api/Leads/P endingExportIds HTTP/1.1 Host: mydomain.leaddocket.com User-Agent: FileMaker/16.0 Accept: */* Accept-Encoding: deflate, gzip Notice: both headers I sent were stripped and replaced. Here is the response from BaseElements trace GET /api/endpoint HTTP/1.1 Host: mydomain.leaddocket.com User-Agent: libcurl-agent-base-elements-plugin/3.3.4 Accept: application/json api_key: 1234567890abcdefg BE left my headers intact. So what gives?
  3. FileMaker cURL Options

    One of the most important and wide-reaching updates in FileMaker 16 is the ability to set cURL options in the Insert from URL script step. This allows FileMaker to natively integrate with innumerable services across the web, including Google Calendar, Google Maps, Microsoft SharePoint, and many other services. FileMaker cURL Options David Happersberger dbservices.com
  4. With the introduction of cURL options in FM16's Insert from URL script step I've been investigating the possibility of being able to save a copy of my FM solution directly to my Dropbox folder using the https://content.dropboxapi.com/2/files/upload element from Dropbox V2 API. I've successfully created the access token to pass through as part of this step and the Insert from URL script step successfully creates the stated folder and file in my Dropbox. However, the file size is always 0 bytes. I've tried 2 different methods METHOD 1 #Export a compacted copy of this file to Temporary Folder Set Variable [ $file_path ; Get ( TemporaryPath ) & "Solution.fmp12" ] Save a Copy as [ "$file_path" ; compacted ] #Set my cURL options to variable Set Variable [ $curl_header ; "curl -X POST https://content.dropboxapi.com/2/files/upload \\" & ¶ & "--header \"Authorization: Bearer " & PREFERENCES::Dropbox_AccessToken & "\" \\" & ¶ & "--header \"Dropbox-API-Arg: {\\\"path\\\": \\\"/DB2FM/Solution.fmp12\\\"}\" \\" & ¶ & "--header \"Content-Type: application/octet-stream\" \\" & ¶ & "--data-binary @" & $file_path ] #Dropbox URL Set Variable [ $dropbox_url ; "https://content.dropboxapi.com/2/files/upload" ] #Make Request - Set to variable adn then format to JSON field Insert from URL [ Verify SSL Certificates ; With dialog: Off ; $json ; $dropbox_url ; cURL options: $curl_header ] Set Field [ PREFERENCES:Dropbox_JSON ; JSONFormatElements ( $json ) ] METHOD 2 #Export a compacted copy of this file to Temporary Folder and then import to a container field Set Variable [ $file_path ; Get ( TemporaryPath ) & "Solution.fmp12" ] //note1 Save a Copy as [ "$file_path" ; compacted ] //note1 Insert File [ PREFERENCES::Container ; "$file_path" ] //note1 #Set variable following instructions on FileMaker website which states: # - Direct file access is replaced with a FileMaker variable prefixed by the @ character. # - To access a file, you can set the variable to a container field, which contains the file, then use that variable as the parameter of the cURL option. Set Variable [ $container_path ; PREFERENCES::Container ] #Set my cURL options to variable Set Variable [ $curl_header ; "curl -X POST https://content.dropboxapi.com/2/files/upload \\" & ¶ & "--header \"Authorization: Bearer " & PREFERENCES::Dropbox_AccessToken & "\" \\" & ¶ & "--header \"Dropbox-API-Arg: {\\\"path\\\": \\\"/DB2FM/Solution.fmp12\\\"}\" \\" & ¶ & "--header \"Content-Type: application/octet-stream\" \\" & ¶ & "--data-binary @" & $container_path ] #Dropbox URL Set Variable [ $dropbox_url ; "https://content.dropboxapi.com/2/files/upload" ] #Make Request - Set to variable adn then format to JSON field Insert from URL [ Verify SSL Certificates ; With dialog: Off ; $json ; $dropbox_url ; cURL options: $curl_header ] Set Field [ PREFERENCES:Dropbox_JSON ; JSONFormatElements ( $json ) ] JSON Response For Both Methods I get the following JSON Response for both methods { "client_modified" : "2017-05-16T11:22:47Z", "content_hash" : "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855", "id" : "id:heJWQ1SWwJsAAAAAAcMWNw", "name" : "Solution.fmp12", "path_display" : "/DB2FM/Solution.fmp12", "path_lower" : "/db2fm/solution.fmp12", "rev" : "3a0412f00f58892", "server_modified" : "2017-05-16T11:22:48Z", "size" : 0 } Any ideas as to why the file is created but with no content. I've also tried this with a number of different file types (.png, .txt, .pdf) by manually inserting a file into the container and greying out the 3 steps marked //note1 above but the result is always the same.
  5. Help with API

    Hi. I am trying to script the getting of some data from a website that has an API. I have BaseElementsPlugin and was given an example bit of code by the website: data = {'domain': domain, 'include_generic': True} headers = {'X-Api-Key': 'xyz123'} resp = requests.post('https://api.anymailfinder.com/v3.0/search/domain.json', data=data, headers=headers) I have never dealt with this kind of programming and am not even sure where this info would go or what script step(s) I would use to call this. Is this CURL? Are you aware of sample FM scripting that I could use as a model to figure this out? Thanks for any help with this!
  6. Hi All, I just thought I'd try to give back to the community that has given so much to me by writing a little tutorial. This technique is one I developed on Macs. Mac OS X has the curl command line tool as part of the default installation. Curl is like a web swiss army knife. You can fetch files, POST data, upload to or download from FTP servers etc... so it brings a lot of functionality to the table which isn't built into FileMaker. I make use of curl through the "do shell script" AppleScript command, which in FileMaker I use through the "Perform AppleScript" script step. Here's a simple 6 line script that lets you take the contents of a container field and upload it to an FTP site. Substitute your container field in the first and fifth lines and your FTP information in the $script variable to make it functional. This script could be extended by actually having variables for the FTP credentials/location too but I've kept it simple here just to demonstrate the technique. set variable [$file_name; GetAsText(YourTable::YourContainerField)] set variable [$path_temp; Get(TemporaryPath) & $file_name] set variable [$path_unix; Middle($path_temp ; Position($path_temp ; "/" ; 1 ; 2) ; Length($path_temp))] set variable [$script; "do shell script "curl -T " & $path_unix & " ftp://USERNAME:PASSWORD@FTP_HOST/FTP_DIRECTORY/" & $file_name &"""] Export Field Contents [YourTable::YourContainerField; "$path_temp"] Perform AppleScript [$script] Enjoy!
  7. Ebay create Listing

    Hello, I want to create a product listing in eBay, with images. I looked at the API's at eBay, overwhelming . Did somebody do this already from Filemaker and can show me an example? TIA
×