Get root public markdown content
curl --request GET \
--url https://app.promptingco.com/api/v1/md/by-path \
--header 'x-api-key: <api-key>'const options = {method: 'GET', headers: {'x-api-key': '<api-key>'}};
fetch('https://app.promptingco.com/api/v1/md/by-path', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://app.promptingco.com/api/v1/md/by-path"
headers = {"x-api-key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text){
"ok": true,
"data": {
"id": "<string>",
"createdAt": "<string>",
"updatedAt": "<string>",
"filePath": "<string>",
"title": "<string>",
"content": "<string>",
"sourceUrl": "<string>",
"isManual": true,
"productId": "<string>",
"contentType": "markdown",
"deletedAt": "<string>"
}
}{
"ok": false,
"code": "<string>",
"message": "<string>",
"details": "<unknown>"
}{
"ok": false,
"code": "<string>",
"message": "<string>",
"details": "<unknown>"
}{
"ok": false,
"code": "<string>",
"message": "<string>",
"details": "<unknown>"
}{
"ok": false,
"code": "<string>",
"message": "<string>",
"details": "<unknown>"
}{
"ok": false,
"code": "<string>",
"message": "<string>",
"details": "<unknown>"
}{
"ok": false,
"code": "<string>",
"message": "<string>",
"details": "<unknown>"
}Content
Get root public markdown content
Retrieves the root public markdown content. Supports standard x-api-key authentication (productId/productSlug via query param or X-Tpc-Product-* headers as fallback) as well as the legacy X-Tpc-* header model.
GET
/
api
/
v1
/
md
/
by-path
Get root public markdown content
curl --request GET \
--url https://app.promptingco.com/api/v1/md/by-path \
--header 'x-api-key: <api-key>'const options = {method: 'GET', headers: {'x-api-key': '<api-key>'}};
fetch('https://app.promptingco.com/api/v1/md/by-path', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://app.promptingco.com/api/v1/md/by-path"
headers = {"x-api-key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text){
"ok": true,
"data": {
"id": "<string>",
"createdAt": "<string>",
"updatedAt": "<string>",
"filePath": "<string>",
"title": "<string>",
"content": "<string>",
"sourceUrl": "<string>",
"isManual": true,
"productId": "<string>",
"contentType": "markdown",
"deletedAt": "<string>"
}
}{
"ok": false,
"code": "<string>",
"message": "<string>",
"details": "<unknown>"
}{
"ok": false,
"code": "<string>",
"message": "<string>",
"details": "<unknown>"
}{
"ok": false,
"code": "<string>",
"message": "<string>",
"details": "<unknown>"
}{
"ok": false,
"code": "<string>",
"message": "<string>",
"details": "<unknown>"
}{
"ok": false,
"code": "<string>",
"message": "<string>",
"details": "<unknown>"
}{
"ok": false,
"code": "<string>",
"message": "<string>",
"details": "<unknown>"
}Authorizations
Organization-scoped API key. Available scopes:
- content:read: Read site pages, markdown content, and llms.txt files
- content:write: Create, update, and delete site pages and content
- prompts:read: Read prompts, topics, prompt suggestions, and prompt analysis results
- prompts:write: Create, update, archive prompts and generate, edit, or review prompt suggestions
- simulations:read: Read agent-simulation tasks, runs, environments, and analytics
- simulations:write: Create and trigger simulation runs
- logs:read: Read AI-traffic logs and request-level audit events
- analytics:read: Read analytics aggregates (rankings, mentions, sources, SOV)
- analytics:write: Write events to analytics
- products:read: Read product metadata and competitor data
- products:write: Update product settings and competitor lists
Headers
Standard API key authentication (preferred). When present, X-Tpc-* headers are ignored.
Bearer API key (used with X-Tpc-* headers for legacy public access)
Organization ID (used with legacy public auth)
Organization slug (used with legacy public auth)
Product ID (used with legacy public auth)
Product slug (used with legacy public auth)