curl

Downloading an on online report using Python requests

牧云@^-^@ 提交于 2020-06-17 09:15:28
问题 How could you request the following curl command using Python please to download a report from Ads Manager (Facebook)? curl "https://scontent-mad1-1.xx.fbcdn.net/v/t66.9516-6/reportid.csv/reportname.csv?_nc_cat=109^&_nc_sid=7a48f7^&_nc_ohc=m4lvbyCnNzsAX9VwD8m^&_nc_ad=z-m^&_nc_cid=0^&_nc_ht=scontent-mad1-1.xx^&oh=45e8967402708665322afdb82bad4a46^&oe=5F0D314B" ^ -H "authority: scontent-mad1-1.xx.fbcdn.net" ^ -H "upgrade-insecure-requests: 1" ^ -H "user-agent: Mozilla/5.0 (Windows NT 10.0; Win64

curl file upload with semicolons in filename

孤街浪徒 提交于 2020-06-16 17:20:08
问题 I'm implementing an automated, command line file uploader using curl to a servlet. The problem is, I've got tens of thousands of files with semicolons (;) in the filenames. I'm well aware of the annoyance of this but it is a legacy app that continues to produce new files each day. Renaming is not really an option for compatibility reasons downstream. I've tried quoting, escaping, converting to "%3b", fully qualifying the path... the obvious stuff... but nothing seems to work, and it fails to

curl file upload with semicolons in filename

試著忘記壹切 提交于 2020-06-16 17:18:55
问题 I'm implementing an automated, command line file uploader using curl to a servlet. The problem is, I've got tens of thousands of files with semicolons (;) in the filenames. I'm well aware of the annoyance of this but it is a legacy app that continues to produce new files each day. Renaming is not really an option for compatibility reasons downstream. I've tried quoting, escaping, converting to "%3b", fully qualifying the path... the obvious stuff... but nothing seems to work, and it fails to

Check for HTTP Code in fetch_json sub / save previous output for backup in Perl

天涯浪子 提交于 2020-06-16 09:50:32
问题 so I have to update a perl script that goes through a json file, fetches keys called “items”, and transforms these items into perl output. I’m a noob at Perl/coding in general, so plz bear with me🥺. The offset variable is set as each url is iterated through. A curl command is passed to the terminal, the file is put through a "@lines" array, and in the end, whatever json data is stored in $data gets decoded and transformed. and in the blocks below (where # populate %manager_to_directs, #

Check for HTTP Code in fetch_json sub / save previous output for backup in Perl

倖福魔咒の 提交于 2020-06-16 09:50:09
问题 so I have to update a perl script that goes through a json file, fetches keys called “items”, and transforms these items into perl output. I’m a noob at Perl/coding in general, so plz bear with me🥺. The offset variable is set as each url is iterated through. A curl command is passed to the terminal, the file is put through a "@lines" array, and in the end, whatever json data is stored in $data gets decoded and transformed. and in the blocks below (where # populate %manager_to_directs, #

How to send environment variables using curl

百般思念 提交于 2020-06-16 03:30:12
问题 I am trying to use slack to notify when a build is complete or if a build fails on GitlabCI. What I also wanna be able to do is append a predefined environment variable $GITLAB_CI_COMMIT_TITLE so along with the build notification I also know which build with what commit has completed/failed In short, This works "curl -X POST -H 'Content-type: application/json' --data '{\"text\":\" Client Staging build complete. \n\"}' https://hooks.slack.com/services/T04KY5T7G/BBA4Z4BQC

API request and Error in curl::curl_fetch_memory(url, handle = handle) : SSL certificate problem: certificate has expired

我只是一个虾纸丫 提交于 2020-06-13 05:44:07
问题 I was running the code for months without any issues, and couple days before. GET(url="myurl", query) Today I've got an error Error in curl::curl_fetch_memory(url, handle = handle) : SSL certificate problem: certificate has expired The SSL cert on the site is active and ends in a year. Also the same GET request is working via browser.... What is the issue? 🤷‍♂️ 回答1: Try testing your server with this tool: https://www.ionos.com/tools/ssl-checker and see if it says that it is "not installed

SImple (and) dirty Firestore authentication rule

依然范特西╮ 提交于 2020-06-12 08:34:13
问题 I'm using REST API in a PHP project to send the data to Firestore DB through curl (PHP curl). I'm struggling in understanding how to setup an authentication rule for a "service" and the suggested approach through Google authorization looks overkilling to me. My data must be readable by ALL but writable just by my PHP server. So far I could ensure that a writing operation could happen only if in the dataset sent a specific code is provided (auth=123): service cloud.firestore { match /databases

Wget and Curl stopped working with HTTPS. Wrongly complain about an expired certificate

筅森魡賤 提交于 2020-06-12 07:29:37
问题 I have a script that runs every day on an Ubuntu 14.04 server. The script is a simple wget command that downloads a file from a remote server and saves it to the local file system: wget https://example.com/resources/scripts/myfile.php -O myfile.php It has worked fine for months until this morning when suddenly when I run it I get: --2020-05-30 11:57:16-- https://example.com/resources/scripts/myfile.php Resolving example.com (example.com)... xx.xx.xx.xx Connecting to example.com (example.com)

Git Push Fails with RPC failed; curl 55 SSL_write() returned SYSCALL, errno = 10053

若如初见. 提交于 2020-06-10 10:25:17
问题 Full list of info Counting objects: 1945, done. Delta compression using up to 8 threads. Compressing objects: 100% (1935/1935), done. rror: RPC failed; curl 55 SSL_write() returned SYSCALL, errno = 10053 atal: The remote end hung up unexpectedly Writing objects: 100% (1945/1945), 3.15 GiB | 1.21 MiB/s, done. Total 1945 (delta 231), reused 0 (delta 0) fatal: The remote end hung up unexpectedly Everything up-to-date As far as I can tell, there is no file larger than 150MB, using the latest Git