TrainFog Developers
Posts

Aggiorna un post specifico

PUT
/posts/{id}
AuthorizationBearer <token>

In: header

Path Parameters

idstring

L'id del post da aggiornare

Campi da aggiornare nel post.

product?string

L'ID del prodotto associato al post.

topicstring

L'argomento principale del post.

type?string

Il tipo di post (es. 'blog', 'social').

Response Body

application/json

application/json

application/json

curl -X PUT "https://api.trainfog.com/developers/v1.0/posts/string" \  -H "Content-Type: application/json" \  -d '{    "topic": "How to use the Trainfog API"  }'
{
  "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"
}
{
  "error": "Not found"
}