İçeriği Yayınla
İçeriği yayınlar (status: published).
Endpoint
POST /api/v1/contents/\{uuid\}/publish
Authentication
Bu endpoint authentication gerektirir.
Header: Authorization: Bearer \{token\}
Permission
content.publish- Tüm içerikleri yayınlamacontent.publish.own- Sadece kendi içeriklerini yayınlama
Request
Headers
| Header | Değer | Zorunlu |
|---|---|---|
Authorization | Bearer \{token\} | Evet |
Path Parameters
| Parametre | Tip | Zorunlu | Açıklama |
|---|---|---|---|
uuid | string | Evet | İçerik UUID'si |
Response
Success Response (200 OK)
{
"message": "Content published",
"content": {
"id": 1,
"uuid": "550e8400-e29b-41d4-a716-446655440000",
"title": "Örnek İçerik",
"status": "published",
"published_at": "2025-11-20T12:00:00.000000Z",
"updated_at": "2025-11-20T12:00:00.000000Z"
}
}
Error Responses
404 Not Found
{
"message": "Not Found"
}
403 Forbidden
{
"message": "Forbidden"
}
Code Examples
cURL
curl -X POST https://api.example.com/api/v1/contents/550e8400-e29b-41d4-a716-446655440000/publish \
-H "Authorization: Bearer \{token\}"
Notes
- İçerik durumu "published" olarak güncellenir
published_attarihi otomatik olarak ayarlanır.ownpermission'ı olan kullanıcılar sadece kendi içeriklerini yayınlayabilir
Related Endpoints
- İçeriği Yayından Kaldır - İçeriği yayından kaldır
- İçerik Detayı - İçerik detayını getir