Update a legal page
curl --request PATCH \
--url https://api.1-news.app/v1/projects/{projectId}/legal \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"kind": "<string>",
"html": "<string>",
"auto": true
}
'const options = {
method: 'PATCH',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({kind: '<string>', html: '<string>', auto: true})
};
fetch('https://api.1-news.app/v1/projects/{projectId}/legal', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.1-news.app/v1/projects/{projectId}/legal"
payload = {
"kind": "<string>",
"html": "<string>",
"auto": True
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text){
"ok": true,
"status": "<string>"
}Legal
Update a legal page
Replace a legal page, or apply the pending notes for one page.
PATCH
/
v1
/
projects
/
{projectId}
/
legal
Update a legal page
curl --request PATCH \
--url https://api.1-news.app/v1/projects/{projectId}/legal \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"kind": "<string>",
"html": "<string>",
"auto": true
}
'const options = {
method: 'PATCH',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({kind: '<string>', html: '<string>', auto: true})
};
fetch('https://api.1-news.app/v1/projects/{projectId}/legal', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.1-news.app/v1/projects/{projectId}/legal"
payload = {
"kind": "<string>",
"html": "<string>",
"auto": True
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text){
"ok": true,
"status": "<string>"
}Update one legal page. An admin can do this. Set auto to true to apply pending notes for that kind. Otherwise send kind and html.