Replace document content
curl --request PUT \
--url https://scribe.skeptrune.com/api/docs/{id}/content \
--header 'Content-Type: text/markdown' \
--cookie scribe_session= \
--data '<string>'import requests
url = "https://scribe.skeptrune.com/api/docs/{id}/content"
payload = "<string>"
headers = {
"cookie": "scribe_session=",
"Content-Type": "text/markdown"
}
response = requests.put(url, data=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {cookie: 'scribe_session=', 'Content-Type': 'text/markdown'},
body: '<string>'
};
fetch('https://scribe.skeptrune.com/api/docs/{id}/content', 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://scribe.skeptrune.com/api/docs/{id}/content",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_POSTFIELDS => "<string>",
CURLOPT_COOKIE => "scribe_session=",
CURLOPT_HTTPHEADER => [
"Content-Type: text/markdown"
],
]);
$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://scribe.skeptrune.com/api/docs/{id}/content"
payload := strings.NewReader("<string>")
req, _ := http.NewRequest("PUT", url, payload)
req.Header.Add("cookie", "scribe_session=")
req.Header.Add("Content-Type", "text/markdown")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.put("https://scribe.skeptrune.com/api/docs/{id}/content")
.header("cookie", "scribe_session=")
.header("Content-Type", "text/markdown")
.body("<string>")
.asString();require 'uri'
require 'net/http'
url = URI("https://scribe.skeptrune.com/api/docs/{id}/content")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["cookie"] = 'scribe_session='
request["Content-Type"] = 'text/markdown'
request.body = "<string>"
response = http.request(request)
puts response.read_body{
"wordCount": 1280,
"charCount": 8214
}{
"error": {
"code": "not_found",
"message": "No such document."
}
}{
"error": {
"code": "not_found",
"message": "No such document."
}
}{
"error": {
"code": "not_found",
"message": "No such document."
}
}{
"error": {
"code": "not_found",
"message": "No such document."
}
}{
"error": {
"code": "not_found",
"message": "No such document."
}
}{
"error": {
"code": "not_found",
"message": "No such document."
}
}Content
Replace document content
Replaces the markdown content of the document. Send the raw markdown as a text/markdown request body. The change is applied through the collaborative session, so connected editors update live. API keys with edit access write as their agent identity; legacy keys without one are recorded as the key itself.
PUT
/
api
/
docs
/
{id}
/
content
Replace document content
curl --request PUT \
--url https://scribe.skeptrune.com/api/docs/{id}/content \
--header 'Content-Type: text/markdown' \
--cookie scribe_session= \
--data '<string>'import requests
url = "https://scribe.skeptrune.com/api/docs/{id}/content"
payload = "<string>"
headers = {
"cookie": "scribe_session=",
"Content-Type": "text/markdown"
}
response = requests.put(url, data=payload, headers=headers)
print(response.text)const options = {
method: 'PUT',
headers: {cookie: 'scribe_session=', 'Content-Type': 'text/markdown'},
body: '<string>'
};
fetch('https://scribe.skeptrune.com/api/docs/{id}/content', 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://scribe.skeptrune.com/api/docs/{id}/content",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PUT",
CURLOPT_POSTFIELDS => "<string>",
CURLOPT_COOKIE => "scribe_session=",
CURLOPT_HTTPHEADER => [
"Content-Type: text/markdown"
],
]);
$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://scribe.skeptrune.com/api/docs/{id}/content"
payload := strings.NewReader("<string>")
req, _ := http.NewRequest("PUT", url, payload)
req.Header.Add("cookie", "scribe_session=")
req.Header.Add("Content-Type", "text/markdown")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.put("https://scribe.skeptrune.com/api/docs/{id}/content")
.header("cookie", "scribe_session=")
.header("Content-Type", "text/markdown")
.body("<string>")
.asString();require 'uri'
require 'net/http'
url = URI("https://scribe.skeptrune.com/api/docs/{id}/content")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Put.new(url)
request["cookie"] = 'scribe_session='
request["Content-Type"] = 'text/markdown'
request.body = "<string>"
response = http.request(request)
puts response.read_body{
"wordCount": 1280,
"charCount": 8214
}{
"error": {
"code": "not_found",
"message": "No such document."
}
}{
"error": {
"code": "not_found",
"message": "No such document."
}
}{
"error": {
"code": "not_found",
"message": "No such document."
}
}{
"error": {
"code": "not_found",
"message": "No such document."
}
}{
"error": {
"code": "not_found",
"message": "No such document."
}
}{
"error": {
"code": "not_found",
"message": "No such document."
}
}Authorizations
cookieAuthbearerAuth
Browser session cookie set by the WorkOS sign-in flow.
Path Parameters
Id of the document whose markdown to replace.
Body
text/markdown
The new markdown source.
The full markdown source to store.