TrainFog Developers
Posts

List all posts

Obtain a list of all posts. Supports filtering, search term (topic, artifact title, artifact body), and type.

GET
/posts
AuthorizationBearer <token>

In: header

Query Parameters

search?string

Search term for post topic, artifact titles, or artifact bodies (uses regex).

type?string

Filter by the post type.

Response Body

application/json

application/json

curl -X GET "https://api.trainfog.com/developers/v1.0/posts"
{
  "count": 10,
  "data": [
    {
      "id": "688874b1a08a60001dd72e1d",
      "product": "some-product-id",
      "topic": "How to use the Trainfog API",
      "type": "blog",
      "artifacts": [
        {
          "title": "API Guide: Getting Started",
          "body": "This is the generated blog post body..."
        }
      ],
      "createdAt": "2025-07-29T07:13:53.474Z",
      "updatedAt": "2025-07-29T07:13:53.474Z"
    }
  ]
}
{
  "error": "Unauthorized"
}