Skip to main content

Endpoint

GET /v1/{organizationId}/posts/{postId}
Retrieves detailed information for a specific post within an organization. Optionally filter by status and content type.

Authentication

This endpoint requires Bearer token authentication. Include your API key in the Authorization header:
Authorization: Bearer YOUR_API_KEY

Path Parameters

organizationId
string
required
The unique identifier of the organization. The API key must have access to this organization.Example: org_123
postId
string
required
The unique identifier of the post to retrieve.Example: post_123

Query Parameters

status
string[]
default:"[published]"
Filter by status. The post will only be returned if it matches one of the specified statuses.Options: draft | publishedDefault: ["published"] (only return if post is published)Examples:
  • Single value: ?status=published
  • Multiple values: ?status=draft&status=published
contentType
string[]
Filter by content type. The post will only be returned if it matches one of the specified content types.Options: changelog | linkedin_postDefault: All content typesExamples:
  • Single value: ?contentType=changelog
  • Multiple values: ?contentType=changelog&contentType=linkedin_post

Response

post
object | null
The post object if found and matches the filter criteria, otherwise null.

Examples

curl -X GET "https://api.notra.ai/v1/org_123/posts/post_456" \
  -H "Authorization: Bearer YOUR_API_KEY"

Response Examples

200 Success - Post Found
{
  "post": {
    "id": "post_456",
    "title": "New Feature Release v2.0",
    "content": "We're excited to announce the release of version 2.0 with major improvements to performance and usability.",
    "markdown": "# New Feature Release v2.0\n\nWe're excited to announce the release of version 2.0 with major improvements to performance and usability.\n\n## What's New\n\n- Enhanced performance\n- Improved UI/UX\n- Bug fixes",
    "contentType": "changelog",
    "sourceMetadata": {
      "author": "[email protected]",
      "version": "2.0.0",
      "platform": "web"
    },
    "status": "published",
    "createdAt": "2026-03-01T12:00:00.000Z",
    "updatedAt": "2026-03-01T14:30:00.000Z"
  }
}
200 Success - Post Not Found
{
  "post": null
}
The post field will be null in the following cases:
  • The post ID does not exist
  • The post exists but belongs to a different organization
  • The post exists but doesn’t match the status filter (e.g., requesting a draft post when status=published)
  • The post exists but doesn’t match the content type filter
The endpoint returns a 200 status with { "post": null } rather than a 404 error in these cases.
400 Bad Request
{
  "error": "Invalid path params or query"
}
401 Unauthorized
{
  "error": "Missing or invalid API key"
}
403 Forbidden
{
  "error": "Forbidden: organization access denied"
}
503 Service Unavailable
{
  "error": "Authentication service unavailable"
}

Status Codes

CodeDescription
200Request successful - check the post field to determine if a post was found
400Invalid path params or query parameters
401Missing or invalid API key
403Forbidden - API key does not have access to the specified organization
503Authentication service unavailable

Notes

  • This endpoint returns a 200 status code even when the post is not found. Check if post is null to determine if the post exists and matches your filters
  • The default behavior is to only return published posts unless you explicitly specify the status query parameter
  • To retrieve a post regardless of status, include both values: ?status=draft&status=published
  • The API key must belong to the organization specified in the path, otherwise a 403 error will be returned
  • The post must exist within the specified organization and match all query filters to be returned

Build docs developers (and LLMs) love