curl --request POST \
--url https://sdk.anghami.com/v1/library/saved:check \
--header 'Authorization: <authorization>' \
--header 'Content-Type: application/json' \
--data '
{
"showIds": {
"values": [
{
"value": "<string>"
}
]
},
"movieIds": {
"values": [
{
"value": "<string>"
}
]
}
}
'import requests
url = "https://sdk.anghami.com/v1/library/saved:check"
payload = {
"showIds": { "values": [{ "value": "<string>" }] },
"movieIds": { "values": [{ "value": "<string>" }] }
}
headers = {
"Authorization": "<authorization>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: '<authorization>', 'Content-Type': 'application/json'},
body: JSON.stringify({
showIds: {values: [{value: '<string>'}]},
movieIds: {values: [{value: '<string>'}]}
})
};
fetch('https://sdk.anghami.com/v1/library/saved:check', 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://sdk.anghami.com/v1/library/saved:check",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'showIds' => [
'values' => [
[
'value' => '<string>'
]
]
],
'movieIds' => [
'values' => [
[
'value' => '<string>'
]
]
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: <authorization>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://sdk.anghami.com/v1/library/saved:check"
payload := strings.NewReader("{\n \"showIds\": {\n \"values\": [\n {\n \"value\": \"<string>\"\n }\n ]\n },\n \"movieIds\": {\n \"values\": [\n {\n \"value\": \"<string>\"\n }\n ]\n }\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "<authorization>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://sdk.anghami.com/v1/library/saved:check")
.header("Authorization", "<authorization>")
.header("Content-Type", "application/json")
.body("{\n \"showIds\": {\n \"values\": [\n {\n \"value\": \"<string>\"\n }\n ]\n },\n \"movieIds\": {\n \"values\": [\n {\n \"value\": \"<string>\"\n }\n ]\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://sdk.anghami.com/v1/library/saved:check")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = '<authorization>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"showIds\": {\n \"values\": [\n {\n \"value\": \"<string>\"\n }\n ]\n },\n \"movieIds\": {\n \"values\": [\n {\n \"value\": \"<string>\"\n }\n ]\n }\n}"
response = http.request(request)
puts response.read_body{
"results": {}
}{
"violations": [
{
"field": "<string>",
"description": "<string>"
}
]
}{
"message": "<string>"
}CheckSavedItems
CheckSavedItems checks whether specific items are in the user’s saved collection. Useful for rendering save/unsave toggle state in the UI. Requires the “read” scope.
curl --request POST \
--url https://sdk.anghami.com/v1/library/saved:check \
--header 'Authorization: <authorization>' \
--header 'Content-Type: application/json' \
--data '
{
"showIds": {
"values": [
{
"value": "<string>"
}
]
},
"movieIds": {
"values": [
{
"value": "<string>"
}
]
}
}
'import requests
url = "https://sdk.anghami.com/v1/library/saved:check"
payload = {
"showIds": { "values": [{ "value": "<string>" }] },
"movieIds": { "values": [{ "value": "<string>" }] }
}
headers = {
"Authorization": "<authorization>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: '<authorization>', 'Content-Type': 'application/json'},
body: JSON.stringify({
showIds: {values: [{value: '<string>'}]},
movieIds: {values: [{value: '<string>'}]}
})
};
fetch('https://sdk.anghami.com/v1/library/saved:check', 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://sdk.anghami.com/v1/library/saved:check",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'showIds' => [
'values' => [
[
'value' => '<string>'
]
]
],
'movieIds' => [
'values' => [
[
'value' => '<string>'
]
]
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: <authorization>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://sdk.anghami.com/v1/library/saved:check"
payload := strings.NewReader("{\n \"showIds\": {\n \"values\": [\n {\n \"value\": \"<string>\"\n }\n ]\n },\n \"movieIds\": {\n \"values\": [\n {\n \"value\": \"<string>\"\n }\n ]\n }\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "<authorization>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://sdk.anghami.com/v1/library/saved:check")
.header("Authorization", "<authorization>")
.header("Content-Type", "application/json")
.body("{\n \"showIds\": {\n \"values\": [\n {\n \"value\": \"<string>\"\n }\n ]\n },\n \"movieIds\": {\n \"values\": [\n {\n \"value\": \"<string>\"\n }\n ]\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://sdk.anghami.com/v1/library/saved:check")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = '<authorization>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"showIds\": {\n \"values\": [\n {\n \"value\": \"<string>\"\n }\n ]\n },\n \"movieIds\": {\n \"values\": [\n {\n \"value\": \"<string>\"\n }\n ]\n }\n}"
response = http.request(request)
puts response.read_body{
"results": {}
}{
"violations": [
{
"field": "<string>",
"description": "<string>"
}
]
}{
"message": "<string>"
}Headers
OAuth 2.0 Bearer token with the 'read' scope. Required for all library operations. Format: Bearer <access_token>.
"Bearer eyJhbGciOiJSUzI1NiIs..."
Preferred locale for localized content in returned items (BCP 47).
"ar"
Body
CheckSavedItemsRequest is the request message for checking whether items are in the user's saved collection. Only movies and shows can be saved.
Response
Successful response
CheckSavedItemsResponse is the response message indicating which items are saved.
Map of item ID to saved status. Every requested ID appears in this map. True indicates the item is in the user's saved collection.
Show child attributes
Show child attributes