Curl is useful because in many projects curl is used by the backend engineers . Also postman / jmeter and maybe other tools allow importing from curl . Also exporting as curl is allowed by postman tool as well for request sharing
hi Raghav, what is API conformance testing?.....can u give me explanation or suggest me any tutorial / link for API conformance testing?......also explain me about conformance testing
Nice little tutorial. I wish it had some sample requests with authentication headers like TBA or OAuth2. Will you be able to give some examples on that?
As u showed, I have used the curl command for the sample website and it worked, but when i'm trying the same command to retrieve datas from appdynamics tool, but i'm getting this Javascript Required. Enable Javascript in your browser settings to use AppDynamics . I see javascript is already enabled in chrome settings. Could you please help here.
Hi Hari The error message "Javascript Required. Enable Javascript in your browser settings to use AppDynamics" means that the AppDynamics website is expecting JavaScript to be enabled in your browser. This is because AppDynamics uses JavaScript to render some of its content. If you have JavaScript enabled in your browser and you are still getting this error message, it is possible that the AppDynamics website is not loading correctly. This could be due to a problem with the AppDynamics website or with your internet connection. To troubleshoot this issue, you can try the following: 1. Check your internet connection to make sure that it is working properly. 2. Try refreshing the AppDynamics website. 3. Try using a different browser. 4. If you are still having problems, you can contact AppDynamics support for help. Here are some additional things you can try: * Clear your browser's cache and cookies. * Disable any extensions or add-ons that you are using in your browser. * Try using a different computer
Thanks for this video ... a very nice covering!. BTW for POST/PUT about JSON is expected use the 'content-type' header instead. In your case was used 'accept', so it is really used to define the response format.
Hi Raghav, I have a question, What if you have multiple containers for the JSON data that you retrieve from the GET request and you only want to see the name from all the containers?
Hi Daniel, If you want to know if an API is up and running, you can use the curl command to make a request to the API endpoint. Assuming the API endpoint is a GET request that returns a response, you can use the following curl command to make a request and see the response: curl If the API is up and running, you should receive a response from the server. The exact response you receive will depend on the API and the endpoint you are querying. If you receive an error response or no response at all, it may indicate that the API is not working correctly or that there is an issue with your network connection. However, keep in mind that just because an API endpoint responds to a request does not necessarily mean that the API is functioning correctly or providing accurate data. To confirm that the API is fully functional and providing accurate data, you will need to perform more thorough testing and analysis.
@@RaghavPal thanks for the reply. If we pass the token generation url , curl can generate token for authorisation ? and if so can you share the example curl scripts?
No, curl by itself cannot generate a token for authorization. Curl is a command-line tool used for transferring data using various protocols, including HTTP. When you pass a token generation URL to curl, it will simply make an HTTP request to that URL and return the response. It does not have any built-in capability to generate authorization tokens.
These commands are not working for me , basically nothing is working for POST verb , for POST verb in my API I have used dynamic,object,httprequestmessage datatypes as parameters but its not working in CURL same thing is working in POSTMAN,what is the issue with CURL or my code can you tell me?? Below are the queries I used for two of my APIS: curl -X POST -H "Accept:application/json" localhost:44373/api/values -d '{"data": "dksk"}' curl localhost:44373/api/values -d "data=jksbjs&name=kjdsj" curl -X POST -H "Accept:application/json" localhost:61963/api/values -d '{"name":"kxsk","job":"kscss"}'
Hi Alex To use CURL in C to send mail using your IIS 6.0 SMTP server, you can follow these steps: 1. Install libcurl: First, you need to install the libcurl library, which is a C library that allows you to make HTTP requests, including sending emails via SMTP. 2. Include the necessary headers: In your C code, include the appropriate libcurl header files. 3. Initialize libcurl: Before making any requests, you need to initialize the libcurl library. 4. Set up the SMTP details: Provide the necessary SMTP server details, such as the IP address, port number, sender email, recipient email, subject, and body. 5. Send the email: Use libcurl to send the email using SMTP. Here's a basic example of how you can use CURL in C to send an email using your IIS 6.0 SMTP server: ```c #include #include int main(void) { CURL *curl; CURLcode res = CURLE_OK; // Initialize libcurl curl = curl_easy_init(); if (curl) { // Set SMTP server details curl_easy_setopt(curl, CURLOPT_URL, "smtp://your_ip_address:25"); curl_easy_setopt(curl, CURLOPT_MAIL_FROM, "sender@example.com"); struct curl_slist *recipients = NULL; recipients = curl_slist_append(recipients, "recipient@example.com"); curl_easy_setopt(curl, CURLOPT_MAIL_RCPT, recipients); // Set email content curl_easy_setopt(curl, CURLOPT_READFUNCTION, NULL); // Set your read function if you want to include a message body curl_easy_setopt(curl, CURLOPT_UPLOAD, 1L); // Send the email res = curl_easy_perform(curl); // Check for errors if (res != CURLE_OK) { fprintf(stderr, "curl_easy_perform() failed: %s ", curl_easy_strerror(res)); } // Clean up curl_slist_free_all(recipients); curl_easy_cleanup(curl); } return (int)res; } ``` Please note that this is just a basic example, and you might need to customize it according to your specific requirements, such as providing authentication credentials or message content. Additionally, ensure that your IIS 6.0 SMTP server is correctly configured to allow email relay from your C application's IP address to prevent it from being blocked as an open relay.
@@RaghavPal , thank you so much, I will try this as soon as possible. Why I'm switching to CURL, well I have a program that's been working for 15 years harvesting data from several websites, suddenly they stopped working a month ago, my research found out that the websites upgraded and use Angular, I tried everything from my old form POST QUERY in OpenSSL, C#, VB6, Python, C, C++, PHP programs, they all failed, then I tried libcurl, it works like magic but I could not send email using my computer static ip address in IIS 6.0. as the SMTP SERVER.
Hi Raghav, I am trying to submit a FORM in a webpage through curl. In the webpage the form action shows as "action=rest/", can you please let me know how i can post the form in the webpage through curl or through any other automation
I hope India one day pull all their engineer and scientist from USA and Europe, Indian are very intelligent and government Indian should use them instead of bullshit unhoronable salary of usa.
Hannibaal I understand your perspective. India indeed has a wealth of talented engineers and scientists who have made significant contributions globally. It’s essential to recognize their skills and expertise
Previously i was facing so many issues with curl in windows but after watching your tutorial i got the solution thanks sir u r great..
You are most welcome Preksha
Thank you SO MUCH you have no idea. I was watching a tutorial about using curl for apis but the instructor is using mac and I'm on windows.
Glad I could help
Not everyone teaches with PASSION, but your bro. Thanks a lot.
So nice of you
Это первое видео, которое мне очень помогло. Ты единственный ответил на мои вопросы. Красава!
Так рад это знать, добро пожаловать
THANK YOU!!! One of the best, and clearly explained tutorials I have ever watched.😊
You are so welcome
Thank you so much, my man! This definitely helped me move through a blockade and has given me the ability to diagnose my website
Great to hear!
getting addicted to ur videos, thanks a lot!
Most welcome Hamsa
This is GOLD! You're an excellent teacher. Cheers!
Thanks a lot
Thank you Raghav for adding immense value to online teaching.
So nice of you Sujatha
We appreciate you !
Thanks a lot
Curl is useful because in many projects curl is used by the backend engineers . Also postman / jmeter and maybe other tools allow importing from curl . Also exporting as curl is allowed by postman tool as well for request sharing
Thanks for sharing El
Excellent video. Exactly what I was looking for. Great presentation and explanation!
Glad it was helpful Dan
Very well explained (and illustrated). Thank you very much !
You're welcome
Thank you for creating this video. It was just what I needed to better understand how to use cURL!!!
You are so welcome Matt
Perfect tutorial video... Starting from installation to query execution... Thanks for such video
You are welcome Pankaj
You're Genius bro. Good luck for your future.
Thank you so much , Humbled
His voice is smooth as butter
Thanks a lot
very good videos on curl. Before this i was fully dependent on postman collection
Glad I could help Niamul
This was actually a little useful to me. Some of the video portions were a little fast, but I think I understood what you were trying to explain.
Please can you tell me is there any other way besides curl to run a cli for a Java API call on Linux, do you know?
Hi Warron, can check this
alternativeto.net/software/curl/
very simple and useful videos, which helps a lot, Thanks VERY much.
You are welcome!
hi Raghav, what is API conformance testing?.....can u give me explanation or suggest me any tutorial / link for API conformance testing?......also explain me about conformance testing
Hi Manjusha, as of now I do not have any resources on this, will plan to add
I wish i could give 100 likes to this video. Its just superb . Thank you so much sir.
So happy & humbled to read your message Prashnat
Thanks Raghav for this helpful tutorial
You're welcome Afnan
nice covered about the topic.
kindly make video lecture series on Python from basics and springboot.
I will plan
starts curl commands at 2:33
Thanks Ragava. Could you provide curl commands with sql injection? If you have any idea......
Not much Uma, will have to check online
Is this like normal sql commands?
Should be able to do, but I will need to check more online on this
How to send a CSV/. zip file using curl could you please share the example ... By the video is awesome
I will share Mohit,
plz add more topic on api testing or dis is all the topic we have in api testing?
Hi Amit, you will find API Testing section here - automationstepbystep.com/
Awesome Tutorial
Please keep it up and waiting to see more tutorials.
Thanks, will do Jini
Thank you, I was trying to use curl from windows cmd lol
Great to know it helped
thanks for clear explanation
You are welcome Devati
Thank you very much for this video, this helped me a lot.
Glad it helped
Very useful and well explained. Tks!
Glad it was helpful!
Thank you for this video.. I'm new to RestAPI, and would like to know how to pass an authentication token in curl command?
Hi Jagan, this will help - stackoverflow.com/questions/3044315/how-to-set-the-authorization-header-using-curl
Bravo .... Thnx mate
Most welcome
NICE VIDEO.NICELY EXPLAINED. But i have a query that how can we use GREP to segregate data from the JSON response using curl?
Hi, I will need to check on that, can try some online help meanwhile
Very Informative Tutorial, Thanks a lot
You are most welcome Ateeq
very good explaination
Thanks Gaurav
Thanks for excellent content!
My pleasure Fernando
Thanks for this valuable tutorial
Thanks for watching Laxmi
Nice tutorial!
Thanks Manish
Nice little tutorial. I wish it had some sample requests with authentication headers like TBA or OAuth2. Will you be able to give some examples on that?
I will plan to have a session for that Vimal
You are awesome! I learned enough with you
I am glad and humbled by your message Justin.
Great content, thanks a lot! 😄
Glad you liked it Artneo
Very helpful - thank you
Most welcome
Hi Raghav Sir, Please can you share me the link for API testing using Cypress. Thanks
Yet to do that, you can find basic Cypress videos here - automationstepbystep.com/
As u showed, I have used the curl command for the sample website and it worked, but when i'm trying the same command to retrieve datas from appdynamics tool, but i'm getting this
Javascript Required. Enable Javascript in your browser settings to use AppDynamics
.
I see javascript is already enabled in chrome settings. Could you please help here.
Hi Hari
The error message "Javascript Required. Enable Javascript in your browser settings to use AppDynamics" means that the AppDynamics website is expecting JavaScript to be enabled in your browser. This is because AppDynamics uses JavaScript to render some of its content.
If you have JavaScript enabled in your browser and you are still getting this error message, it is possible that the AppDynamics website is not loading correctly. This could be due to a problem with the AppDynamics website or with your internet connection.
To troubleshoot this issue, you can try the following:
1. Check your internet connection to make sure that it is working properly.
2. Try refreshing the AppDynamics website.
3. Try using a different browser.
4. If you are still having problems, you can contact AppDynamics support for help.
Here are some additional things you can try:
* Clear your browser's cache and cookies.
* Disable any extensions or add-ons that you are using in your browser.
* Try using a different computer
Thx ! Nice tutorial
Glad it helped
Awesome stuff!!
Thanks for watching
Can I use CURL to automate a REST connection task instead of writing a custom program?
you can based on your needs and scenario
Hi Raghav,
I want to test url is working or not best choice is cURL or any other tool is there?
Thanks,
Kumar
Just to check url is working you can use cURL. Or check any tool to find broken links - ruclips.net/video/Bj3tfSNS0j0/видео.html
Thanks for this valuable tutoria
You are most welcome
Excellent presentation. Thank you.
You are welcome
Useful. Thanks
Most welcome
What is the purpose of CURl ? In organization where we can use or work or implement?
Hi, it is a very simple and quick way to test API
Thanks for this video ... a very nice covering!.
BTW for POST/PUT about JSON is expected use the 'content-type' header instead. In your case was used 'accept', so it is really used to define the response format.
Yes, you are right Manuel
Again, huge thanks for this video!
Hi Raghav Pal,
Could you please make a video on how to fetch bitbucket code review report using curl?
I will try and plan Vishal
@@RaghavPal Thanks Raghav
Nice represention 👍👍👍
Thanks Amit
Thank you!
You're welcome
Hi Raghav,
I have a question, What if you have multiple containers for the JSON data that you retrieve from the GET request and you only want to see the name from all the containers?
Hi Yash, I might need to see an example to check this.
Thanks sir
Very nice tutorial
Thanks Akram
Thank You so much Sir... :)
Most welcome!
very well explained
Thanks Anima
how to extract the status and then check periodically, every hour, if my website is up and running or not ?
will need to check the exact curl command Saroj, if that is your only need, you can also try some online tools for that
Perfect. Thanks Raghav.
You're welcome Bill
Good tutorial. thank you for sharing.
You are very welcome Huan
if i just wants to know the api is up and running ? just use curl url is enough ?
Hi Daniel,
If you want to know if an API is up and running, you can use the curl command to make a request to the API endpoint.
Assuming the API endpoint is a GET request that returns a response, you can use the following curl command to make a request and see the response:
curl
If the API is up and running, you should receive a response from the server. The exact response you receive will depend on the API and the endpoint you are querying. If you receive an error response or no response at all, it may indicate that the API is not working correctly or that there is an issue with your network connection.
However, keep in mind that just because an API endpoint responds to a request does not necessarily mean that the API is functioning correctly or providing accurate data. To confirm that the API is fully functional and providing accurate data, you will need to perform more thorough testing and analysis.
@@RaghavPal thanks for the reply. If we pass the token generation url , curl can generate token for authorisation ? and if so can you share the example curl scripts?
No, curl by itself cannot generate a token for authorization.
Curl is a command-line tool used for transferring data using various protocols, including HTTP. When you pass a token generation URL to curl, it will simply make an HTTP request to that URL and return the response. It does not have any built-in capability to generate authorization tokens.
@@RaghavPal ok got it. thanks for your help
NIce job, very usefull
Glad it was helpful Juan
Thank you again😄
Most welcome Prasanna
Hi..could you please help me on this?..do you have any idea on when curl_getdate is called in a libcurl library when we make any http request?
Will need to check on this
These commands are not working for me , basically nothing is working for POST verb , for POST verb in my API I have used dynamic,object,httprequestmessage datatypes as parameters but its not working in CURL same thing is working in POSTMAN,what is the issue with CURL or my code can you tell me??
Below are the queries I used for two of my APIS:
curl -X POST -H "Accept:application/json" localhost:44373/api/values -d '{"data": "dksk"}'
curl localhost:44373/api/values -d "data=jksbjs&name=kjdsj"
curl -X POST -H "Accept:application/json" localhost:61963/api/values -d '{"name":"kxsk","job":"kscss"}'
What is the response/error you get
Thanks, Raghav!!
you're welcome Deepak
Hi ... what if we want to delete multiple files under multiple directories ? can we do it through curl ?
Not sure Deva, will need to check online.
Thanks what a great help
Happy to know it helped
good job buddy
Thanks for watching
Great ! Thanks.
You're welcome
how to use CURL in C language to send mail using my IIS 6.0 SMTP SERVER using ip address, my c#, visual basic 6, asp, php, c++ apps can do this.
Hi Alex
To use CURL in C to send mail using your IIS 6.0 SMTP server, you can follow these steps:
1. Install libcurl: First, you need to install the libcurl library, which is a C library that allows you to make HTTP requests, including sending emails via SMTP.
2. Include the necessary headers: In your C code, include the appropriate libcurl header files.
3. Initialize libcurl: Before making any requests, you need to initialize the libcurl library.
4. Set up the SMTP details: Provide the necessary SMTP server details, such as the IP address, port number, sender email, recipient email, subject, and body.
5. Send the email: Use libcurl to send the email using SMTP.
Here's a basic example of how you can use CURL in C to send an email using your IIS 6.0 SMTP server:
```c
#include
#include
int main(void) {
CURL *curl;
CURLcode res = CURLE_OK;
// Initialize libcurl
curl = curl_easy_init();
if (curl) {
// Set SMTP server details
curl_easy_setopt(curl, CURLOPT_URL, "smtp://your_ip_address:25");
curl_easy_setopt(curl, CURLOPT_MAIL_FROM, "sender@example.com");
struct curl_slist *recipients = NULL;
recipients = curl_slist_append(recipients, "recipient@example.com");
curl_easy_setopt(curl, CURLOPT_MAIL_RCPT, recipients);
// Set email content
curl_easy_setopt(curl, CURLOPT_READFUNCTION, NULL); // Set your read function if you want to include a message body
curl_easy_setopt(curl, CURLOPT_UPLOAD, 1L);
// Send the email
res = curl_easy_perform(curl);
// Check for errors
if (res != CURLE_OK) {
fprintf(stderr, "curl_easy_perform() failed: %s
", curl_easy_strerror(res));
}
// Clean up
curl_slist_free_all(recipients);
curl_easy_cleanup(curl);
}
return (int)res;
}
```
Please note that this is just a basic example, and you might need to customize it according to your specific requirements, such as providing authentication credentials or message content.
Additionally, ensure that your IIS 6.0 SMTP server is correctly configured to allow email relay from your C application's IP address to prevent it from being blocked as an open relay.
@@RaghavPal , thank you so much, I will try this as soon as possible. Why I'm switching to CURL, well I have a program that's been working for 15 years harvesting data from several websites, suddenly they stopped working a month ago, my research found out that the websites upgraded and use Angular, I tried everything from my old form POST QUERY in OpenSSL, C#, VB6, Python, C, C++, PHP programs, they all failed, then I tried libcurl, it works like magic but I could not send email using my computer static ip address in IIS 6.0. as the SMTP SERVER.
i want to fecth data submit form from another portal than get response using curl
php
Hi, will need to see some examples online
thanks buddy
You're welcome Vishal
Thank you very much for your help
You're welcome Alain
How to get only the id value from that json format?
Hi Souptik, I may have to check the video again and get online help. Pls try some online examples and still if you have queries, let me know
How to use multi headers?
I will check and add
Thanks for the video..
you're are welcome Venkatesh
I am new to curl. i got basic idea how to use it
Great to know Aruna
can i have your email id
Hi Aruna, can send me your query here
Thank you
You're welcome
Hi Raghav, I am trying to submit a FORM in a webpage through curl. In the webpage the form action shows as "action=rest/", can you please let me know how i can post the form in the webpage through curl or through any other automation
Hi Ananthakrishnan, I will need more details here. In case you need to run a REST Request, of course it can be done with CURL or other tools for REST.
thk u ! it helps
You're welcome
curl -X DELETE localhost:44312/HeartRate/DELETE/1036
this command just works like a get page why?
what is the output you are getting
@@RaghavPal an HTML page
will need to check online for this
How to pass or use session resumption in curl
Hi Sanjeev, I will check on that, for now you can get some help from here curl.haxx.se/libcurl/c/CURLOPT_SSL_SESSIONID_CACHE.html
How to make a Get call that has authentication
I will show this in a session, You can also check the documentation meanwhile
Nice
Thanks Ashok
why you type url without www?
Hi Tarique, I will check the video again and respond
awesome
How to use curl with Basic Auth username and password?
Hi Nayana, I will plan a session, can also check some online examples meanwhile
how to get a video from a site
Hi Anthony, is there an api available for it
@@RaghavPal Hi eg. from reddit video
Will need to see an api for that
@@RaghavPal Isn't it possible to paste the link of a video and grab the video?
There are possibilities, I will need to check more on this
I hope India one day pull all their engineer and scientist from USA and Europe, Indian are very intelligent and government Indian should use them instead of bullshit unhoronable salary of usa.
Hannibaal
I understand your perspective. India indeed has a wealth of talented engineers and scientists who have made significant contributions globally. It’s essential to recognize their skills and expertise
bro can u tell me how to run this curl command i am on vscode?
#!/bin/bash
CMD=$(cat
will need to check on this with more details
how to access api services via sheel script (.ksh.file)
I will need to check on this Arvind