cURL
curl --request GET \
--url https://web-scraping-api2.p.rapidapi.com/get-post-comments \
--header 'x-rapidapi-key: <api-key>'import requests
url = "https://web-scraping-api2.p.rapidapi.com/get-post-comments"
headers = {"x-rapidapi-key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'x-rapidapi-key': '<api-key>'}};
fetch('https://web-scraping-api2.p.rapidapi.com/get-post-comments', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://web-scraping-api2.p.rapidapi.com/get-post-comments",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"x-rapidapi-key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://web-scraping-api2.p.rapidapi.com/get-post-comments"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("x-rapidapi-key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://web-scraping-api2.p.rapidapi.com/get-post-comments")
.header("x-rapidapi-key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://web-scraping-api2.p.rapidapi.com/get-post-comments")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["x-rapidapi-key"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"data": [
{
"annotation": null,
"commenter": {
"headline": "Procurement | Certified Functional Analyst | Product Design & Engineering",
"linkedin_url": "https://www.linkedin.com/in/ssgoh",
"name": "Goh Swee Siong"
},
"created_at": 1732656234066,
"created_datetime": "11/26/2024, 1:23:54 PM",
"permalink": "https://www.linkedin.com/feed/update/urn:li:activity:7267273010393358336?commentUrn=urn%3Ali%3Acomment%3A%28activity%3A7267273010393358336%2C7267286973164187649%29&dashCommentUrn=urn%3Ali%3Afsd_comment%3A%287267286973164187649%2Curn%3Ali%3Aactivity%3A7267273010393358336%29",
"pinned": false,
"replies": [
"<unknown>"
],
"text": "This happened all the time in high performance culture nowadays. Nothing new. As the doer, we need to seek clarification and pin down to do or not to do even at the expense of irking the manager.",
"thread_urn": null
}
],
"message": "ok",
"pagination_token": "1388203668-1733209092407-fec4cb84fb5d80c384f61dba04a4f290",
"total": 10
}{
"data": null,
"message": "Bad request: Invalid URN."
}{
"data": null,
"message": "The url was not found on Linkedin."
}{
"data": null,
"message": "System error. We will fix it soon!"
}Post Data
Get Post's Comments
-
Get comments of a post.
-
1 credit per call.
GET
/
get-post-comments
cURL
curl --request GET \
--url https://web-scraping-api2.p.rapidapi.com/get-post-comments \
--header 'x-rapidapi-key: <api-key>'import requests
url = "https://web-scraping-api2.p.rapidapi.com/get-post-comments"
headers = {"x-rapidapi-key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'x-rapidapi-key': '<api-key>'}};
fetch('https://web-scraping-api2.p.rapidapi.com/get-post-comments', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://web-scraping-api2.p.rapidapi.com/get-post-comments",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"x-rapidapi-key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://web-scraping-api2.p.rapidapi.com/get-post-comments"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("x-rapidapi-key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://web-scraping-api2.p.rapidapi.com/get-post-comments")
.header("x-rapidapi-key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://web-scraping-api2.p.rapidapi.com/get-post-comments")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["x-rapidapi-key"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"data": [
{
"annotation": null,
"commenter": {
"headline": "Procurement | Certified Functional Analyst | Product Design & Engineering",
"linkedin_url": "https://www.linkedin.com/in/ssgoh",
"name": "Goh Swee Siong"
},
"created_at": 1732656234066,
"created_datetime": "11/26/2024, 1:23:54 PM",
"permalink": "https://www.linkedin.com/feed/update/urn:li:activity:7267273010393358336?commentUrn=urn%3Ali%3Acomment%3A%28activity%3A7267273010393358336%2C7267286973164187649%29&dashCommentUrn=urn%3Ali%3Afsd_comment%3A%287267286973164187649%2Curn%3Ali%3Aactivity%3A7267273010393358336%29",
"pinned": false,
"replies": [
"<unknown>"
],
"text": "This happened all the time in high performance culture nowadays. Nothing new. As the doer, we need to seek clarification and pin down to do or not to do even at the expense of irking the manager.",
"thread_urn": null
}
],
"message": "ok",
"pagination_token": "1388203668-1733209092407-fec4cb84fb5d80c384f61dba04a4f290",
"total": 10
}{
"data": null,
"message": "Bad request: Invalid URN."
}{
"data": null,
"message": "The url was not found on Linkedin."
}{
"data": null,
"message": "System error. We will fix it soon!"
}Authorizations
Query Parameters
The URN of the post. Either urn or share_urn is required.
The share URN of the post. Can be used as an alternative to urn.
Default value: Most relevant. Possible values: Most relevant, Most recent.
Required when fetching the next result page. Please use the token from the result of your previous call.
⌘I
